[Xfce4-commits] [panel-plugins/xfce4-timer-plugin] 14/22: Now when stop progress_bar is 0%
noreply at xfce.org
noreply at xfce.org
Sat Dec 30 06:16:35 CET 2017
This is an automated email from the git hooks/post-receive script.
a n d r e p u s h e d a c o m m i t t o b r a n c h m a s t e r
in repository panel-plugins/xfce4-timer-plugin.
commit 7336ca6f9fd54fc5b996f7364f416608cee5d989
Author: Daniel Muñiz Fontoira <dani at damufo.com>
Date: Wed Dec 13 12:03:50 2017 +0100
Now when stop progress_bar is 0%
This behavior makes it easier to know when it is started.
---
panel-plugin/xfcetimer.c | 10 ++++++----
1 file changed, 6 insertions(+), 4 deletions(-)
diff --git a/panel-plugin/xfcetimer.c b/panel-plugin/xfcetimer.c
index 66e8ae1..095947f 100644
--- a/panel-plugin/xfcetimer.c
+++ b/panel-plugin/xfcetimer.c
@@ -168,14 +168,14 @@ static gboolean update_function (gpointer data){
/* Disable tooltips, reset pbar */
gtk_widget_set_tooltip_text (GTK_WIDGET(pd->base), "");
- gtk_progress_bar_set_fraction(GTK_PROGRESS_BAR(pd->pbar),1);
+ gtk_progress_bar_set_fraction(GTK_PROGRESS_BAR(pd->pbar),0);
pd->timeout=0;
pd->timer_on=FALSE;
if( (strlen(pd->timeout_command)==0) || !pd->nowin_if_alarm ) {
- gtk_progress_bar_set_fraction(GTK_PROGRESS_BAR(pd->pbar),1);
+ gtk_progress_bar_set_fraction(GTK_PROGRESS_BAR(pd->pbar),0);
/* Display the name of the alarm when the countdown ends */
dialog_message = g_strdup_printf(_("Beeep! :) \nTime is up for the alarm %s."), pd->active_timer_name);
@@ -281,6 +281,8 @@ static void start_timer (plugin_data *pd){
alrm = (alarm_t *) pd->selected->data;
+ gtk_progress_bar_set_fraction(GTK_PROGRESS_BAR(pd->pbar),1);
+
/* Record the timer name */
if (pd->active_timer_name)
g_free(pd->active_timer_name);
@@ -380,7 +382,7 @@ static void start_stop_selected (GtkWidget* menuitem, gpointer
/* Disable tooltips, reset pbar */
gtk_widget_set_tooltip_text (GTK_WIDGET(pd->base), "");
- gtk_progress_bar_set_fraction(GTK_PROGRESS_BAR(pd->pbar),1);
+ gtk_progress_bar_set_fraction(GTK_PROGRESS_BAR(pd->pbar),0);
return;
@@ -1813,7 +1815,7 @@ static void create_plugin_control (XfcePanelPlugin *plugin)
load_settings(pd);
pd->selected = pd->alarm_list;
- gtk_progress_bar_set_fraction(GTK_PROGRESS_BAR(pd->pbar),1);
+ gtk_progress_bar_set_fraction(GTK_PROGRESS_BAR(pd->pbar),0);
add_pbar(pd->base,pd);
--
To stop receiving notification emails like this one, please contact
the administrator of this repository.
More information about the Xfce4-commits
mailing list