sdgtk: don't follow our own selection
When the main window is focused, we are probably the owner of it.
This commit is contained in:
parent
aa19848499
commit
e47667b28a
|
@ -214,6 +214,7 @@ on_selection (GtkClipboard *clipboard, GdkEvent *event,
|
||||||
G_GNUC_UNUSED gpointer data)
|
G_GNUC_UNUSED gpointer data)
|
||||||
{
|
{
|
||||||
if (g.watch_selection
|
if (g.watch_selection
|
||||||
|
&& !gtk_window_has_toplevel_focus (GTK_WINDOW (g.window))
|
||||||
&& event->owner_change.owner != NULL)
|
&& event->owner_change.owner != NULL)
|
||||||
gtk_clipboard_request_text (clipboard, on_selection_received, NULL);
|
gtk_clipboard_request_text (clipboard, on_selection_received, NULL);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue