0

I'm trying to port a great Windows Forms program to Linux and get this error:

System.EntryPointNotFoundException: GetUpdateRect
  at (wrapper managed-to-native)  
CDBurnerXP.Controls.NativeMethods:GetUpdateRectInternal  
(intptr,System.Drawing.Rectangle&,bool)  
at CDBurnerXP.Controls.NativeMethods.GetUpdateRect  
(System.Windows.Forms.Control cntl) [0x0000f] in  
<ce4ca0f630654e4c8c1f96509f1eae82>:0  

Is there a way to support C# calls to
NativeMethods:GetUpdateRect noon Mono on Lubuntu 16.04.1?


Edit:
Thanks, knocte, for your comment. This edit is to quote the bit of code that tries to reference this function (because comments don't allow any formatting):

[DllImport("user32.dll", EntryPoint = "GetUpdateRect", CharSet = CharSet.Auto)]
private static extern IntPtr GetUpdateRectInternal(IntPtr hWnd, ref Rectangle r, bool eraseBackground);
4

1 回答 1

0

Well, the answer is that I was asking the wrong question.
I should have been asking "How can I replace ObjectListView.cs, which depends on non-portable Windows system calls, to port this program to Mono on Linux?"

ObjectListView seems to work very well on Windows, but is not compatible with Linux or Mac systems. There's a very good discussion in the ObjectListView discussion board. The comment by Steve Hiner (2015-11-29) changed the direction of my search. Steve's approach is "I already created a proxy that uses OLV on Windows and the stock listview on Linux and Mac. That would be one way OLV could provide pseudo mono support, it could just use the stock listview without any fancy features."

Thanks, knocte, for getting me thinking in the right direction.

于 2016-11-26T15:08:53.403 回答