예제 #1
0
 public void SetAlertMode(int seconds)
 {
     if (wrapped != null)
     {
         wrapped.SetAlertMode(seconds);
     }
 }
예제 #2
0
 static void OnBusyStateChanged(object s, BusyStateEventArgs args)
 {
     isBusy = args.IsBusy;
     DispatchService.GuiDispatch(delegate {
         busyDialog.UpdateBusyState(args);
         if (args.IsBusy)
         {
             if (busyStatusIcon == null)
             {
                 busyStatusIcon = IdeApp.Workbench.StatusBar.ShowStatusIcon(ImageService.GetPixbuf("md-execute-debug", Gtk.IconSize.Menu));
                 busyStatusIcon.SetAlertMode(100);
                 busyStatusIcon.ToolTip = GettextCatalog.GetString("The Debugger is waiting for an expression evaluation to finish.");
                 busyStatusIcon.EventBox.ButtonPressEvent += delegate {
                     busyDialog.Show();
                 };
             }
         }
         else
         {
             if (busyStatusIcon != null)
             {
                 busyStatusIcon.Dispose();
                 busyStatusIcon = null;
             }
         }
     });
 }
예제 #3
0
 static async void OnBusyStateChanged(object s, BusyStateEventArgs args)
 {
     isBusy = args.IsBusy;
     await Runtime.RunInMainThread(delegate {
         busyEvaluator.UpdateBusyState(args);
         if (args.IsBusy)
         {
             if (busyStatusIcon == null)
             {
                 busyStatusIcon = IdeApp.Workbench.StatusBar.ShowStatusIcon(ImageService.GetIcon("md-execute-debug", Gtk.IconSize.Menu));
                 busyStatusIcon.SetAlertMode(100);
                 busyStatusIcon.ToolTip  = GettextCatalog.GetString("The debugger runtime is not responding. You can wait for it to recover, or stop debugging.");
                 busyStatusIcon.Clicked += OnBusyStatusIconClicked;
             }
         }
         else
         {
             if (busyStatusIcon != null)
             {
                 busyStatusIcon.Clicked -= OnBusyStatusIconClicked;
                 busyStatusIcon.Dispose();
                 busyStatusIcon = null;
             }
         }
     });
 }
예제 #4
0
        void WarnAvailableUpdates()
        {
            if (!UpdateService.NotifyAddinUpdates)
            {
                return;
            }

            updateIcon = IdeApp.Workbench.StatusBar.ShowStatusIcon(ImageService.GetIcon(Gui.Stock.Updates, IconSize.Menu));
            string s = GettextCatalog.GetString("New extension updates are available:");

            for (int n = 0; n < updates.Length && n < 10; n++)
            {
                s += "\n" + updates [n].Addin.Name;
            }

            if (updates.Length > 10)
            {
                s += "\n...";
            }

            updateIcon.ToolTip = s;
            updateIcon.Title   = GettextCatalog.GetString("Updates");
            updateIcon.Help    = GettextCatalog.GetString("Indicates that there are updates available to be installed");
            updateIcon.SetAlertMode(20);
            updateIcon.Clicked += OnUpdateClicked;
        }
예제 #5
0
 static void OnBusyStateChanged(object s, BusyStateEventArgs args)
 {
     isBusy = args.IsBusy;
     DispatchService.GuiDispatch(delegate {
         busyDialog.UpdateBusyState(args);
         if (args.IsBusy)
         {
             if (busyStatusIcon == null)
             {
                 busyStatusIcon = IdeApp.Workbench.StatusBar.ShowStatusIcon(ImageService.GetIcon("md-execute-debug", Gtk.IconSize.Menu));
                 busyStatusIcon.SetAlertMode(100);
                 busyStatusIcon.ToolTip  = GettextCatalog.GetString("The debugger runtime is not responding. You can wait for it to recover, or stop debugging.");
                 busyStatusIcon.Clicked += delegate {
                     MessageService.PlaceDialog(busyDialog, MessageService.RootWindow);
                 };
             }
         }
         else
         {
             if (busyStatusIcon != null)
             {
                 busyStatusIcon.Dispose();
                 busyStatusIcon = null;
             }
         }
     });
 }
예제 #6
0
 static void NotifyError(LogMessage message)
 {
     if (!errorNotificationEnabled)
     {
         return;
     }
     ClearErrorIcon();
     Gdk.Pixbuf pix = ImageService.GetPixbuf(Gtk.Stock.DialogError, Gtk.IconSize.Menu);
     errorIcon = IdeApp.Workbench.StatusBar.ShowStatusIcon(pix);
     errorIcon.EventBox.ButtonPressEvent += new Gtk.ButtonPressEventHandler(OnShowLogPad);
     errorIcon.SetAlertMode(5);
     errorIcon.ToolTip = message.Message;
 }
예제 #7
0
 void ShowStatusIcon()
 {
     Runtime.RunInMainThread(() => {
         if (statusBarIcon == null)
         {
             var icon               = ImageService.GetIcon("md-text-file-icon", Gtk.IconSize.Menu);
             statusBarIcon          = IdeApp.Workbench.StatusBar.ShowStatusIcon(icon);
             statusBarIcon.Clicked += StatusBarIconClicked;
         }
         statusBarIcon.Title   = GettextCatalog.GetString("IDE log errors");
         statusBarIcon.ToolTip = GettextCatalog.GetPluralString("{0} IDE log error", "{0} IDE log errors", errorsCount, errorsCount);
         statusBarIcon.SetAlertMode(1);
     }).Ignore();
 }
예제 #8
0
        static void NotifyError(LogMessage message)
        {
            if (!errorNotificationEnabled)
            {
                return;
            }
            ClearErrorIcon();
            var pix = ImageService.GetIcon(Gtk.Stock.DialogError, Gtk.IconSize.Menu);

            errorIcon = IdeApp.Workbench.StatusBar.ShowStatusIcon(pix);
            errorIcon.EventBox.ButtonPressEvent += delegate {
                ClearErrorIcon();
                MessageService.ShowError(message.Message);
            };
            errorIcon.SetAlertMode(5);
            errorIcon.ToolTip = message.Message;
        }
    void WarnAvailableUpdates ()
    {
        if (!UpdateService.NotifyAddinUpdates)
            return;

        updateIcon = IdeApp.Workbench.StatusBar.ShowStatusIcon (ImageService.GetPixbuf ("md-software-update", IconSize.Menu));
        string s = GettextCatalog.GetString ("New add-in updates are available:");
        for (int n=0; n<updates.Length && n < 10; n++)
            s += "\n" + updates [n].Addin.Name;

        if (updates.Length > 10)
            s += "\n...";

        updateIcon.ToolTip = s;
        updateIcon.SetAlertMode (20);
        updateIcon.EventBox.ButtonPressEvent += new ButtonPressEventHandler (OnUpdateClicked);
    }
예제 #10
0
		void WarnAvailableUpdates ()
		{
			if (!UpdateService.NotifyAddinUpdates)
				return;

			updateIcon = IdeApp.Workbench.StatusBar.ShowStatusIcon (ImageService.GetIcon ("md-updates", IconSize.Menu));
			string s = GettextCatalog.GetString ("New add-in updates are available:");
			for (int n=0; n<updates.Length && n < 10; n++)
				s += "\n" + updates [n].Addin.Name;

			if (updates.Length > 10)
				s += "\n...";

			updateIcon.ToolTip = s;
			updateIcon.SetAlertMode (20);
			updateIcon.Clicked += OnUpdateClicked;
		}
예제 #11
0
		void WarnAvailableUpdates ()
		{
			if (!UpdateService.NotifyAddinUpdates)
				return;
			
			updateIcon = IdeApp.Workbench.StatusBar.ShowStatusIcon (ImageService.GetPixbuf ("md-software-update", IconSize.Menu));
			string s = GettextCatalog.GetString ("New add-in updates are available:");
			for (int n=0; n<updates.Length && n < 10; n++)
				s += "\n" + updates [n].Addin.Name;
			
			if (updates.Length > 10)
				s += "\n...";

			updateIcon.ToolTip = s;
			updateIcon.SetAlertMode (20);
			updateIcon.EventBox.ButtonPressEvent += new ButtonPressEventHandler (OnUpdateClicked);
		}
예제 #12
0
        void WarnAvailableUpdates()
        {
            if (!UpdateService.NotifyAddinUpdates)
            {
                return;
            }

            updateIcon = IdeApp.Workbench.StatusBar.ShowStatusIcon(ImageService.GetIcon("md-updates", IconSize.Menu));
            string s = GettextCatalog.GetString("New add-in updates are available:");

            for (int n = 0; n < updates.Length && n < 10; n++)
            {
                s += "\n" + updates [n].Addin.Name;
            }

            if (updates.Length > 10)
            {
                s += "\n...";
            }

            updateIcon.ToolTip = s;
            updateIcon.SetAlertMode(20);
            updateIcon.Clicked += OnUpdateClicked;
        }
예제 #13
0
		static void OnBusyStateChanged (object s, BusyStateEventArgs args)
		{
			isBusy = args.IsBusy;
			DispatchService.GuiDispatch (delegate {
				busyDialog.UpdateBusyState (args);
				if (args.IsBusy) {
					if (busyStatusIcon == null) {
						busyStatusIcon = IdeApp.Workbench.StatusBar.ShowStatusIcon (ImageService.GetPixbuf ("md-execute-debug", Gtk.IconSize.Menu));
						busyStatusIcon.SetAlertMode (100);
						busyStatusIcon.ToolTip = GettextCatalog.GetString ("The Debugger is waiting for an expression evaluation to finish.");
						busyStatusIcon.EventBox.ButtonPressEvent += delegate {
							busyDialog.Show ();
						};
					}
				} else {
					if (busyStatusIcon != null) {
						busyStatusIcon.Dispose ();
						busyStatusIcon = null;
					}
				}
			});
		}
예제 #14
0
		static void NotifyError (LogMessage message)
		{
			if (!errorNotificationEnabled)
				return;
			ClearErrorIcon ();
			var pix = ImageService.GetIcon (Gtk.Stock.DialogError, Gtk.IconSize.Menu);
			errorIcon = IdeApp.Workbench.StatusBar.ShowStatusIcon (pix);
			errorIcon.Clicked += delegate {
				ClearErrorIcon ();
				MessageService.ShowError (message.Message);
			};
			errorIcon.SetAlertMode (5);
			errorIcon.ToolTip = message.Message;
		}
예제 #15
0
		static void NotifyError (LogMessage message)
		{
			if (!errorNotificationEnabled)
				return;
			ClearErrorIcon ();
			Gdk.Pixbuf pix = ImageService.GetPixbuf (Gtk.Stock.DialogError, Gtk.IconSize.Menu);
			errorIcon = IdeApp.Workbench.StatusBar.ShowStatusIcon (pix);
			errorIcon.EventBox.ButtonPressEvent += new Gtk.ButtonPressEventHandler (OnShowLogPad);
			errorIcon.SetAlertMode (5);
			errorIcon.ToolTip = message.Message;
		}