Dillon Buchanan在MonoTouch中有一个很棒的example for creating the a left side slide-out导航。
我的问题是我正在使用MonoCross而无法弄清楚如何实现它。以下是Dillon与我FinishedLaunching
实施的摘录。
狄龙的:
public override bool FinishedLaunching (UIApplication app, NSDictionary options)
{
window = new UIWindow (UIScreen.MainScreen.Bounds);
Menu = new SlideoutNavigationController();
Menu.TopView = new HomeViewController();
Menu.MenuView = new DummyController();
window.RootViewController = Menu;
window.MakeKeyAndVisible ();
return true;
}
矿
public override bool FinishedLaunching (UIApplication app, NSDictionary options)
{
// create a new window instance based on the screen size
window = new UIWindow (UIScreen.MainScreen.Bounds);
MXTouchContainer.Initialize(new eDash.App(), this, window);
// Add Views
MXTouchContainer.AddView<List<Location>>(typeof(LocationListView), ViewPerspective.Default);
MXTouchContainer.AddView<Location>(typeof(LocationView), ViewPerspective.Default);
MXTouchContainer.AddView<List<Engagements>>(typeof(EngagementsListView), ViewPerspective.Default);
MXTouchContainer.Navigate(null, MXContainer.Instance.App.NavigateOnLoad);
UIDevice.CurrentDevice.BeginGeneratingDeviceOrientationNotifications();
UINavigationBar.Appearance.TintColor =UIColor.Black;
return true;
}