我正在使用这里的覆盖代码 - http://docs.xamarin.com/recipes/ios/standard_controls/popovers/display_a_loading_message
一切正常...,我可以打电话View.Add(loadingOverlay)
...直到我将事情更改为 MonoTouch.Dialog 并且它不再起作用了。
public partial class BaseView : UIViewController
{
LoadingOverlay loadingOverlay;
public void ProgressDialogShow(string message, string title)
{
loadingOverlay = new LoadingOverlay(message, UIScreen.MainScreen.Bounds);
View.Add(loadingOverlay);
}
}
视图本身(LoginView)是从 BaseView 继承的。
[Register("SecondLoginView")]
public class SecondLoginView : BaseView
{
public override void ViewDidLoad()
{
base.ViewDidLoad();
window = new UIWindow(UIScreen.MainScreen.Bounds);
root = new RootElement("Login") {
new Section() {
new EntryElement ("Benutzer", "Login", "Test")
}
};
rootVC = new DialogViewController(root);
nav = new UINavigationController(rootVC);
window.RootViewController = nav;
window.MakeKeyAndVisible();
}
}
在这种情况下,Loadingoverlay 不会出现。我怎样才能将它与 MonoTouch.Dialog 一起使用?
任何帮助表示赞赏!