[gtk/resizing-fixes: 1/13] window: Stop counting ConfigureRequests
- From: Matthias Clasen <matthiasc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk/resizing-fixes: 1/13] window: Stop counting ConfigureRequests
- Date: Sat, 8 Aug 2020 02:27:27 +0000 (UTC)
commit 81c05b9e1829bf1bfec538cce319beccd3383f7a
Author: Matthias Clasen <mclasen redhat com>
Date: Fri Aug 7 18:02:55 2020 -0400
window: Stop counting ConfigureRequests
Stop counting configure reuqests and stop freezing
the surface ourselves. The backend should do that
if it wants to.
gtk/gtkwindow.c | 25 -------------------------
1 file changed, 25 deletions(-)
---
diff --git a/gtk/gtkwindow.c b/gtk/gtkwindow.c
index d84729442f..8f43a584e4 100644
--- a/gtk/gtkwindow.c
+++ b/gtk/gtkwindow.c
@@ -175,8 +175,6 @@ typedef struct
guint32 initial_timestamp;
- guint16 configure_request_count;
-
guint mnemonics_display_timeout_id;
guint focus_visible_timeout;
@@ -1466,7 +1464,6 @@ gtk_window_init (GtkWindow *window)
priv->geometry_info = NULL;
priv->focus_widget = NULL;
priv->default_widget = NULL;
- priv->configure_request_count = 0;
priv->resizable = TRUE;
priv->configure_notify_received = FALSE;
priv->need_default_size = TRUE;
@@ -3909,11 +3906,6 @@ gtk_window_unmap (GtkWidget *widget)
GTK_WIDGET_CLASS (gtk_window_parent_class)->unmap (widget);
gdk_surface_hide (priv->surface);
- while (priv->configure_request_count > 0)
- {
- priv->configure_request_count--;
- gdk_surface_thaw_toplevel_updates (priv->surface);
- }
priv->configure_notify_received = FALSE;
state = gdk_toplevel_get_state (GDK_TOPLEVEL (priv->surface));
@@ -4740,13 +4732,6 @@ surface_size_changed (GtkWidget *widget,
* priv->configure_request_count notifies.
*/
- if (priv->configure_request_count > 0)
- {
- priv->configure_request_count -= 1;
-
- gdk_surface_thaw_toplevel_updates (priv->surface);
- }
-
/*
* If we do need to resize, we do that by:
* - setting configure_notify_received to TRUE
@@ -5593,16 +5578,6 @@ gtk_window_move_resize (GtkWindow *window)
* we don't get the ConfigureNotify back, the resize queue will never be run.
*/
- /* Increment the number of have-not-yet-received-notify requests.
- * This is done before gdk_surface[_move]_resize(), because
- * that call might be synchronous (depending on which GDK backend
- * is being used), so any preparations for its effects must
- * be done beforehand.
- */
- priv->configure_request_count += 1;
-
- gdk_surface_freeze_toplevel_updates (priv->surface);
-
/* for GTK_RESIZE_QUEUE toplevels, we are now awaiting a new
* configure event in response to our resizing request.
* the configure event will cause a new resize with
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]