本文整理汇总了C#中UINavigationController.SetToolbarHidden方法的典型用法代码示例。如果您正苦于以下问题:C# UINavigationController.SetToolbarHidden方法的具体用法?C# UINavigationController.SetToolbarHidden怎么用?C# UINavigationController.SetToolbarHidden使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类UINavigationController
的用法示例。
在下文中一共展示了UINavigationController.SetToolbarHidden方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: OnTapped
partial void OnTapped(MonoTouch.UIKit.UIButton sender)
{
if (textPassword.Text != "123")
new UIAlertView("My Notes", "Wrong password!", null, "Ok").Show();
else
{
var controller = new NotesTableViewController();
var navigationController = new UINavigationController(controller);
navigationController.SetToolbarHidden(false, false);
this.PresentModalViewController(navigationController, true);
}
}
示例2: FinishedLaunching
//.........这里部分代码省略.........
_downloader.Progress += (progress) => {
float percent = (progress.Written / (float)progress.Total) * 100;
int ipercent = (int)percent;
string caption = string.Format("{0} {1} {2}% ({3} / {4})",
"Global",
progress.State.ToString(),
ipercent,
progress.Written,
progress.Total
);
InvokeOnMainThread(() => {
globalprogress.Caption = caption;
globalprogress
.GetImmediateRootElement()
.Reload(globalprogress, UITableViewRowAnimation.Automatic);
});
};
_sample = new DialogViewController (root);
var add = new UIBarButtonItem ("Add",
UIBarButtonItemStyle.Bordered,
(sender, e) => {
string url = string.Format(templateurl, 1);
Add(url);
});
var addall = new UIBarButtonItem ("All",
UIBarButtonItemStyle.Bordered,
(sender, e) => {
for(int i=1; i<80; i++) {
string url = string.Format(templateurl, i);
Add(url);
}
});
var zips = new UIBarButtonItem ("Z",
UIBarButtonItemStyle.Bordered,
(sender, e) => {
foreach(string coll in collections) {
string url = string.Format(zipurl, coll);
Add(url);
}
});
var s404 = new UIBarButtonItem ("4",
UIBarButtonItemStyle.Bordered,
(sender, e) => {
string url = string.Format(httpurl, 404);
Add(url);
});
var s500 = new UIBarButtonItem ("5",
UIBarButtonItemStyle.Bordered,
(sender, e) => {
string url = string.Format(httpurl, 500);
Add(url);
});
var s301 = new UIBarButtonItem ("3",
UIBarButtonItemStyle.Bordered,
(sender, e) => {
string url = string.Format(httpurl, 301);
Add(url);
});
var s301p = new UIBarButtonItem ("3+",
UIBarButtonItemStyle.Bordered,
(sender, e) => {
string url = string.Format(redirecturl, 301);
Add(url);
});
var reset = new UIBarButtonItem ("Reset",
UIBarButtonItemStyle.Bordered,
async (sender, e) => {
await _downloader.Reset();
Sync();
});
var sync = new UIBarButtonItem ("S",
UIBarButtonItemStyle.Bordered,
(sender, e) => {
Sync();
});
Navigation = new UINavigationController ();
Window.RootViewController = Navigation;
Window.MakeKeyAndVisible ();
Navigation.PushViewController (_sample, false);
_sample.SetToolbarItems (new [] { add, addall, zips, s404, s500, s301, s301p, reset, sync}, true);
Navigation.SetToolbarHidden (false, true);
return true;
}