I've been converting old GIT code to the new Unified API and have hit the following that I cannot convert:
[DllImport (MonoMac.Constants.AppKitLibrary, EntryPoint="NSDrawWindowBackground")] public extern static void DrawWindowBackground (CGRect aRect); [DllImport (MonoMac.Constants.AppKitLibrary, EntryPoint="NSSetFocusRingStyle")] public extern static void SetFocusRingStyle (NSFocusRingPlacement placement); [DllImport (MonoMac.Constants.AppKitLibrary, EntryPoint="NSDisableScreenUpdates")] public extern static void DisableScreenUpdates (); [DllImport (MonoMac.Constants.AppKitLibrary, EntryPoint="NSEnableScreenUpdates")] public extern static void EnableScreenUpdates ();
I keep getting "The name 'MonoMac' does not exist in the current context" compile-time message & when I strip 'MonoMac' I receive the same message "The name 'Constants' does not exist in the current context.
What am I missing here?
Thanks,
Graeme
Posts
MonoMac.Constants.AppKitLibrary simply resolves to "/System/Library/Frameworks/AppKit.framework/AppKit"
Please forgive my ignorance, but I am new to Mac dev... what would be the fix then?
Just hard code the string constant:
Apple isn't moving AppKit anytime.
Thanks Chris... Now I just need to figure out why NSCellMask is not found in the "Unified" AppKit ...