mirror of
https://gitlab.gnome.org/GNOME/calls.git
synced 2024-12-04 19:07:39 +00:00
record-row: Only popup context menu if row is realized
This works around the long press gesture (mis?) firing the "press" signal on a row that is not realized anymore (because the slice model in the history box currently rebuilds all rows when the items change). Fixes: https://gitlab.gnome.org/GNOME/calls/-/issues/666 Part-of: <https://gitlab.gnome.org/GNOME/calls/-/merge_requests/755>
This commit is contained in:
parent
d9e6fb3717
commit
b15d557106
1 changed files with 5 additions and 0 deletions
|
@ -384,6 +384,11 @@ on_long_pressed (GtkGestureLongPress *gesture,
|
||||||
gdouble y,
|
gdouble y,
|
||||||
GtkWidget *self)
|
GtkWidget *self)
|
||||||
{
|
{
|
||||||
|
if (!gtk_widget_get_realized (self)) {
|
||||||
|
g_warning ("widget is not realized, why does it emit 'pressed'? Aborting..");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
context_menu (self, NULL);
|
context_menu (self, NULL);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue