mirror of
https://gitlab.gnome.org/GNOME/libmks.git
synced 2024-12-22 13:45:21 +00:00
display-picture: set cursor on init
Set cursor to none (i.e., hide it) on init. Otherwise, in cases where the define_cursor signal is not received (e.g., atomic kms), there are two cursors painted on the Widget display. Signed-off-by: Albert Esteve <aesteve@redhat.com>
This commit is contained in:
parent
e8d30c4f73
commit
25b58fc0a2
@ -629,6 +629,7 @@ static void
|
|||||||
mks_display_picture_init (MksDisplayPicture *self)
|
mks_display_picture_init (MksDisplayPicture *self)
|
||||||
{
|
{
|
||||||
GtkEventController *controller;
|
GtkEventController *controller;
|
||||||
|
g_autoptr(GdkCursor) gdk_cursor = gdk_cursor_new_from_name ("none", NULL);
|
||||||
|
|
||||||
controller = gtk_event_controller_legacy_new ();
|
controller = gtk_event_controller_legacy_new ();
|
||||||
g_signal_connect_object (controller,
|
g_signal_connect_object (controller,
|
||||||
@ -661,6 +662,7 @@ mks_display_picture_init (MksDisplayPicture *self)
|
|||||||
self,
|
self,
|
||||||
G_CONNECT_SWAPPED);
|
G_CONNECT_SWAPPED);
|
||||||
|
|
||||||
|
gtk_widget_set_cursor (GTK_WIDGET (self), gdk_cursor);
|
||||||
gtk_widget_set_focusable (GTK_WIDGET (self), TRUE);
|
gtk_widget_set_focusable (GTK_WIDGET (self), TRUE);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user