static void handle_new_progress_info (NemoProgressUIHandler *self, NemoProgressInfo *info) { g_signal_connect (info, "finished", G_CALLBACK (progress_info_finished_cb), self); self->priv->active_infos++; if (self->priv->active_infos == 1) { /* this is the only active operation, present the window */ progress_ui_handler_add_to_window (self, info); gtk_window_present (GTK_WINDOW (self->priv->progress_window)); } else { if (gtk_widget_get_visible (self->priv->progress_window)) { progress_ui_handler_add_to_window (self, info); } else { progress_ui_handler_update_notification_or_status (self); } } #ifdef HAVE_UNITY progress_ui_handler_update_unity_launcher (self, info, TRUE); #endif }
static void progress_info_finished_cb (NautilusProgressInfo *info, NautilusProgressUIHandler *self) { self->priv->active_infos--; if (self->priv->active_infos > 0) { if (!gtk_widget_get_visible (self->priv->progress_window)) { progress_ui_handler_update_notification_or_status (self); } } else { if (gtk_widget_get_visible (self->priv->progress_window)) { gtk_widget_hide (self->priv->progress_window); } else { progress_ui_handler_hide_notification_or_status (self); progress_ui_handler_show_complete_notification (self); } } }
static void progress_info_finished_cb (NemoProgressInfo *info, NemoProgressUIHandler *self) { self->priv->active_infos--; if (self->priv->active_infos > 0) { if (!gtk_widget_get_visible (self->priv->progress_window)) { progress_ui_handler_update_notification_or_status (self); } } else { if (gtk_widget_get_visible (self->priv->progress_window)) { gtk_widget_hide (self->priv->progress_window); } else { progress_ui_handler_hide_notification_or_status (self); progress_ui_handler_show_complete_notification (self); } } #ifdef HAVE_UNITY progress_ui_handler_update_unity_launcher (self, info, FALSE); #endif }