Fixes for #135333, analysed by Damon Chaplin:

Thu Feb 26 23:39:07 2004  Matthias Clasen  <maclas@gmx.de>

	Fixes for #135333, analysed by Damon Chaplin:

	* gtk/gtkcombobox.c (gtk_combo_box_list_button_pressed): Don't
	grab here.
	* gtk/gtkcombobox.c (gtk_combo_box_popup): Do the grabs here,
	so that we don't forget to grab when the menu is popped via
	keynav.
	* gtk/gtkcombobox.c (gtk_combo_box_list_button_released): Don't
	ungrab here.
	* gtk/gtkcombobox.c (gtk_combo_box_popdown): Do the ungrabs here.
This commit is contained in:
Matthias Clasen 2004-02-26 22:40:12 +00:00 committed by Matthias Clasen
parent 9c12d8e463
commit 061b9024ed
6 changed files with 75 additions and 15 deletions

View File

@ -1,3 +1,16 @@
Thu Feb 26 23:39:07 2004 Matthias Clasen <maclas@gmx.de>
Fixes for #135333, analysed by Damon Chaplin:
* gtk/gtkcombobox.c (gtk_combo_box_list_button_pressed): Don't
grab here.
* gtk/gtkcombobox.c (gtk_combo_box_popup): Do the grabs here,
so that we don't forget to grab when the menu is popped via
keynav.
* gtk/gtkcombobox.c (gtk_combo_box_list_button_released): Don't
ungrab here.
* gtk/gtkcombobox.c (gtk_combo_box_popdown): Do the ungrabs here.
Thu Feb 26 23:26:00 2004 Soeren Sandmann <sandmann@daimi.au.dk>
* gtk/gtkstatusbar.c (set_grip_cursor): New function. Use resize

View File

@ -1,3 +1,16 @@
Thu Feb 26 23:39:07 2004 Matthias Clasen <maclas@gmx.de>
Fixes for #135333, analysed by Damon Chaplin:
* gtk/gtkcombobox.c (gtk_combo_box_list_button_pressed): Don't
grab here.
* gtk/gtkcombobox.c (gtk_combo_box_popup): Do the grabs here,
so that we don't forget to grab when the menu is popped via
keynav.
* gtk/gtkcombobox.c (gtk_combo_box_list_button_released): Don't
ungrab here.
* gtk/gtkcombobox.c (gtk_combo_box_popdown): Do the ungrabs here.
Thu Feb 26 23:26:00 2004 Soeren Sandmann <sandmann@daimi.au.dk>
* gtk/gtkstatusbar.c (set_grip_cursor): New function. Use resize

View File

@ -1,3 +1,16 @@
Thu Feb 26 23:39:07 2004 Matthias Clasen <maclas@gmx.de>
Fixes for #135333, analysed by Damon Chaplin:
* gtk/gtkcombobox.c (gtk_combo_box_list_button_pressed): Don't
grab here.
* gtk/gtkcombobox.c (gtk_combo_box_popup): Do the grabs here,
so that we don't forget to grab when the menu is popped via
keynav.
* gtk/gtkcombobox.c (gtk_combo_box_list_button_released): Don't
ungrab here.
* gtk/gtkcombobox.c (gtk_combo_box_popdown): Do the ungrabs here.
Thu Feb 26 23:26:00 2004 Soeren Sandmann <sandmann@daimi.au.dk>
* gtk/gtkstatusbar.c (set_grip_cursor): New function. Use resize

View File

@ -1,3 +1,16 @@
Thu Feb 26 23:39:07 2004 Matthias Clasen <maclas@gmx.de>
Fixes for #135333, analysed by Damon Chaplin:
* gtk/gtkcombobox.c (gtk_combo_box_list_button_pressed): Don't
grab here.
* gtk/gtkcombobox.c (gtk_combo_box_popup): Do the grabs here,
so that we don't forget to grab when the menu is popped via
keynav.
* gtk/gtkcombobox.c (gtk_combo_box_list_button_released): Don't
ungrab here.
* gtk/gtkcombobox.c (gtk_combo_box_popdown): Do the ungrabs here.
Thu Feb 26 23:26:00 2004 Soeren Sandmann <sandmann@daimi.au.dk>
* gtk/gtkstatusbar.c (set_grip_cursor): New function. Use resize

View File

@ -1,3 +1,16 @@
Thu Feb 26 23:39:07 2004 Matthias Clasen <maclas@gmx.de>
Fixes for #135333, analysed by Damon Chaplin:
* gtk/gtkcombobox.c (gtk_combo_box_list_button_pressed): Don't
grab here.
* gtk/gtkcombobox.c (gtk_combo_box_popup): Do the grabs here,
so that we don't forget to grab when the menu is popped via
keynav.
* gtk/gtkcombobox.c (gtk_combo_box_list_button_released): Don't
ungrab here.
* gtk/gtkcombobox.c (gtk_combo_box_popdown): Do the ungrabs here.
Thu Feb 26 23:26:00 2004 Soeren Sandmann <sandmann@daimi.au.dk>
* gtk/gtkstatusbar.c (set_grip_cursor): New function. Use resize

View File

@ -885,6 +885,15 @@ gtk_combo_box_popup (GtkComboBox *combo_box)
FALSE, GDK_CURRENT_TIME);
gtk_widget_grab_focus (combo_box->priv->tree_view);
}
gtk_grab_add (combo_box->priv->popup_window);
gdk_pointer_grab (combo_box->priv->popup_window->window, TRUE,
GDK_BUTTON_PRESS_MASK |
GDK_BUTTON_RELEASE_MASK |
GDK_POINTER_MOTION_MASK,
NULL, NULL, GDK_CURRENT_TIME);
gtk_grab_add (combo_box->priv->tree_view);
}
/**
@ -909,6 +918,7 @@ gtk_combo_box_popdown (GtkComboBox *combo_box)
return;
}
gtk_combo_box_list_remove_grabs (combo_box);
gtk_widget_hide_all (combo_box->priv->popup_window);
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (combo_box->priv->button),
FALSE);
@ -1974,15 +1984,6 @@ gtk_combo_box_list_button_pressed (GtkWidget *widget,
gtk_combo_box_popup (combo_box);
gtk_grab_add (combo_box->priv->popup_window);
gdk_pointer_grab (combo_box->priv->popup_window->window, TRUE,
GDK_BUTTON_PRESS_MASK |
GDK_BUTTON_RELEASE_MASK |
GDK_POINTER_MOTION_MASK,
NULL, NULL, GDK_CURRENT_TIME);
gtk_grab_add (combo_box->priv->tree_view);
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (combo_box->priv->button),
TRUE);
@ -2017,7 +2018,6 @@ gtk_combo_box_list_button_released (GtkWidget *widget,
!popup_in_progress &&
gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON (combo_box->priv->button)))
{
gtk_combo_box_list_remove_grabs (combo_box);
gtk_combo_box_popdown (combo_box);
return TRUE;
}
@ -2025,7 +2025,6 @@ gtk_combo_box_list_button_released (GtkWidget *widget,
/* released outside treeview */
if (ewidget != combo_box->priv->button)
{
gtk_combo_box_list_remove_grabs (combo_box);
gtk_combo_box_popdown (combo_box);
return TRUE;
@ -2034,9 +2033,6 @@ gtk_combo_box_list_button_released (GtkWidget *widget,
return FALSE;
}
/* drop grabs */
gtk_combo_box_list_remove_grabs (combo_box);
/* select something cool */
ret = gtk_tree_view_get_path_at_pos (GTK_TREE_VIEW (widget),
event->x, event->y,
@ -2090,7 +2086,6 @@ gtk_combo_box_list_key_press (GtkWidget *widget,
gtk_combo_box_set_active (combo_box,
gtk_combo_box_get_active (combo_box));
gtk_combo_box_list_remove_grabs (combo_box);
gtk_combo_box_popdown (combo_box);
return TRUE;