private void HandleEditorFocusOutEvent(object o, Gtk.FocusOutEventArgs args)
 {
     if (!args.Event.In)
     {
         CommitEditCore();
     }
 }
 void TextView_FocusOutEvent(object o, Gtk.FocusOutEventArgs args)
 {
     // On Windows code completion popup stays TopMost also when switching to other apps
     // but on Mac code completion window hides and shows when focus goes out and back in
     // so no need to hide it on Mac for better UX
     if (MonoDevelop.Core.Platform.IsWindows)
     {
         CompletionWindowManager.HideWindow();
     }
 }
Beispiel #3
0
            public override void FocusOutEvent(object o, Gtk.FocusOutEventArgs args)
            {
                base.FocusOutEvent(o, args);
                var handler = Handler;

                if (handler != null)
                {
                    handler.lastSelection = handler.Selection;
                }
            }
Beispiel #4
0
 void OnEditorFocusOut(object sender, Gtk.FocusOutEventArgs args)
 {
     // TODO: Duplicated from Update(); refactor instead
     if (editing_title)
     {
         Changed();
         UpdateNoteTitle();
         editing_title = false;
     }
 }
Beispiel #5
0
            public virtual void FocusOutEvent(object o, Gtk.FocusOutEventArgs args)
            {
                // Handler can be null here after window is closed
                var handler = Handler;

                if (handler != null)
                {
                    handler.Callback.OnLostFocus(Handler.Widget, EventArgs.Empty);
                }
            }
Beispiel #6
0
        private void _OnFocusOut(object sender, Gtk.FocusOutEventArgs e)
        {
            Trace.Call(sender, e);

            if (Frontend.MainWindow.CaretMode)
            {
                return;
            }

            // we can't just move to focus directly back as that breaks the
            // notebook scrolling, see trac bug#11

            // grant the user 250ms to start a selection
            GLib.Timeout.Add(250, new GLib.TimeoutHandler(delegate {
                // TODO: check mouse buttons, if left mouse button is still pressed
                // we should not interrupt either, as the user is going to make a selection!

                // don't interrupt on-going entry selections
                int start, end;
                if (GetSelectionBounds(out start, out end))
                {
#if LOG4NET
                    //_Logger.Debug("_OnFocusOut(): Entry has on-going selection, waiting...");
#endif
                    return(true);
                }

                ChatView chat = ChatViewManager.CurrentChatView;
                if (chat == null)
                {
                    return(false);
                }

                // don't interrupt on-going selections
                if (chat.HasSelection && chat.HasFocus)
                {
#if LOG4NET
                    //_Logger.Debug("_OnFocusOut(): CurrentChatView has on-going selection, waiting...");
#endif
                    return(true);
                }

                // HACK: for some reason the selection of the TextView gets
                // lost when moving the focus from the TextView to the entry
                // being non-empty. So we empty it, move focus and then set the
                // old value back. GTK+ bug maybe?
                string text = Text;
                Text        = String.Empty;
                HasFocus    = true;
                Text        = text;
                Position    = -1;

                return(false);
            }));
        }
Beispiel #7
0
 void HandleWidgetFocusOutEvent(object o, Gtk.FocusOutEventArgs args)
 {
     Toolkit.Invoke(delegate {
         EventSink.OnLostFocus();
     });
 }
Beispiel #8
0
 protected void MessageFocusOut(object o, Gtk.FocusOutEventArgs args)
 {
     MainWin.PublishMessage = textViewMessage.Buffer.Text;
 }
Beispiel #9
0
 protected virtual void GtkFormsCustomCalendarWindow_FocusOutEvent(object o, Gtk.FocusOutEventArgs args)
 {
     Hide();
 }
Beispiel #10
0
 void HandleFocusOutEvent(object o, Gtk.FocusOutEventArgs args)
 {
     ParameterInformationWindowManager.HideWindow(this, CompletionWidget);
     CompletionWindowManager.HideWindow();
 }
Beispiel #11
0
 void HandleEntryFocusOutEvent(object sender, Gtk.FocusOutEventArgs e)
 {
     OnFocusOut();
 }
Beispiel #12
0
 void Spinbutton1_FocusOutEvent(object o, Gtk.FocusOutEventArgs args)
 {
     _settings.Delay = (int)(spinbutton1.Value);
 }
Beispiel #13
0
 void HandleFocusOutEvent(object o, Gtk.FocusOutEventArgs args)
 {
     Update();
 }
Beispiel #14
0
 private void SearchFocusOutEvent(object o, Gtk.FocusOutEventArgs args)
 {
     ElementController?.SetValueFromRenderer(VisualElement.IsFocusedPropertyKey, false);
 }
Beispiel #15
0
 /// <summary>
 /// Handles the rom list FocusOut event.
 /// </summary>
 /// <param name="o">The ROM list Gtk.TreeView.</param>
 /// <param name="args">The event data.</param>
 protected void HandleRomListFocusOut(object o, Gtk.FocusOutEventArgs args)
 {
     ViewModel.ListHasFocus = false;
 }
Beispiel #16
0
 private void OnLostKeyboardFocus(object sender, Gtk.FocusOutEventArgs e) => this.Dismiss();
Beispiel #17
0
 void OnFocusOutEvent(object o, Gtk.FocusOutEventArgs args)
 {
     SetPlaceholderText(true);
 }
Beispiel #18
0
 protected virtual void OnFocusOutEvent(object o, Gtk.FocusOutEventArgs args)
 {
     this.Hide();
 }
Beispiel #19
0
 private void Parent_FocusOutEvent(object o, Gtk.FocusOutEventArgs args)
 {
     IsFocused = false;
 }
 protected virtual void OnEntryFocusOut(object o, Gtk.FocusOutEventArgs args)
 {
     this.QueueDraw();
 }
Beispiel #21
0
 void FolderEntry_FocusOutEvent(object o, Gtk.FocusOutEventArgs args)
 {
     _settings.Folder = folderEntry.Text;
 }
Beispiel #22
0
 public void FocusOutEvent(object o, Gtk.FocusOutEventArgs args)
 {
     Handler.Widget.OnLostFocus(EventArgs.Empty);
 }
Beispiel #23
0
 /// <summary>
 /// If the drop down dialog is up and lose focus on the parent field, close it
 /// </summary>
 /// <param name="o"></param>
 /// <param name="args"></param>
 private void Entry_FocusOutEvent(object o, Gtk.FocusOutEventArgs args)
 {
     // if the pull-down is are up, close it
     dlg?.CloseDialog();
 }
Beispiel #24
0
 void HandleWidgetFocusOutEvent(object o, Gtk.FocusOutEventArgs args)
 {
     ApplicationContext.InvokeUserCode(delegate {
         EventSink.OnLostFocus();
     });
 }
Beispiel #25
0
 private void _window_FocusOutEvent(object o, Gtk.FocusOutEventArgs args)
 {
     Instance.TriggerIsActiveChanged(false);
 }
 static void RootWindow_FocusOutEvent(object o, Gtk.FocusOutEventArgs args)
 {
     LinksShown = false;
 }
 private static void HandleFocusOutEvent(object o, Gtk.FocusOutEventArgs args)
 {
     DestroyWindow();
 }