private void MainWindow_Loaded(object sender, RoutedEventArgs e)
 {
     AlertBarManager.Alert("Default",
                           AlertBuilder.Build()
                           .WithTitle("TestTitle")
                           .WithMessage("Hello")
                           .WithAction("Klick mich", () => MessageBox.Show("Hier ist die Antwort: 42"), true)
                           //.AsStickyInfo()
                           .WithBackground(Colors.Pink));
 }
        public override IDisposable Alert(AlertConfig config)
        {
            var activity = this.TopActivityFunc();

            if (activity is AppCompatActivity)
            {
                return(this.ShowDialog <AlertAppCompatDialogFragment, AlertConfig>((AppCompatActivity)activity, config));
            }

            if (activity is FragmentActivity)
            {
                return(this.ShowDialog <AlertDialogFragment, AlertConfig>((FragmentActivity)activity, config));
            }

            return(this.Show(activity, AlertBuilder.Build(activity, config)));
        }
 protected override Dialog CreateDialog(AlertConfig config)
 {
     return(AlertBuilder.Build(this.Activity as AppCompatActivity, config).Create());
 }