PhoshHome: Reset overview when folding ends instead of when unfolding starts

Resetting the app grid from filtered state can take a noticeable
amount of time. Do it when folding animation ends, when it's
far less likely that the user wants to interact with the shell,
rather than when unfolding animation starts, which is almost
guaranteed to be done because of user action. Thanks to that
the shell can respond faster.
parent 1fd951a8
Pipeline #64347 passed with stages
in 72 minutes and 20 seconds
......@@ -463,8 +463,10 @@ animate_cb(GtkWidget *widget,
phosh_home_resize (self);
if (finished) {
if (self->state == PHOSH_HOME_STATE_FOLDED)
if (self->state == PHOSH_HOME_STATE_FOLDED) {
gtk_widget_hide (GTK_WIDGET (self->overview));
phosh_overview_reset (PHOSH_OVERVIEW (self->overview));
}
return G_SOURCE_REMOVE;
}
......@@ -504,7 +506,6 @@ phosh_home_set_state (PhoshHome *self, PhoshHomeState state)
if (state == PHOSH_HOME_STATE_UNFOLDED) {
kbd_interactivity = TRUE;
phosh_overview_reset (PHOSH_OVERVIEW (self->overview));
gtk_widget_show (GTK_WIDGET (self->overview));
} else {
kbd_interactivity = FALSE;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment