コード例 #1
0
 public void SetAlertMode(int seconds)
 {
     if (wrapped != null)
     {
         wrapped.SetAlertMode(seconds);
     }
 }
コード例 #2
0
ファイル: DebuggingService.cs プロジェクト: thild/monodevelop
 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;
        }
コード例 #9
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);
    }
コード例 #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
ファイル: InternalLog.cs プロジェクト: riverans/monodevelop
		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
ファイル: InternalLog.cs プロジェクト: nieve/monodevelop
		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;
		}