Skip to content
Browse files

Update for latest MonoMac/XamMac

  • Loading branch information...
1 parent 2e96682 commit abfd01f8a9c98998d9b2c371f8433d7d2a1f7da3 @cwensley cwensley committed
View
BIN Libraries/MonoMac/MonoMac.dll
Binary file not shown.
View
2 Source/Eto.Platform.Mac/Eto.Platform.XamMac.csproj
@@ -38,7 +38,7 @@
<Reference Include="System.Drawing" />
<Reference Include="System.Core" />
<Reference Include="System.Xaml" />
- <Reference Include="XamMac, Version=0.0.0.0, Culture=neutral">
+ <Reference Include="XamMac, Version=0.0.0.0, Culture=neutral, PublicKeyToken=84e04ff9cfb79065">
<Private>False</Private>
</Reference>
</ItemGroup>
View
6 Source/Eto.Platform.Mac/Forms/Controls/GridHandler.cs
@@ -120,10 +120,10 @@ protected virtual void UpdateColumns ()
public GridColumnHandler GetColumn (NSTableColumn tableColumn)
{
- var str = tableColumn.Identifier as NSString;
- if (str != null) {
+ var str = tableColumn.Identifier;
+ if (!string.IsNullOrEmpty (str)) {
int col;
- if (int.TryParse ((string)str, out col)) {
+ if (int.TryParse (str, out col)) {
return GetColumn (col);
}
}
View
8 Source/Eto.Platform.Mac/Forms/MacWindow.cs
@@ -155,11 +155,7 @@ protected override void Initialize ()
base.Initialize ();
Control.DidBecomeKey += delegate {
if (MenuBar != null) {
-#if XAMMAC
- NSApplication.SharedApplication.SetMainMenu (MenuBar);
-#else
NSApplication.SharedApplication.MainMenu = MenuBar;
-#endif
}
};
}
@@ -381,11 +377,7 @@ public virtual void SetParent (Control parent)
set {
this.menuBar = value;
if (Control.IsKeyWindow) {
-#if XAMMAC
- NSApplication.SharedApplication.SetMainMenu ((NSMenu)value.ControlObject);
-#else
NSApplication.SharedApplication.MainMenu = (NSMenu)value.ControlObject;
-#endif
}
}
}
View
2 Source/Eto.Platform.Mac/Forms/Menu/ContextMenuHandler.cs
@@ -15,7 +15,7 @@ public ContextMenuHandler ()
public void AddMenu (int index, MenuItem item)
{
- Control.InsertItematIndex ((NSMenuItem)item.ControlObject, index);
+ Control.InsertItem ((NSMenuItem)item.ControlObject, index);
}
public void RemoveMenu (MenuItem item)
View
2 Source/Eto.Platform.Mac/Forms/Menu/MenuBarHandler.cs
@@ -18,7 +18,7 @@ public void AddMenu (int index, MenuItem item)
{
var itemHandler = item.Handler as IMenuHandler;
if (itemHandler != null) itemHandler.EnsureSubMenu ();
- Control.InsertItematIndex ((NSMenuItem)item.ControlObject, index);
+ Control.InsertItem ((NSMenuItem)item.ControlObject, index);
}
public void RemoveMenu (MenuItem item)
View
2 Source/Eto.Platform.Mac/Forms/Menu/MenuHandler.cs
@@ -27,7 +27,7 @@ public void EnsureSubMenu ()
public virtual void AddMenu (int index, MenuItem item)
{
EnsureSubMenu ();
- Control.Submenu.InsertItematIndex ((NSMenuItem)item.ControlObject, index);
+ Control.Submenu.InsertItem ((NSMenuItem)item.ControlObject, index);
}
public virtual void RemoveMenu (MenuItem item)

0 comments on commit abfd01f

Please sign in to comment.
Something went wrong with that request. Please try again.