sound-juicer r2381 - in trunk: . src
- From: rburton svn gnome org
- To: svn-commits-list gnome org
- Subject: sound-juicer r2381 - in trunk: . src
- Date: Mon, 22 Dec 2008 22:20:21 +0000 (UTC)
Author: rburton
Date: Mon Dec 22 22:20:21 2008
New Revision: 2381
URL: http://svn.gnome.org/viewvc/sound-juicer?rev=2381&view=rev
Log:
2008-12-22 Ross Burton <ross linux intel com>
* configure.in:
* src/sj-main.c:
* src/sj-extracting.c:
* src/sj-prefs.c:
Drop libgnome and instead use the new GTK+ hotness. Thanks Iain
Holmes and Emilio Pozuelo Monfort (#556793)
Modified:
trunk/ChangeLog
trunk/configure.in
trunk/src/sj-extracting.c
trunk/src/sj-main.c
trunk/src/sj-prefs.c
Modified: trunk/configure.in
==============================================================================
--- trunk/configure.in (original)
+++ trunk/configure.in Mon Dec 22 22:20:21 2008
@@ -50,7 +50,7 @@
LIBS="$oldlibs"
# Find the UI libraries
-PKG_CHECK_MODULES(UI, gtk+-2.0 >= 2.12 libglade-2.0 gconf-2.0 libgnomeui-2.0 >= 2.13.0 gio-2.0 gmodule-export-2.0 dbus-glib-1)
+PKG_CHECK_MODULES(UI, gtk+-2.0 >= 2.14 libglade-2.0 gconf-2.0 gio-2.0 gmodule-export-2.0 dbus-glib-1)
AC_SUBST(UI_CFLAGS)
AC_SUBST(UI_LIBS)
Modified: trunk/src/sj-extracting.c
==============================================================================
--- trunk/src/sj-extracting.c (original)
+++ trunk/src/sj-extracting.c Mon Dec 22 22:20:21 2008
@@ -602,16 +602,13 @@
/* Maybe open the target directory */
if (open_finished) {
- char *base, *command;
+ char *base = NULL;
- base = NULL;
/* Find the deepest common directory. */
g_list_foreach (paths, (GFunc)base_finder, &base);
-
- command = g_strdup_printf ("gnome-open \"%s\"", base);
- g_spawn_command_line_async (command, NULL);
-
- g_free (command);
+
+ gtk_show_uri (NULL, base, GDK_CURRENT_TIME, NULL);
+
g_free (base);
}
}
Modified: trunk/src/sj-main.c
==============================================================================
--- trunk/src/sj-main.c (original)
+++ trunk/src/sj-main.c Mon Dec 22 22:20:21 2008
@@ -33,10 +33,6 @@
#include <glade/glade.h>
#include <gconf/gconf-client.h>
#include <nautilus-burn.h>
-#include <libgnome/gnome-help.h>
-#include <libgnome/gnome-url.h>
-#include <libgnomeui/gnome-ui-init.h>
-#include <libgnomeui/gnome-authentication-manager.h>
#include <profiles/gnome-media-profiles.h>
#include <gst/gst.h>
@@ -1232,7 +1228,7 @@
GError *error = NULL;
if (current_submit_url) {
- if (!gnome_url_show (current_submit_url, &error)) {
+ if (!gtk_show_uri (NULL, current_submit_url, GDK_CURRENT_TIME, &error)) {
GtkWidget *dialog;
dialog = gtk_message_dialog_new (GTK_WINDOW (main_window),
@@ -1449,8 +1445,7 @@
void on_contents_activate(GtkWidget *button, gpointer user_data) {
GError *error = NULL;
- /* If/when we drop libgnome, simply spawn the URI ghelp:sound-juicer. */
- gnome_help_display ("sound-juicer", NULL, &error);
+ gtk_show_uri (NULL, "ghelp:sound-juicer", GDK_CURRENT_TIME, &error);
if (error) {
GtkWidget *dialog;
@@ -1578,7 +1573,6 @@
int main (int argc, char **argv)
{
- GnomeProgram *program;
GError *error = NULL;
GtkTreeSelection *selection;
char *device = NULL, **uris = NULL;
@@ -1598,21 +1592,20 @@
textdomain (GETTEXT_PACKAGE);
ctx = g_option_context_new (N_("- Extract music from your CDs"));
- g_option_context_add_main_entries (ctx, entries, GETTEXT_PACKAGE);
+ g_option_context_add_main_entries (ctx, entries, GETTEXT_PACKAGE);
g_option_context_set_translation_domain(ctx, GETTEXT_PACKAGE);
+ g_option_context_add_group (ctx, gtk_get_option_group (FALSE));
g_option_context_add_group (ctx, gst_init_get_option_group ());
g_option_context_set_ignore_unknown_options (ctx, TRUE);
- program = gnome_program_init ("sound-juicer",
- VERSION, LIBGNOMEUI_MODULE,
- argc, argv,
- GNOME_PROGRAM_STANDARD_PROPERTIES,
- GNOME_PARAM_GOPTION_CONTEXT, ctx,
- NULL);
+ g_option_context_parse (ctx, &argc, &argv, &error);
+ if (error != NULL) {
+ g_error ("Error parsing options: %s", error->message);
+ }
- g_set_application_name (_("Sound Juicer"));
+ gtk_init (&argc, &argv);
- gnome_authentication_manager_init ();
+ g_set_application_name (_("Sound Juicer"));
sj_debug_init ();
@@ -1846,6 +1839,5 @@
g_object_unref (metadata);
g_object_unref (extractor);
g_object_unref (gconf_client);
- g_object_unref (program);
return 0;
}
Modified: trunk/src/sj-prefs.c
==============================================================================
--- trunk/src/sj-prefs.c (original)
+++ trunk/src/sj-prefs.c Mon Dec 22 22:20:21 2008
@@ -26,7 +26,6 @@
#include <gtk/gtk.h>
#include <glade/glade-xml.h>
#include <gconf/gconf-client.h>
-#include <libgnome/gnome-help.h>
#include <profiles/gnome-media-profiles.h>
#include <nautilus-burn-drive.h>
#include <nautilus-burn-drive-selection.h>
@@ -94,7 +93,7 @@
{
GError *error = NULL;
- gnome_help_display ("sound-juicer", "preferences", &error);
+ gtk_show_uri (NULL, "ghelp:sound-juicer?preferences", GDK_CURRENT_TIME, &error);
if (error) {
GtkWidget *dialog;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]