summaryrefslogtreecommitdiffstats
path: root/gtk
diff options
context:
space:
mode:
authorjstebbins <[email protected]>2008-11-09 19:12:00 +0000
committerjstebbins <[email protected]>2008-11-09 19:12:00 +0000
commitad1d412f8e4cddd7685aa6421fb78fd2b08973ff (patch)
treecb2e9f46635808123b7fb56bd102ad8727e75c3f /gtk
parentc512791d812b8b559287b54f6a735fde25bdfa7f (diff)
LinGui: add update checking. shows a dialog similar to the macui when
an update is available, but without the "install" option. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@1910 b64f7644-9d1e-0410-96f1-a4d463321fa5
Diffstat (limited to 'gtk')
-rw-r--r--gtk/configure.ac2
-rw-r--r--gtk/src/Makefile.am2
-rw-r--r--gtk/src/callbacks.c228
-rw-r--r--gtk/src/callbacks.h1
-rw-r--r--gtk/src/ghb.ui161
-rw-r--r--gtk/src/internal_defaults.xml2
-rw-r--r--gtk/src/main.c8
-rw-r--r--gtk/src/resource_data.h250
-rw-r--r--gtk/src/resources.plist163
-rw-r--r--gtk/src/settings.h2
10 files changed, 808 insertions, 11 deletions
diff --git a/gtk/configure.ac b/gtk/configure.ac
index 88e882b5a..6b051ebd3 100644
--- a/gtk/configure.ac
+++ b/gtk/configure.ac
@@ -70,7 +70,7 @@ PKG_CHECK_MODULES(GHBTOOLS, [glib-2.0 gobject-2.0 gdk-pixbuf-2.0])
AC_SUBST(GHBTOOLS_CFLAGS)
AC_SUBST(GHBTOOLS_LIBS)
-PKG_CHECK_MODULES(GHB, [gtk+-2.0 >= 2.8 gio-2.0 hal hal-storage])
+PKG_CHECK_MODULES(GHB, [gtk+-2.0 >= 2.8 gio-2.0 hal hal-storage libgtkhtml-3.14])
AC_SUBST(GHB_CFLAGS)
AC_SUBST(GHB_LIBS)
diff --git a/gtk/src/Makefile.am b/gtk/src/Makefile.am
index 41881d090..4cae9d35f 100644
--- a/gtk/src/Makefile.am
+++ b/gtk/src/Makefile.am
@@ -105,6 +105,8 @@ ghb_SOURCES = \
icon_tools.h \
values.c \
values.h \
+ appcast.c \
+ appcast.h \
plist.c \
plist.h \
hb-backend.c \
diff --git a/gtk/src/callbacks.c b/gtk/src/callbacks.c
index 515acb5b0..f7e55189e 100644
--- a/gtk/src/callbacks.c
+++ b/gtk/src/callbacks.c
@@ -19,8 +19,11 @@
#include <poll.h>
#include <fcntl.h>
#include <sys/stat.h>
+#include <netinet/in.h>
+#include <netdb.h>
#include <libhal-storage.h>
#include <gtk/gtk.h>
+#include <gtkhtml/gtkhtml.h>
#include <gdk/gdkkeysyms.h>
#include <glib/gstdio.h>
#include <gio/gio.h>
@@ -34,6 +37,7 @@
#include "presets.h"
#include "values.h"
#include "plist.h"
+#include "appcast.h"
#include "hb-backend.h"
#include "ghb-dvd.h"
#include "ghbcellrenderertext.h"
@@ -2013,12 +2017,13 @@ about_activate_cb(GtkWidget *xwidget, signal_user_data_t *ud)
gtk_widget_show (widget);
}
-void
-guide_activate_cb(GtkWidget *xwidget, signal_user_data_t *ud)
+static void
+browse_url(const gchar *url)
{
gboolean result;
char *argv[] =
- {"xdg-open","http://trac.handbrake.fr/wiki/HandBrakeGuide",NULL,NULL};
+ {"xdg-open",NULL,NULL,NULL};
+ argv[1] = (gchar*)url;
result = g_spawn_async(NULL, argv, NULL, G_SPAWN_SEARCH_PATH, NULL,
NULL, NULL, NULL);
if (result) return;
@@ -2040,7 +2045,12 @@ guide_activate_cb(GtkWidget *xwidget, signal_user_data_t *ud)
argv[2] = NULL;
result = g_spawn_async(NULL, argv, NULL, G_SPAWN_SEARCH_PATH, NULL,
NULL, NULL, NULL);
- if (result) return;
+}
+
+void
+guide_activate_cb(GtkWidget *xwidget, signal_user_data_t *ud)
+{
+ browse_url("http://trac.handbrake.fr/wiki/HandBrakeGuide");
}
void
@@ -2728,3 +2738,213 @@ format_vquality_cb(GtkScale *scale, gdouble val, signal_user_data_t *ud)
return g_strdup_printf("%.1f", val);
}
}
+
+static void
+html_link_cb(GtkHTML *html, const gchar *url, signal_user_data_t *ud)
+{
+ browse_url(url);
+}
+
+static gboolean check_stable_update(signal_user_data_t *ud);
+static gboolean stable_update_lock = FALSE;
+
+static void
+process_appcast(signal_user_data_t *ud)
+{
+ gchar *description = NULL, *build = NULL, *version = NULL, *msg;
+ GtkWidget *html, *window, *dialog, *label;
+ gint response, ibuild = 0, skip;
+
+ if (ud->appcast == NULL || ud->appcast_len < 15 ||
+ strncmp(&(ud->appcast[9]), "200 OK", 6))
+ {
+ if (!stable_update_lock && HB_BUILD % 100)
+ g_idle_add((GSourceFunc)check_stable_update, ud);
+ goto done;
+ }
+ ghb_appcast_parse(ud->appcast, &description, &build, &version);
+ if (build)
+ ibuild = g_strtod(build, NULL);
+ skip = ghb_settings_get_int(ud->settings, "update_skip_version");
+ if (description == NULL || build == NULL || version == NULL
+ || ibuild <= HB_BUILD || skip == ibuild)
+ {
+ if (!stable_update_lock && HB_BUILD % 100)
+ g_idle_add((GSourceFunc)check_stable_update, ud);
+ goto done;
+ }
+ msg = g_strdup_printf("HandBrake %s/%s is now available (you have %s/%d).",
+ version, build, HB_VERSION, HB_BUILD);
+ label = GHB_WIDGET(ud->builder, "update_message");
+ gtk_label_set_text(GTK_LABEL(label), msg);
+ html = gtk_html_new_from_string(description, -1);
+ g_signal_connect(html, "link_clicked", G_CALLBACK(html_link_cb), ud);
+ window = GHB_WIDGET(ud->builder, "update_scroll");
+ gtk_container_add(GTK_CONTAINER(window), html);
+ // Show it
+ dialog = GHB_WIDGET(ud->builder, "update_dialog");
+ gtk_widget_set_size_request(html, 420, 240);
+ gtk_widget_show(html);
+ response = gtk_dialog_run(GTK_DIALOG(dialog));
+ gtk_widget_hide(dialog);
+ gtk_widget_destroy(html);
+ if (response == GTK_RESPONSE_OK)
+ {
+ // Skip
+ ghb_settings_set_int(ud->settings, "update_skip_version", ibuild);
+ ghb_pref_save(ud->settings, "update_skip_version");
+ }
+ g_free(msg);
+
+done:
+ if (description) g_free(description);
+ if (build) g_free(build);
+ if (version) g_free(version);
+ g_free(ud->appcast);
+ ud->appcast_len = 0;
+ ud->appcast = NULL;
+}
+
+void
+ghb_net_close(GIOChannel *ioc)
+{
+ gint fd;
+
+ g_debug("ghb_net_close");
+ fd = g_io_channel_unix_get_fd(ioc);
+ close(fd);
+ g_io_channel_unref(ioc);
+}
+
+gboolean
+ghb_net_recv_cb(GIOChannel *ioc, GIOCondition cond, gpointer data)
+{
+ gchar buf[2048];
+ gsize len;
+ GError *gerror = NULL;
+ GIOStatus status;
+
+ g_debug("ghb_net_recv_cb");
+ signal_user_data_t *ud = (signal_user_data_t*)data;
+
+ status = g_io_channel_read_chars (ioc, buf, 2048, &len, &gerror);
+ if ((status == G_IO_STATUS_NORMAL || status == G_IO_STATUS_EOF) &&
+ len > 0)
+ {
+ gint new_len = ud->appcast_len + len;
+ ud->appcast = g_realloc(ud->appcast, new_len + 1);
+ memcpy(&(ud->appcast[ud->appcast_len]), buf, len);
+ ud->appcast_len = new_len;
+ }
+ if (status == G_IO_STATUS_EOF)
+ {
+ ud->appcast[ud->appcast_len] = 0;
+ process_appcast(ud);
+ ghb_net_close(ioc);
+ return FALSE;
+ }
+ return TRUE;
+}
+
+static gboolean
+appcast_timeout_cb(GIOChannel *ioc)
+{
+ g_debug("appcast_timeout_cb");
+ ghb_net_close(ioc);
+ return FALSE;
+}
+
+GIOChannel*
+ghb_net_open(signal_user_data_t *ud, gchar *address, gint port)
+{
+ GIOChannel *ioc;
+ gint fd;
+
+ struct sockaddr_in sock;
+ struct hostent * host;
+
+ g_debug("ghb_net_open");
+ if( !( host = gethostbyname( address ) ) )
+ {
+ g_warning( "gethostbyname failed (%s)", address );
+ return NULL;
+ }
+
+ memset( &sock, 0, sizeof( struct sockaddr_in ) );
+ sock.sin_family = host->h_addrtype;
+ sock.sin_port = htons( port );
+ memcpy( &sock.sin_addr, host->h_addr, host->h_length );
+
+ fd = socket(host->h_addrtype, SOCK_STREAM, 0);
+ if( fd < 0 )
+ {
+ g_debug( "socket failed" );
+ return NULL;
+ }
+
+ if(connect(fd, (struct sockaddr*)&sock, sizeof(struct sockaddr_in )) < 0 )
+ {
+ g_debug( "connect failed" );
+ return NULL;
+ }
+ ioc = g_io_channel_unix_new(fd);
+ g_io_channel_set_encoding (ioc, NULL, NULL);
+ g_io_channel_set_flags(ioc, G_IO_FLAG_NONBLOCK, NULL);
+ g_io_add_watch (ioc, G_IO_IN, ghb_net_recv_cb, (gpointer)ud );
+ g_timeout_add_seconds(20, (GSourceFunc)appcast_timeout_cb, ioc);
+
+ return ioc;
+}
+
+gboolean
+ghb_check_update(signal_user_data_t *ud)
+{
+ gchar *query;
+ gsize len;
+ GIOChannel *ioc;
+ GError *gerror = NULL;
+
+ g_debug("ghb_check_update");
+ if (HB_BUILD % 100)
+ {
+ query =
+ "GET /appcast_unstable.xml HTTP/1.0\r\nHost: handbrake.fr\r\n\r\n";
+ }
+ else
+ {
+ stable_update_lock = TRUE;
+ query = "GET /appcast.xml HTTP/1.0\r\nHost: handbrake.fr\r\n\r\n";
+ }
+ ioc = ghb_net_open(ud, "handbrake.fr", 80);
+ if (ioc == NULL)
+ return FALSE;
+
+ g_io_channel_write_chars(ioc, query, strlen(query), &len, &gerror);
+ g_io_channel_flush(ioc, &gerror);
+ // This function is initiated by g_idle_add. Must return false
+ // so that it is not called again
+ return FALSE;
+}
+
+static gboolean
+check_stable_update(signal_user_data_t *ud)
+{
+ gchar *query;
+ gsize len;
+ GIOChannel *ioc;
+ GError *gerror = NULL;
+
+ g_debug("check_stable_update");
+ stable_update_lock = TRUE;
+ query = "GET /appcast.xml HTTP/1.0\r\nHost: handbrake.fr\r\n\r\n";
+ ioc = ghb_net_open(ud, "handbrake.fr", 80);
+ if (ioc == NULL)
+ return FALSE;
+
+ g_io_channel_write_chars(ioc, query, strlen(query), &len, &gerror);
+ g_io_channel_flush(ioc, &gerror);
+ // This function is initiated by g_idle_add. Must return false
+ // so that it is not called again
+ return FALSE;
+}
+
diff --git a/gtk/src/callbacks.h b/gtk/src/callbacks.h
index 26c76861c..7afaf9d14 100644
--- a/gtk/src/callbacks.h
+++ b/gtk/src/callbacks.h
@@ -46,6 +46,7 @@ GValue* ghb_start_next_job(signal_user_data_t *ud, gboolean find_first);
void ghb_check_dependency(signal_user_data_t *ud, GtkWidget *widget);
void ghb_do_scan(signal_user_data_t *ud, const gchar *filename, gboolean force);
void ghb_log(gchar *log, ...);
+gboolean ghb_check_update(signal_user_data_t *ud);
#endif // _CALLBACKS_H_
diff --git a/gtk/src/ghb.ui b/gtk/src/ghb.ui
index 5dc1012c1..c0fc2fccc 100644
--- a/gtk/src/ghb.ui
+++ b/gtk/src/ghb.ui
@@ -4752,4 +4752,165 @@ libxvidcore authors:
</object>
</child>
</object>
+ <object class="GtkDialog" id="update_dialog">
+ <property name="border_width">5</property>
+ <property name="modal">True</property>
+ <property name="window_position">center-on-parent</property>
+ <property name="type_hint">dialog</property>
+ <property name="skip_taskbar_hint">True</property>
+ <property name="skip_pager_hint">True</property>
+ <property name="has_separator">False</property>
+ <child internal-child="vbox">
+ <object class="GtkVBox" id="dialog-vbox6">
+ <property name="visible">True</property>
+ <property name="spacing">2</property>
+ <child>
+ <object class="GtkHBox" id="hbox24">
+ <property name="visible">True</property>
+ <child>
+ <object class="GtkVBox" id="vbox19">
+ <property name="visible">True</property>
+ <child>
+ <object class="GtkEventBox" id="eventbox1">
+ <property name="visible">True</property>
+ <property name="events">GDK_BUTTON_MOTION_MASK | GDK_BUTTON_PRESS_MASK | GDK_STRUCTURE_MASK</property>
+ <property name="visible_window">False</property>
+ <property name="above_child">True</property>
+ <child>
+ <object class="GtkImage" id="image3">
+ <property name="visible">True</property>
+ <property name="events">GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK</property>
+ <property name="icon_name">hb-icon</property>
+ <property name="icon-size">6</property>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkVBox" id="vbox1">
+ <property name="visible">True</property>
+ <child>
+ <object class="GtkLabel" id="label3">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="xpad">10</property>
+ <property name="ypad">5</property>
+ <property name="label" translatable="yes">&lt;b&gt;A new version of HandBrake is available!&lt;/b&gt;</property>
+ <property name="use_markup">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="update_message">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="xpad">10</property>
+ <property name="ypad">5</property>
+ <property name="label" translatable="yes">HandBrake xxx is now available (you have yyy).</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkFrame" id="frame2">
+ <property name="visible">True</property>
+ <property name="label_xalign">0</property>
+ <property name="shadow_type">etched-out</property>
+ <child>
+ <object class="GtkAlignment" id="alignment2">
+ <property name="visible">True</property>
+ <property name="left_padding">12</property>
+ <child>
+ <object class="GtkScrolledWindow" id="update_scroll">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="hscrollbar_policy">automatic</property>
+ <property name="vscrollbar_policy">automatic</property>
+ <child>
+ <placeholder/>
+ </child>
+ </object>
+ </child>
+ </object>
+ </child>
+ <child type="label">
+ <object class="GtkLabel" id="label88">
+ <property name="visible">True</property>
+ <property name="label" translatable="yes">&lt;b&gt;Release Notes&lt;/b&gt;</property>
+ <property name="use_markup">True</property>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="position">2</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ <child internal-child="action_area">
+ <object class="GtkHButtonBox" id="dialog-action_area6">
+ <property name="visible">True</property>
+ <property name="layout_style">end</property>
+ <child>
+ <object class="GtkButton" id="update_skip">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">True</property>
+ <property name="label" translatable="yes">Skip This Version</property>
+ </object>
+ <packing>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkButton" id="update_remind">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">True</property>
+ <property name="label" translatable="yes">Remind Me Later</property>
+ </object>
+ <packing>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="pack_type">end</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ </object>
+ </child>
+ <action-widgets>
+ <action-widget response="-5">update_skip</action-widget>
+ <action-widget response="0">update_remind</action-widget>
+ </action-widgets>
+ </object>
</interface>
diff --git a/gtk/src/internal_defaults.xml b/gtk/src/internal_defaults.xml
index 373f78a97..143223cfd 100644
--- a/gtk/src/internal_defaults.xml
+++ b/gtk/src/internal_defaults.xml
@@ -108,6 +108,8 @@
<true />
<key>use_source_name</key>
<true />
+ <key>update_skip_version</key>
+ <integer>0</integer>
<key>version</key>
<string>0.1</string>
</dict>
diff --git a/gtk/src/main.c b/gtk/src/main.c
index d73538473..08d7ff1a3 100644
--- a/gtk/src/main.c
+++ b/gtk/src/main.c
@@ -515,15 +515,10 @@ main (int argc, char *argv[])
ghb_hal_init();
#endif
- ud = g_malloc(sizeof(signal_user_data_t));
+ ud = g_malloc0(sizeof(signal_user_data_t));
ud->debug = ghb_debug;
- ud->cancel_encode = FALSE;
g_log_set_handler (NULL, G_LOG_LEVEL_DEBUG, debug_log_handler, ud);
ud->settings = ghb_settings_new();
- ud->queue = NULL;
- ud->current_job = NULL;
- ud->current_dvd_device = NULL;
- ud->dont_clear_presets = FALSE;
// Enable events that alert us to media change events
watch_volumes (ud);
ud->builder = create_builder_or_die (BUILDER_NAME);
@@ -617,6 +612,7 @@ main (int argc, char *argv[])
}
// Reload and check status of the last saved queue
g_idle_add((GSourceFunc)ghb_reload_queue, ud);
+ g_idle_add((GSourceFunc)ghb_check_update, ud);
// Start timer for monitoring libhb status, 500ms
g_timeout_add (500, ghb_timer_cb, (gpointer)ud);
// Everything should be go-to-go. Lets rock!
diff --git a/gtk/src/resource_data.h b/gtk/src/resource_data.h
index b61cc75d2..9ffa39077 100644
--- a/gtk/src/resource_data.h
+++ b/gtk/src/resource_data.h
@@ -7654,6 +7654,254 @@
" &lt;/object&gt;\n"
" &lt;/child&gt;\n"
" &lt;/object&gt;\n"
+" &lt;object class=&quot;GtkDialog&quot; id=&quot;update_dialog&quot;&g"
+"t;\n"
+" &lt;property name=&quot;border_width&quot;&gt;5&lt;/property&gt;\n"
+" &lt;property name=&quot;modal&quot;&gt;True&lt;/property&gt;\n"
+" &lt;property name=&quot;window_position&quot;&gt;center-on-parent&l"
+"t;/property&gt;\n"
+" &lt;property name=&quot;type_hint&quot;&gt;dialog&lt;/property&gt;\n"
+" &lt;property name=&quot;skip_taskbar_hint&quot;&gt;True&lt;/propert"
+"y&gt;\n"
+" &lt;property name=&quot;skip_pager_hint&quot;&gt;True&lt;/property&"
+"gt;\n"
+" &lt;property name=&quot;has_separator&quot;&gt;False&lt;/property&g"
+"t;\n"
+" &lt;child internal-child=&quot;vbox&quot;&gt;\n"
+" &lt;object class=&quot;GtkVBox&quot; id=&quot;dialog-vbox6&quot;&"
+"gt;\n"
+" &lt;property name=&quot;visible&quot;&gt;True&lt;/property&gt;\n"
+" &lt;property name=&quot;spacing&quot;&gt;2&lt;/property&gt;\n"
+" &lt;child&gt;\n"
+" &lt;object class=&quot;GtkHBox&quot; id=&quot;hbox24&quot;&gt"
+";\n"
+" &lt;property name=&quot;visible&quot;&gt;True&lt;/property&"
+"gt;\n"
+" &lt;child&gt;\n"
+" &lt;object class=&quot;GtkVBox&quot; id=&quot;vbox19&quot"
+";&gt;\n"
+" &lt;property name=&quot;visible&quot;&gt;True&lt;/prope"
+"rty&gt;\n"
+" &lt;child&gt;\n"
+" &lt;object class=&quot;GtkEventBox&quot; id=&quot;eve"
+"ntbox1&quot;&gt;\n"
+" &lt;property name=&quot;visible&quot;&gt;True&lt;/p"
+"roperty&gt;\n"
+" &lt;property name=&quot;events&quot;&gt;GDK_BUTTON_"
+"MOTION_MASK | GDK_BUTTON_PRESS_MASK | GDK_STRUCTURE_MASK&lt;/property&g"
+"t;\n"
+" &lt;property name=&quot;visible_window&quot;&gt;Fal"
+"se&lt;/property&gt;\n"
+" &lt;property name=&quot;above_child&quot;&gt;True&l"
+"t;/property&gt;\n"
+" &lt;child&gt;\n"
+" &lt;object class=&quot;GtkImage&quot; id=&quot;im"
+"age3&quot;&gt;\n"
+" &lt;property name=&quot;visible&quot;&gt;True&l"
+"t;/property&gt;\n"
+" &lt;property name=&quot;events&quot;&gt;GDK_POI"
+"NTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK"
+" | GDK_BUTTON_RELEASE_MASK&lt;/property&gt;\n"
+" &lt;property name=&quot;icon_name&quot;&gt;hb-i"
+"con&lt;/property&gt;\n"
+" &lt;property name=&quot;icon-size&quot;&gt;6&lt"
+";/property&gt;\n"
+" &lt;/object&gt;\n"
+" &lt;/child&gt;\n"
+" &lt;/object&gt;\n"
+" &lt;packing&gt;\n"
+" &lt;property name=&quot;expand&quot;&gt;False&lt;/p"
+"roperty&gt;\n"
+" &lt;property name=&quot;position&quot;&gt;0&lt;/pro"
+"perty&gt;\n"
+" &lt;/packing&gt;\n"
+" &lt;/child&gt;\n"
+" &lt;child&gt;\n"
+" &lt;placeholder/&gt;\n"
+" &lt;/child&gt;\n"
+" &lt;/object&gt;\n"
+" &lt;packing&gt;\n"
+" &lt;property name=&quot;expand&quot;&gt;False&lt;/prope"
+"rty&gt;\n"
+" &lt;property name=&quot;position&quot;&gt;0&lt;/propert"
+"y&gt;\n"
+" &lt;/packing&gt;\n"
+" &lt;/child&gt;\n"
+" &lt;child&gt;\n"
+" &lt;object class=&quot;GtkVBox&quot; id=&quot;vbox1&quot;"
+"&gt;\n"
+" &lt;property name=&quot;visible&quot;&gt;True&lt;/prope"
+"rty&gt;\n"
+" &lt;child&gt;\n"
+" &lt;object class=&quot;GtkLabel&quot; id=&quot;label3"
+"&quot;&gt;\n"
+" &lt;property name=&quot;visible&quot;&gt;True&lt;/p"
+"roperty&gt;\n"
+" &lt;property name=&quot;xalign&quot;&gt;0&lt;/prope"
+"rty&gt;\n"
+" &lt;property name=&quot;xpad&quot;&gt;10&lt;/proper"
+"ty&gt;\n"
+" &lt;property name=&quot;ypad&quot;&gt;5&lt;/propert"
+"y&gt;\n"
+" &lt;property name=&quot;label&quot; translatable=&q"
+"uot;yes&quot;&gt;&amp;lt;b&amp;gt;A new version of HandBrake is availab"
+"le!&amp;lt;/b&amp;gt;&lt;/property&gt;\n"
+" &lt;property name=&quot;use_markup&quot;&gt;True&lt"
+";/property&gt;\n"
+" &lt;/object&gt;\n"
+" &lt;packing&gt;\n"
+" &lt;property name=&quot;expand&quot;&gt;False&lt;/p"
+"roperty&gt;\n"
+" &lt;property name=&quot;position&quot;&gt;0&lt;/pro"
+"perty&gt;\n"
+" &lt;/packing&gt;\n"
+" &lt;/child&gt;\n"
+" &lt;child&gt;\n"
+" &lt;object class=&quot;GtkLabel&quot; id=&quot;update"
+"_message&quot;&gt;\n"
+" &lt;property name=&quot;visible&quot;&gt;True&lt;/p"
+"roperty&gt;\n"
+" &lt;property name=&quot;xalign&quot;&gt;0&lt;/prope"
+"rty&gt;\n"
+" &lt;property name=&quot;xpad&quot;&gt;10&lt;/proper"
+"ty&gt;\n"
+" &lt;property name=&quot;ypad&quot;&gt;5&lt;/propert"
+"y&gt;\n"
+" &lt;property name=&quot;label&quot; translatable=&q"
+"uot;yes&quot;&gt;HandBrake xxx is now available (you have yyy).&lt;/pro"
+"perty&gt;\n"
+" &lt;/object&gt;\n"
+" &lt;packing&gt;\n"
+" &lt;property name=&quot;expand&quot;&gt;False&lt;/p"
+"roperty&gt;\n"
+" &lt;property name=&quot;position&quot;&gt;1&lt;/pro"
+"perty&gt;\n"
+" &lt;/packing&gt;\n"
+" &lt;/child&gt;\n"
+" &lt;child&gt;\n"
+" &lt;object class=&quot;GtkFrame&quot; id=&quot;frame2"
+"&quot;&gt;\n"
+" &lt;property name=&quot;visible&quot;&gt;True&lt;/p"
+"roperty&gt;\n"
+" &lt;property name=&quot;label_xalign&quot;&gt;0&lt;"
+"/property&gt;\n"
+" &lt;property name=&quot;shadow_type&quot;&gt;etched"
+"-out&lt;/property&gt;\n"
+" &lt;child&gt;\n"
+" &lt;object class=&quot;GtkAlignment&quot; id=&quo"
+"t;alignment2&quot;&gt;\n"
+" &lt;property name=&quot;visible&quot;&gt;True&l"
+"t;/property&gt;\n"
+" &lt;property name=&quot;left_padding&quot;&gt;1"
+"2&lt;/property&gt;\n"
+" &lt;child&gt;\n"
+" &lt;object class=&quot;GtkScrolledWindow&quot"
+"; id=&quot;update_scroll&quot;&gt;\n"
+" &lt;property name=&quot;visible&quot;&gt;Tr"
+"ue&lt;/property&gt;\n"
+" &lt;property name=&quot;can_focus&quot;&gt;"
+"True&lt;/property&gt;\n"
+" &lt;property name=&quot;hscrollbar_policy&q"
+"uot;&gt;automatic&lt;/property&gt;\n"
+" &lt;property name=&quot;vscrollbar_policy&q"
+"uot;&gt;automatic&lt;/property&gt;\n"
+" &lt;child&gt;\n"
+" &lt;placeholder/&gt;\n"
+" &lt;/child&gt;\n"
+" &lt;/object&gt;\n"
+" &lt;/child&gt;\n"
+" &lt;/object&gt;\n"
+" &lt;/child&gt;\n"
+" &lt;child type=&quot;label&quot;&gt;\n"
+" &lt;object class=&quot;GtkLabel&quot; id=&quot;la"
+"bel88&quot;&gt;\n"
+" &lt;property name=&quot;visible&quot;&gt;True&l"
+"t;/property&gt;\n"
+" &lt;property name=&quot;label&quot; translatabl"
+"e=&quot;yes&quot;&gt;&amp;lt;b&amp;gt;Release Notes&amp;lt;/b&amp;gt;&l"
+"t;/property&gt;\n"
+" &lt;property name=&quot;use_markup&quot;&gt;Tru"
+"e&lt;/property&gt;\n"
+" &lt;/object&gt;\n"
+" &lt;/child&gt;\n"
+" &lt;/object&gt;\n"
+" &lt;packing&gt;\n"
+" &lt;property name=&quot;position&quot;&gt;2&lt;/pro"
+"perty&gt;\n"
+" &lt;/packing&gt;\n"
+" &lt;/child&gt;\n"
+" &lt;/object&gt;\n"
+" &lt;packing&gt;\n"
+" &lt;property name=&quot;position&quot;&gt;1&lt;/propert"
+"y&gt;\n"
+" &lt;/packing&gt;\n"
+" &lt;/child&gt;\n"
+" &lt;/object&gt;\n"
+" &lt;packing&gt;\n"
+" &lt;property name=&quot;position&quot;&gt;1&lt;/property&gt"
+";\n"
+" &lt;/packing&gt;\n"
+" &lt;/child&gt;\n"
+" &lt;child internal-child=&quot;action_area&quot;&gt;\n"
+" &lt;object class=&quot;GtkHButtonBox&quot; id=&quot;dialog-ac"
+"tion_area6&quot;&gt;\n"
+" &lt;property name=&quot;visible&quot;&gt;True&lt;/property&"
+"gt;\n"
+" &lt;property name=&quot;layout_style&quot;&gt;end&lt;/prope"
+"rty&gt;\n"
+" &lt;child&gt;\n"
+" &lt;object class=&quot;GtkButton&quot; id=&quot;update_sk"
+"ip&quot;&gt;\n"
+" &lt;property name=&quot;visible&quot;&gt;True&lt;/prope"
+"rty&gt;\n"
+" &lt;property name=&quot;can_focus&quot;&gt;True&lt;/pro"
+"perty&gt;\n"
+" &lt;property name=&quot;receives_default&quot;&gt;True&"
+"lt;/property&gt;\n"
+" &lt;property name=&quot;label&quot; translatable=&quot;"
+"yes&quot;&gt;Skip This Version&lt;/property&gt;\n"
+" &lt;/object&gt;\n"
+" &lt;packing&gt;\n"
+" &lt;property name=&quot;position&quot;&gt;0&lt;/propert"
+"y&gt;\n"
+" &lt;/packing&gt;\n"
+" &lt;/child&gt;\n"
+" &lt;child&gt;\n"
+" &lt;object class=&quot;GtkButton&quot; id=&quot;update_re"
+"mind&quot;&gt;\n"
+" &lt;property name=&quot;visible&quot;&gt;True&lt;/prope"
+"rty&gt;\n"
+" &lt;property name=&quot;can_focus&quot;&gt;True&lt;/pro"
+"perty&gt;\n"
+" &lt;property name=&quot;receives_default&quot;&gt;True&"
+"lt;/property&gt;\n"
+" &lt;property name=&quot;label&quot; translatable=&quot;"
+"yes&quot;&gt;Remind Me Later&lt;/property&gt;\n"
+" &lt;/object&gt;\n"
+" &lt;packing&gt;\n"
+" &lt;property name=&quot;position&quot;&gt;1&lt;/propert"
+"y&gt;\n"
+" &lt;/packing&gt;\n"
+" &lt;/child&gt;\n"
+" &lt;/object&gt;\n"
+" &lt;packing&gt;\n"
+" &lt;property name=&quot;expand&quot;&gt;False&lt;/property&"
+"gt;\n"
+" &lt;property name=&quot;pack_type&quot;&gt;end&lt;/property"
+"&gt;\n"
+" &lt;property name=&quot;position&quot;&gt;0&lt;/property&gt"
+";\n"
+" &lt;/packing&gt;\n"
+" &lt;/child&gt;\n"
+" &lt;/object&gt;\n"
+" &lt;/child&gt;\n"
+" &lt;action-widgets&gt;\n"
+" &lt;action-widget response=&quot;-5&quot;&gt;update_skip&lt;/acti"
+"on-widget&gt;\n"
+" &lt;action-widget response=&quot;0&quot;&gt;update_remind&lt;/act"
+"ion-widget&gt;\n"
+" &lt;/action-widgets&gt;\n"
+" &lt;/object&gt;\n"
"&lt;/interface&gt;\n"
"</string>\n"
" <key>icons</key>\n"
@@ -10169,6 +10417,8 @@
" <true />\n"
" <key>show_presets</key>\n"
" <true />\n"
+" <key>update_skip_version</key>\n"
+" <integer>0</integer>\n"
" <key>use_source_name</key>\n"
" <true />\n"
" <key>version</key>\n"
diff --git a/gtk/src/resources.plist b/gtk/src/resources.plist
index ca929e5b1..2bc58d602 100644
--- a/gtk/src/resources.plist
+++ b/gtk/src/resources.plist
@@ -4757,6 +4757,167 @@ libxvidcore authors:
&lt;/object&gt;
&lt;/child&gt;
&lt;/object&gt;
+ &lt;object class=&quot;GtkDialog&quot; id=&quot;update_dialog&quot;&gt;
+ &lt;property name=&quot;border_width&quot;&gt;5&lt;/property&gt;
+ &lt;property name=&quot;modal&quot;&gt;True&lt;/property&gt;
+ &lt;property name=&quot;window_position&quot;&gt;center-on-parent&lt;/property&gt;
+ &lt;property name=&quot;type_hint&quot;&gt;dialog&lt;/property&gt;
+ &lt;property name=&quot;skip_taskbar_hint&quot;&gt;True&lt;/property&gt;
+ &lt;property name=&quot;skip_pager_hint&quot;&gt;True&lt;/property&gt;
+ &lt;property name=&quot;has_separator&quot;&gt;False&lt;/property&gt;
+ &lt;child internal-child=&quot;vbox&quot;&gt;
+ &lt;object class=&quot;GtkVBox&quot; id=&quot;dialog-vbox6&quot;&gt;
+ &lt;property name=&quot;visible&quot;&gt;True&lt;/property&gt;
+ &lt;property name=&quot;spacing&quot;&gt;2&lt;/property&gt;
+ &lt;child&gt;
+ &lt;object class=&quot;GtkHBox&quot; id=&quot;hbox24&quot;&gt;
+ &lt;property name=&quot;visible&quot;&gt;True&lt;/property&gt;
+ &lt;child&gt;
+ &lt;object class=&quot;GtkVBox&quot; id=&quot;vbox19&quot;&gt;
+ &lt;property name=&quot;visible&quot;&gt;True&lt;/property&gt;
+ &lt;child&gt;
+ &lt;object class=&quot;GtkEventBox&quot; id=&quot;eventbox1&quot;&gt;
+ &lt;property name=&quot;visible&quot;&gt;True&lt;/property&gt;
+ &lt;property name=&quot;events&quot;&gt;GDK_BUTTON_MOTION_MASK | GDK_BUTTON_PRESS_MASK | GDK_STRUCTURE_MASK&lt;/property&gt;
+ &lt;property name=&quot;visible_window&quot;&gt;False&lt;/property&gt;
+ &lt;property name=&quot;above_child&quot;&gt;True&lt;/property&gt;
+ &lt;child&gt;
+ &lt;object class=&quot;GtkImage&quot; id=&quot;image3&quot;&gt;
+ &lt;property name=&quot;visible&quot;&gt;True&lt;/property&gt;
+ &lt;property name=&quot;events&quot;&gt;GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK&lt;/property&gt;
+ &lt;property name=&quot;icon_name&quot;&gt;hb-icon&lt;/property&gt;
+ &lt;property name=&quot;icon-size&quot;&gt;6&lt;/property&gt;
+ &lt;/object&gt;
+ &lt;/child&gt;
+ &lt;/object&gt;
+ &lt;packing&gt;
+ &lt;property name=&quot;expand&quot;&gt;False&lt;/property&gt;
+ &lt;property name=&quot;position&quot;&gt;0&lt;/property&gt;
+ &lt;/packing&gt;
+ &lt;/child&gt;
+ &lt;child&gt;
+ &lt;placeholder/&gt;
+ &lt;/child&gt;
+ &lt;/object&gt;
+ &lt;packing&gt;
+ &lt;property name=&quot;expand&quot;&gt;False&lt;/property&gt;
+ &lt;property name=&quot;position&quot;&gt;0&lt;/property&gt;
+ &lt;/packing&gt;
+ &lt;/child&gt;
+ &lt;child&gt;
+ &lt;object class=&quot;GtkVBox&quot; id=&quot;vbox1&quot;&gt;
+ &lt;property name=&quot;visible&quot;&gt;True&lt;/property&gt;
+ &lt;child&gt;
+ &lt;object class=&quot;GtkLabel&quot; id=&quot;label3&quot;&gt;
+ &lt;property name=&quot;visible&quot;&gt;True&lt;/property&gt;
+ &lt;property name=&quot;xalign&quot;&gt;0&lt;/property&gt;
+ &lt;property name=&quot;xpad&quot;&gt;10&lt;/property&gt;
+ &lt;property name=&quot;ypad&quot;&gt;5&lt;/property&gt;
+ &lt;property name=&quot;label&quot; translatable=&quot;yes&quot;&gt;&amp;lt;b&amp;gt;A new version of HandBrake is available!&amp;lt;/b&amp;gt;&lt;/property&gt;
+ &lt;property name=&quot;use_markup&quot;&gt;True&lt;/property&gt;
+ &lt;/object&gt;
+ &lt;packing&gt;
+ &lt;property name=&quot;expand&quot;&gt;False&lt;/property&gt;
+ &lt;property name=&quot;position&quot;&gt;0&lt;/property&gt;
+ &lt;/packing&gt;
+ &lt;/child&gt;
+ &lt;child&gt;
+ &lt;object class=&quot;GtkLabel&quot; id=&quot;update_message&quot;&gt;
+ &lt;property name=&quot;visible&quot;&gt;True&lt;/property&gt;
+ &lt;property name=&quot;xalign&quot;&gt;0&lt;/property&gt;
+ &lt;property name=&quot;xpad&quot;&gt;10&lt;/property&gt;
+ &lt;property name=&quot;ypad&quot;&gt;5&lt;/property&gt;
+ &lt;property name=&quot;label&quot; translatable=&quot;yes&quot;&gt;HandBrake xxx is now available (you have yyy).&lt;/property&gt;
+ &lt;/object&gt;
+ &lt;packing&gt;
+ &lt;property name=&quot;expand&quot;&gt;False&lt;/property&gt;
+ &lt;property name=&quot;position&quot;&gt;1&lt;/property&gt;
+ &lt;/packing&gt;
+ &lt;/child&gt;
+ &lt;child&gt;
+ &lt;object class=&quot;GtkFrame&quot; id=&quot;frame2&quot;&gt;
+ &lt;property name=&quot;visible&quot;&gt;True&lt;/property&gt;
+ &lt;property name=&quot;label_xalign&quot;&gt;0&lt;/property&gt;
+ &lt;property name=&quot;shadow_type&quot;&gt;etched-out&lt;/property&gt;
+ &lt;child&gt;
+ &lt;object class=&quot;GtkAlignment&quot; id=&quot;alignment2&quot;&gt;
+ &lt;property name=&quot;visible&quot;&gt;True&lt;/property&gt;
+ &lt;property name=&quot;left_padding&quot;&gt;12&lt;/property&gt;
+ &lt;child&gt;
+ &lt;object class=&quot;GtkScrolledWindow&quot; id=&quot;update_scroll&quot;&gt;
+ &lt;property name=&quot;visible&quot;&gt;True&lt;/property&gt;
+ &lt;property name=&quot;can_focus&quot;&gt;True&lt;/property&gt;
+ &lt;property name=&quot;hscrollbar_policy&quot;&gt;automatic&lt;/property&gt;
+ &lt;property name=&quot;vscrollbar_policy&quot;&gt;automatic&lt;/property&gt;
+ &lt;child&gt;
+ &lt;placeholder/&gt;
+ &lt;/child&gt;
+ &lt;/object&gt;
+ &lt;/child&gt;
+ &lt;/object&gt;
+ &lt;/child&gt;
+ &lt;child type=&quot;label&quot;&gt;
+ &lt;object class=&quot;GtkLabel&quot; id=&quot;label88&quot;&gt;
+ &lt;property name=&quot;visible&quot;&gt;True&lt;/property&gt;
+ &lt;property name=&quot;label&quot; translatable=&quot;yes&quot;&gt;&amp;lt;b&amp;gt;Release Notes&amp;lt;/b&amp;gt;&lt;/property&gt;
+ &lt;property name=&quot;use_markup&quot;&gt;True&lt;/property&gt;
+ &lt;/object&gt;
+ &lt;/child&gt;
+ &lt;/object&gt;
+ &lt;packing&gt;
+ &lt;property name=&quot;position&quot;&gt;2&lt;/property&gt;
+ &lt;/packing&gt;
+ &lt;/child&gt;
+ &lt;/object&gt;
+ &lt;packing&gt;
+ &lt;property name=&quot;position&quot;&gt;1&lt;/property&gt;
+ &lt;/packing&gt;
+ &lt;/child&gt;
+ &lt;/object&gt;
+ &lt;packing&gt;
+ &lt;property name=&quot;position&quot;&gt;1&lt;/property&gt;
+ &lt;/packing&gt;
+ &lt;/child&gt;
+ &lt;child internal-child=&quot;action_area&quot;&gt;
+ &lt;object class=&quot;GtkHButtonBox&quot; id=&quot;dialog-action_area6&quot;&gt;
+ &lt;property name=&quot;visible&quot;&gt;True&lt;/property&gt;
+ &lt;property name=&quot;layout_style&quot;&gt;end&lt;/property&gt;
+ &lt;child&gt;
+ &lt;object class=&quot;GtkButton&quot; id=&quot;update_skip&quot;&gt;
+ &lt;property name=&quot;visible&quot;&gt;True&lt;/property&gt;
+ &lt;property name=&quot;can_focus&quot;&gt;True&lt;/property&gt;
+ &lt;property name=&quot;receives_default&quot;&gt;True&lt;/property&gt;
+ &lt;property name=&quot;label&quot; translatable=&quot;yes&quot;&gt;Skip This Version&lt;/property&gt;
+ &lt;/object&gt;
+ &lt;packing&gt;
+ &lt;property name=&quot;position&quot;&gt;0&lt;/property&gt;
+ &lt;/packing&gt;
+ &lt;/child&gt;
+ &lt;child&gt;
+ &lt;object class=&quot;GtkButton&quot; id=&quot;update_remind&quot;&gt;
+ &lt;property name=&quot;visible&quot;&gt;True&lt;/property&gt;
+ &lt;property name=&quot;can_focus&quot;&gt;True&lt;/property&gt;
+ &lt;property name=&quot;receives_default&quot;&gt;True&lt;/property&gt;
+ &lt;property name=&quot;label&quot; translatable=&quot;yes&quot;&gt;Remind Me Later&lt;/property&gt;
+ &lt;/object&gt;
+ &lt;packing&gt;
+ &lt;property name=&quot;position&quot;&gt;1&lt;/property&gt;
+ &lt;/packing&gt;
+ &lt;/child&gt;
+ &lt;/object&gt;
+ &lt;packing&gt;
+ &lt;property name=&quot;expand&quot;&gt;False&lt;/property&gt;
+ &lt;property name=&quot;pack_type&quot;&gt;end&lt;/property&gt;
+ &lt;property name=&quot;position&quot;&gt;0&lt;/property&gt;
+ &lt;/packing&gt;
+ &lt;/child&gt;
+ &lt;/object&gt;
+ &lt;/child&gt;
+ &lt;action-widgets&gt;
+ &lt;action-widget response=&quot;-5&quot;&gt;update_skip&lt;/action-widget&gt;
+ &lt;action-widget response=&quot;0&quot;&gt;update_remind&lt;/action-widget&gt;
+ &lt;/action-widgets&gt;
+ &lt;/object&gt;
&lt;/interface&gt;
</string>
<key>icons</key>
@@ -4968,6 +5129,8 @@ R2RrUAAABBgBAQACAAAAQAAAABAAAAAQ////AP///wD///8A////AP///wD///8A////AP///wD///8A
<true />
<key>show_presets</key>
<true />
+ <key>update_skip_version</key>
+ <integer>0</integer>
<key>use_source_name</key>
<true />
<key>version</key>
diff --git a/gtk/src/settings.h b/gtk/src/settings.h
index a089e0a71..bc4adc65c 100644
--- a/gtk/src/settings.h
+++ b/gtk/src/settings.h
@@ -48,6 +48,8 @@ typedef struct
GValue *current_job;
GIOChannel *activity_log;
GIOChannel *job_activity_log;
+ gchar *appcast;
+ gint appcast_len;
} signal_user_data_t;
enum