]> granicus.if.org Git - handbrake/commitdiff
LinGui: bugfix branch, disable status icon progress when status icon is disabled
authorjstebbins <jstebbins.hb@gmail.com>
Thu, 21 Jun 2012 18:31:30 +0000 (18:31 +0000)
committerjstebbins <jstebbins.hb@gmail.com>
Thu, 21 Jun 2012 18:31:30 +0000 (18:31 +0000)
git-svn-id: svn://svn.handbrake.fr/HandBrake/branches/0.9.x@4764 b64f7644-9d1e-0410-96f1-a4d463321fa5

gtk/src/callbacks.c
libhb/decavcodec.c
libhb/encavcodecaudio.c

index d1b11484d1173dad5ed74f897fd3855b34d2985c..5020942b12b11c3d74517fcb66c8dba2103747fa 100644 (file)
@@ -2846,19 +2846,22 @@ ghb_backend_events(signal_user_data_t *ud)
                status_str = searching_status_string(ud, &status.queue);
                label = GTK_LABEL(GHB_WIDGET(ud->builder, "queue_status"));
                gtk_label_set_text (label, status_str);
+               if (ghb_settings_get_boolean(ud->settings, "show_status"))
+               {
 #if !GTK_CHECK_VERSION(2, 16, 0)
-               GtkStatusIcon *si;
+                       GtkStatusIcon *si;
 
-               si = GTK_STATUS_ICON(GHB_OBJECT(ud->builder, "hb_status"));
-               gtk_status_icon_set_tooltip(si, status_str);
+                       si = GTK_STATUS_ICON(GHB_OBJECT(ud->builder, "hb_status"));
+                       gtk_status_icon_set_tooltip(si, status_str);
 #endif
 #if defined(_USE_APP_IND)
-               char * ai_status_str= g_strdup_printf(
-                       "%.2f%%",
-                       100.0 * status.queue.progress);
-               app_indicator_set_label( ud->ai, ai_status_str, "99.99%");
-               g_free(ai_status_str);
+                       char * ai_status_str= g_strdup_printf(
+                               "%.2f%%",
+                               100.0 * status.queue.progress);
+                       app_indicator_set_label( ud->ai, ai_status_str, "99.99%");
+                       g_free(ai_status_str);
 #endif
+               }
                gtk_label_set_text (work_status, status_str);
                gtk_progress_bar_set_fraction (progress, status.queue.progress);
                g_free(status_str);
@@ -2891,20 +2894,23 @@ ghb_backend_events(signal_user_data_t *ud)
                status_str = working_status_string(ud, &status.queue);
                label = GTK_LABEL(GHB_WIDGET(ud->builder, "queue_status"));
                gtk_label_set_text (label, status_str);
+               if (ghb_settings_get_boolean(ud->settings, "show_status"))
+               {
 #if defined(_USE_APP_IND)
-               char * ai_status_str= g_strdup_printf(
-                       "%.2f%%",
-                       100.0 * status.queue.progress);
-               app_indicator_set_label( ud->ai, ai_status_str, "99.99%");
-               g_free(ai_status_str);
+                       char * ai_status_str= g_strdup_printf(
+                               "%.2f%%",
+                               100.0 * status.queue.progress);
+                       app_indicator_set_label( ud->ai, ai_status_str, "99.99%");
+                       g_free(ai_status_str);
 #else
 #if !GTK_CHECK_VERSION(2, 16, 0)
-               GtkStatusIcon *si;
+                       GtkStatusIcon *si;
 
-               si = GTK_STATUS_ICON(GHB_OBJECT(ud->builder, "hb_status"));
-               gtk_status_icon_set_tooltip(si, status_str);
+                       si = GTK_STATUS_ICON(GHB_OBJECT(ud->builder, "hb_status"));
+                       gtk_status_icon_set_tooltip(si, status_str);
 #endif
 #endif
+               }
                gtk_label_set_text (work_status, status_str);
                gtk_progress_bar_set_fraction (progress, status.queue.progress);
                g_free(status_str);
index f0d3756853a32f1700d80ddf9922797dd4590378..c12414b8751d986ec042087af141d4741302ea66 100644 (file)
@@ -38,7 +38,9 @@
 #include "hb.h"
 #include "hbffmpeg.h"
 #include "downmix.h"
-#include "libavcodec/audioconvert.h"
+
+struct AVAudioConvert;
+typedef struct AVAudioConvert AVAudioConvert;
 
 static void compute_frame_duration( hb_work_private_t *pv );
 static void flushDelayQueue( hb_work_private_t *pv );
index 3a23256fa0888afc66037919d60e01c5e64b348f..dad8fa1413aaecfac7f58af81b297b1c8d97a3da 100644 (file)
@@ -7,7 +7,9 @@
 #include "hb.h"
 #include "hbffmpeg.h"
 #include "downmix.h"
-#include "libavcodec/audioconvert.h"
+
+struct AVAudioConvert;
+typedef struct AVAudioConvert AVAudioConvert;
 
 struct hb_work_private_s
 {