diff options
author | jstebbins <[email protected]> | 2014-12-04 21:53:41 +0000 |
---|---|---|
committer | jstebbins <[email protected]> | 2014-12-04 21:53:41 +0000 |
commit | cfec1a964ac58e7830a9f472171a063bbed0342b (patch) | |
tree | 0cec7803be51e012609305103ca0b4d234b7635c /gtk | |
parent | 6747d0d4ae5ab3d94fe986823bc61e68392fb39c (diff) |
LinGui: remove POS appindicator
It's nothing but trouble. Buggy POS ubuntu crapware.
git-svn-id: svn://svn.handbrake.fr/HandBrake/branches/0.10.x@6587 b64f7644-9d1e-0410-96f1-a4d463321fa5
Diffstat (limited to 'gtk')
-rw-r--r-- | gtk/configure.ac | 7 | ||||
-rw-r--r-- | gtk/src/callbacks.c | 51 | ||||
-rw-r--r-- | gtk/src/ghb.ui | 19 | ||||
-rw-r--r-- | gtk/src/internal_defaults.xml | 2 | ||||
-rw-r--r-- | gtk/src/main.c | 23 | ||||
-rw-r--r-- | gtk/src/settings.h | 6 |
6 files changed, 0 insertions, 108 deletions
diff --git a/gtk/configure.ac b/gtk/configure.ac index fac3f167b..7630351d2 100644 --- a/gtk/configure.ac +++ b/gtk/configure.ac @@ -142,13 +142,6 @@ else CFLAGS="$CFLAGS -D_NO_UPDATE_CHECK" fi -PKG_CHECK_MODULES(libappindicator3, appindicator3-0.1, have_appind=yes, have_appind=no) -if test "x$have_appind" = "xyes" ; then - GHB_PACKAGES="$GHB_PACKAGES appindicator3-0.1" - CXXFLAGS="$CXXFLAGS -D_USE_APP_IND" - CFLAGS="$CFLAGS -D_USE_APP_IND" -fi - AM_CONDITIONAL([MINGW], [test "x$mingw_flag" = "xyes"]) PKG_CHECK_MODULES(GHB, [$GHB_PACKAGES]) diff --git a/gtk/src/callbacks.c b/gtk/src/callbacks.c index 03fa96607..cd9e4604d 100644 --- a/gtk/src/callbacks.c +++ b/gtk/src/callbacks.c @@ -60,10 +60,6 @@ #include <dbt.h> #endif -#if defined(_USE_APP_IND) -#include <libappindicator/app-indicator.h> -#endif - #include "hb.h" #include "callbacks.h" #include "queuehandler.h" @@ -3221,16 +3217,6 @@ ghb_backend_events(signal_user_data_t *ud) { gchar *status_str; - if (ghb_settings_get_boolean(ud->prefs, "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); -#endif - } status_str = searching_status_string(ud, &status.queue); gtk_label_set_text (work_status, status_str); gtk_progress_bar_set_fraction (progress, status.queue.progress); @@ -3240,16 +3226,6 @@ ghb_backend_events(signal_user_data_t *ud) { gchar *status_str; - if (ghb_settings_get_boolean(ud->prefs, "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); -#endif - } status_str = working_status_string(ud, &status.queue); gtk_label_set_text (work_status, status_str); gtk_progress_bar_set_fraction (progress, status.queue.progress); @@ -3319,9 +3295,6 @@ ghb_backend_events(signal_user_data_t *ud) } ghb_save_queue(ud->queue); ud->cancel_encode = GHB_CANCEL_NONE; -#if defined(_USE_APP_IND) - app_indicator_set_label( ud->ai, "", "99.99%"); -#endif } else if (status.queue.state & GHB_STATE_MUXING) { @@ -3974,30 +3947,6 @@ use_m4v_changed_cb(GtkWidget *widget, signal_user_data_t *ud) } G_MODULE_EXPORT void -show_status_cb(GtkWidget *widget, signal_user_data_t *ud) -{ - g_debug("show_status_cb"); - ghb_widget_to_setting (ud->prefs, widget); - ghb_check_dependency(ud, widget, NULL); - const gchar *name = ghb_get_setting_key(widget); - ghb_pref_set(ud->prefs, name); - -#if defined(_USE_APP_IND) - if (ud->ai) - { - if (ghb_settings_get_boolean(ud->prefs, "show_status")) - { - app_indicator_set_status(ud->ai, APP_INDICATOR_STATUS_ACTIVE); - } - else - { - app_indicator_set_status(ud->ai, APP_INDICATOR_STATUS_PASSIVE); - } - } -#endif -} - -G_MODULE_EXPORT void vqual_granularity_changed_cb(GtkWidget *widget, signal_user_data_t *ud) { g_debug("vqual_granularity_changed_cb"); diff --git a/gtk/src/ghb.ui b/gtk/src/ghb.ui index 42b82715a..10cd30d60 100644 --- a/gtk/src/ghb.ui +++ b/gtk/src/ghb.ui @@ -7094,25 +7094,6 @@ Resets all queue jobs to pending and ready to run again.</property> <property name="position">4</property> </packing> </child> - <child> - <object class="GtkCheckButton" id="show_status"> - <property name="label" translatable="yes">Show system tray icon</property> - <property name="visible">True</property> - <property name="can_focus">True</property> - <property name="receives_default">False</property> - <property name="halign">start</property> - <property name="draw_indicator">True</property> - <property name="margin-top">6</property> - <property name="margin-bottom">6</property> - <property name="margin-left">12</property> - <signal name="toggled" handler="show_status_cb" swapped="no"/> - </object> - <packing> - <property name="expand">False</property> - <property name="fill">True</property> - <property name="position">5</property> - </packing> - </child> </object> </child> <child type="tab"> diff --git a/gtk/src/internal_defaults.xml b/gtk/src/internal_defaults.xml index d15a5815a..fe817a7ff 100644 --- a/gtk/src/internal_defaults.xml +++ b/gtk/src/internal_defaults.xml @@ -143,8 +143,6 @@ <false /> <key>EncodeLogLocation</key> <false /> - <key>show_status</key> - <true /> <key>allow_tweaks</key> <false /> <key>last_update_check</key> diff --git a/gtk/src/main.c b/gtk/src/main.c index 588dfa761..9973390dc 100644 --- a/gtk/src/main.c +++ b/gtk/src/main.c @@ -47,10 +47,6 @@ #define pipe(phandles) _pipe (phandles, 4096, _O_BINARY) #endif -#if defined(_USE_APP_IND) -#include <libappindicator/app-indicator.h> -#endif - #include <glib/gstdio.h> #include <glib/gi18n.h> #include <gio/gio.h> @@ -1044,25 +1040,6 @@ main(int argc, char *argv[]) ghb_volname_cache_init(); GHB_THREAD_NEW("Cache Volume Names", (GThreadFunc)ghb_cache_volnames, ud); -#if defined(_USE_APP_IND) - GtkMenu *ai_menu = GTK_MENU(GHB_OBJECT(ud->builder, "tray_menu")); - ud->ai = app_indicator_new("HandBrake", "hb-icon", APP_INDICATOR_CATEGORY_APPLICATION_STATUS); - app_indicator_set_menu( ud->ai, ai_menu ); - app_indicator_set_label( ud->ai, "", "99.99%"); - if (ghb_settings_get_boolean(ud->prefs, "show_status")) - { - app_indicator_set_status( ud->ai, APP_INDICATOR_STATUS_ACTIVE ); - } - else - { - app_indicator_set_status( ud->ai, APP_INDICATOR_STATUS_PASSIVE ); - } -#else - // gtk-3 has eliminated status icons. Remove the option from preferences - GtkWidget *status_icon_pref = GHB_WIDGET(ud->builder, "show_status"); - gtk_widget_set_visible(status_icon_pref, FALSE); -#endif - GtkWidget *ghb_window = GHB_WIDGET(ud->builder, "hb_window"); gint window_width, window_height; diff --git a/gtk/src/settings.h b/gtk/src/settings.h index 67f49e5df..2367bcb6a 100644 --- a/gtk/src/settings.h +++ b/gtk/src/settings.h @@ -17,9 +17,6 @@ #define _SETTINGS_H_ #include <gtk/gtk.h> -#if defined(_USE_APP_IND) -#include <libappindicator/app-indicator.h> -#endif #define GHB_WIDGET(b,n) GTK_WIDGET(gtk_builder_get_object ((b), (n))) //#define GHB_WIDGET(b,n) GTK_WIDGET(debug_get_object((b), (n))) @@ -71,9 +68,6 @@ typedef struct gchar *appcast; gint appcast_len; GdkVisibilityState hb_visibility; -#if defined(_USE_APP_IND) - AppIndicator *ai; -#endif } signal_user_data_t; enum |