summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLeonardo Boshell <leonardop@gentoo.org>2005-07-26 23:25:35 +0000
committerLeonardo Boshell <leonardop@gentoo.org>2005-07-26 23:25:35 +0000
commit0ad0fa0aa66d766795e073ad0f85abb9577020fe (patch)
tree07b19da5004f5887ed20d0a413aee08704b13752 /gnome-base/nautilus
parentFixing BRANCH_UPDATE. (diff)
downloadgentoo-2-0ad0fa0aa66d766795e073ad0f85abb9577020fe.tar.gz
gentoo-2-0ad0fa0aa66d766795e073ad0f85abb9577020fe.tar.bz2
gentoo-2-0ad0fa0aa66d766795e073ad0f85abb9577020fe.zip
Marking 2.10.1-r1 stable (x86). Cleaning old ebuilds/patches.
(Portage version: 2.0.51.22-r2)
Diffstat (limited to 'gnome-base/nautilus')
-rw-r--r--gnome-base/nautilus/ChangeLog6
-rw-r--r--gnome-base/nautilus/Manifest6
-rw-r--r--gnome-base/nautilus/files/digest-nautilus-2.10.11
-rw-r--r--gnome-base/nautilus/files/nautilus-2-x-printers.patch1129
-rw-r--r--gnome-base/nautilus/files/nautilus-2.8-x-printers.patch1129
-rw-r--r--gnome-base/nautilus/nautilus-2.10.1-r1.ebuild18
-rw-r--r--gnome-base/nautilus/nautilus-2.10.1.ebuild95
7 files changed, 13 insertions, 2371 deletions
diff --git a/gnome-base/nautilus/ChangeLog b/gnome-base/nautilus/ChangeLog
index a6a6e0579dd8..a4abce15c3a9 100644
--- a/gnome-base/nautilus/ChangeLog
+++ b/gnome-base/nautilus/ChangeLog
@@ -1,6 +1,10 @@
# ChangeLog for gnome-base/nautilus
# Copyright 2002-2005 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/gnome-base/nautilus/ChangeLog,v 1.142 2005/07/13 02:14:42 leonardop Exp $
+# $Header: /var/cvsroot/gentoo-x86/gnome-base/nautilus/ChangeLog,v 1.143 2005/07/26 23:25:35 leonardop Exp $
+
+ 26 Jul 2005; Leonardo Boshell <leonardop@gentoo.org>
+ nautilus-2.10.1-r1.ebuild:
+ Stable on x86.
*nautilus-2.10.1-r1 (12 Jul 2005)
diff --git a/gnome-base/nautilus/Manifest b/gnome-base/nautilus/Manifest
index 7cfe3819cacd..6d10daec1695 100644
--- a/gnome-base/nautilus/Manifest
+++ b/gnome-base/nautilus/Manifest
@@ -3,7 +3,8 @@ MD5 03ad2e6c4ab41244af1015a8bbb0b39f metadata.xml 158
MD5 00c95b6b319c4650c8e666dbe2354c7a nautilus-1.0.6-r9.ebuild 3398
MD5 acabd89b48a935acbeba5c482df05fac nautilus-2.10.1-r1.ebuild 2820
MD5 c0ed9135a2a082d9b804280bbbf62c57 nautilus-2.10.0.ebuild 2587
-MD5 d6f6da2d532de48270a1bfe87142a545 nautilus-2.10.1.ebuild 2540
+MD5 a678d8e2f61c28071a9ef7f46c95c289 nautilus-2.10.1-r2.ebuild 2660
+MD5 071b59881259d7153417565b0f30c1f7 .nautilus-2.10.1-r2.ebuild.swp 12288
MD5 3db7f854e279f4032b8d1e86d64157aa files/digest-nautilus-1.0.6-r9 68
MD5 29bf62fc0e7eaa6cd6aa5cf4e2dd291d files/nautilus-2.10.1-font_sizes.patch 1532
MD5 567191aa3b9ef17acb8e3b0ba006afdf files/digest-nautilus-2.10.1-r1 69
@@ -12,10 +13,11 @@ MD5 4c62404b0162ab39572cb522fed222c4 files/nautilus-1.0.6-hyperbola.diff 1632
MD5 47ad4a802bbd17967708599cda1b7aaf files/nautilus-1.0.6-mozilla-1.0_rc1.diff 920
MD5 d7ad0d83dbafefa25a34a50e2ee34806 files/nautilus-1.0.6-mozilla-1.0_rc3.diff 1709
MD5 ddc1abbf275436c7fa5fd5c04a27cc94 files/nautilus-1.0.6-mozilla-embed-1.0_rc3.diff 526
+MD5 1821261bc498a281e646477a30370937 files/nautilus-2.10.1-optional_esd.patch 4056
MD5 b6616981e10e2a9725840198f3b29d15 files/nautilus-2-x-printers.patch 39941
+MD5 567191aa3b9ef17acb8e3b0ba006afdf files/digest-nautilus-2.10.1-r2 69
MD5 e59f42d528ba156ebff5be711d19c97c files/nautilus-2.8-x-printers.patch 39945
MD5 d3f1a79cced5768f96e22c17df92261b files/digest-nautilus-2.10.0 69
MD5 76cc1af40c4dc75ce99179ae9b25a2cd files/nautilus-2.9.90-icon_view_gst.patch 8136
-MD5 567191aa3b9ef17acb8e3b0ba006afdf files/digest-nautilus-2.10.1 69
MD5 7cb2f285f24e86a90c6a65b0b9356d39 files/macros/gnome.m4 16426
MD5 486b971d706aec59655a72282d3feb0b files/macros/nautilus-macros.m4 7993
diff --git a/gnome-base/nautilus/files/digest-nautilus-2.10.1 b/gnome-base/nautilus/files/digest-nautilus-2.10.1
deleted file mode 100644
index ba3eb814a675..000000000000
--- a/gnome-base/nautilus/files/digest-nautilus-2.10.1
+++ /dev/null
@@ -1 +0,0 @@
-MD5 976d725db15e901bc881dfb8c50145c1 nautilus-2.10.1.tar.bz2 5960278
diff --git a/gnome-base/nautilus/files/nautilus-2-x-printers.patch b/gnome-base/nautilus/files/nautilus-2-x-printers.patch
deleted file mode 100644
index a7b9eb79261b..000000000000
--- a/gnome-base/nautilus/files/nautilus-2-x-printers.patch
+++ /dev/null
@@ -1,1129 +0,0 @@
-diff -Nru -x '*~' -x '*.o' -x '*.orig' -x '*.rej' nautilus-2.2.4.orig/components/Makefile.am nautilus-2.2.4/components/Makefile.am
---- nautilus-2.2.4.orig/components/Makefile.am 2002-11-20 07:19:52.000000000 -0500
-+++ nautilus-2.2.4/components/Makefile.am 2003-05-27 01:31:42.000000000 -0400
-@@ -5,6 +5,7 @@
- hardware \
- history \
- notes \
-+ printers \
- text \
- throbber \
- tree \
-diff -Nru -x '*~' -x '*.o' -x '*.orig' -x '*.rej' nautilus-2.2.4.orig/components/printers/Makefile.am nautilus-2.2.4/components/printers/Makefile.am
---- nautilus-2.2.4.orig/components/printers/Makefile.am 1969-12-31 19:00:00.000000000 -0500
-+++ nautilus-2.2.4/components/printers/Makefile.am 2003-05-26 22:17:59.000000000 -0400
-@@ -0,0 +1,37 @@
-+NULL =
-+
-+INCLUDES=\
-+ -DG_LOG_DOMAIN=\"Nautilus-Printers\" \
-+ -I$(top_srcdir) \
-+ -DDATADIR=\""$(datadir)"\" \
-+ -DGNOMELOCALEDIR=\""$(prefix)/${DATADIRNAME}/locale"\" \
-+ $(PRINTER_CFLAGS) \
-+ $(NULL) \
-+ -DGTK_ENABLE_BROKEN
-+
-+bonobodir = $(libdir)/bonobo
-+bonobo_LTLIBRARIES = libnautilus-printers-view.la
-+
-+libnautilus_printers_view_la_SOURCES = nautilus-printers.c
-+
-+libnautilus_printers_view_la_LIBADD = \
-+ $(top_builddir)/libnautilus/libnautilus.la \
-+ $(top_builddir)/libnautilus-private/libnautilus-private.la \
-+ $(PRINTER_LIBS) \
-+ $(NULL)
-+
-+libnautilus_printers_view_la_LDFLAGS = -module -avoid-version
-+
-+server_in_files = Nautilus_View_printers.server.in.in
-+
-+serverdir = $(libdir)/bonobo/servers
-+server_DATA = $(server_in_files:.server.in.in=.server)
-+$(server_in_files:.server.in.in=.server.in): $(server_in_files)
-+ sed -e "s|\@BONOBODIR\@|$(bonobodir)|" $< > $@
-+@INTLTOOL_SERVER_RULE@
-+
-+uidir=$(datadir)/gnome-2.0/ui
-+ui_DATA = nautilus-printers-view-ui.xml
-+
-+EXTRA_DIST= $(server_in_files) $(ui_DATA)
-+CLEANFILES = $(server_DATA) $(server_DATA).in
-diff -Nru -x '*~' -x '*.o' -x '*.orig' -x '*.rej' nautilus-2.2.4.orig/components/printers/nautilus-printers.c nautilus-2.2.4/components/printers/nautilus-printers.c
---- nautilus-2.2.4.orig/components/printers/nautilus-printers.c 1969-12-31 19:00:00.000000000 -0500
-+++ nautilus-2.2.4/components/printers/nautilus-printers.c 2003-05-27 01:31:06.000000000 -0400
-@@ -0,0 +1,923 @@
-+/* -*- Mode: C; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 8 -*- */
-+
-+/*
-+ * Nautilus
-+ *
-+ * Copyright (C) 2002 Ximian Inc.
-+ *
-+ * This library is free software; you can redistribute it and/or
-+ * modify it under the terms of the GNU General Public License as
-+ * published by the Free Software Foundation; either version 2 of the
-+ * License, or (at your option) any later version.
-+ *
-+ * This library is distributed in the hope that it will be useful,
-+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
-+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-+ * General Public License for more details.
-+ *
-+ * You should have received a copy of the GNU General Public License
-+ * along with this library; if not, write to the Free Software
-+ * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
-+ *
-+ * Author: Dave Camp <dave@ximian.com>
-+ *
-+ */
-+
-+#define VIEW_IID "OAFIID:Nautilus_Printers_View"
-+
-+#include <config.h>
-+
-+#include <string.h>
-+#include <bonobo/bonobo-window.h>
-+#include <eel/eel-glib-extensions.h>
-+#include <eel/eel-gtk-extensions.h>
-+#include <gtk/gtklabel.h>
-+#include <gtk/gtklayout.h>
-+#include <gtk/gtkmessagedialog.h>
-+#include <gtk/gtkscrolledwindow.h>
-+#include <libgnome/gnome-i18n.h>
-+#include <libgnome/gnome-macros.h>
-+#include <libgnomecups/gnome-cups-init.h>
-+#include <libgnomecups/gnome-cups-printer.h>
-+#include <libgnomecups/gnome-cups-request.h>
-+#include <libgnomecups/gnome-cups-ui-init.h>
-+#include <libnautilus/nautilus-view.h>
-+#include <libnautilus/nautilus-view-standard-main.h>
-+#include <libnautilus-private/nautilus-bonobo-extensions.h>
-+#include <libnautilus-private/nautilus-icon-container.h>
-+#include <libnautilus-private/nautilus-icon-factory.h>
-+#include <libnautilus-private/nautilus-global-preferences.h>
-+
-+#define NEW_PRINTER_ICON ((NautilusIconData*)1)
-+
-+#define COMMAND_NEW_PRINTER "/commands/New Printer"
-+#define COMMAND_OPEN "/commands/Open"
-+#define COMMAND_DELETE "/commands/Delete"
-+#define COMMAND_PAUSE "/commands/Pause"
-+#define COMMAND_RESUME "/commands/Resume"
-+#define COMMAND_MAKE_DEFAULT "/commands/Make Default"
-+#define COMMAND_PROPERTIES "/commands/Properties"
-+
-+typedef struct {
-+ NautilusIconContainer container;
-+
-+ GList *printers;
-+ guint new_printer_notify;
-+ NautilusView *view;
-+ BonoboUIComponent *ui;
-+} NautilusPrinterContainer;
-+
-+typedef struct {
-+ NautilusIconContainerClass container;
-+} NautilusPrinterContainerClass;
-+
-+static GType nautilus_printer_container_get_type (void);
-+
-+static void remove_printer (NautilusPrinterContainer *container,
-+ GnomeCupsPrinter *printer);
-+
-+GNOME_CLASS_BOILERPLATE (NautilusPrinterContainer, nautilus_printer_container,
-+ NautilusIconContainer,
-+ nautilus_icon_container_get_type ());
-+
-+static void
-+update_menus (NautilusPrinterContainer *container)
-+{
-+ GList *selection;
-+ GList *l;
-+ GnomeCupsPrinter *printer;
-+ int num_selected;
-+ gboolean new_printer_selected;
-+ gboolean all_paused;
-+ gboolean all_running;
-+ gboolean is_default;
-+
-+ selection = nautilus_icon_container_get_selection (NAUTILUS_ICON_CONTAINER (container));
-+
-+ num_selected = g_list_length (selection);
-+
-+ new_printer_selected = FALSE;
-+ all_paused = TRUE;
-+ all_running = TRUE;
-+ is_default = FALSE;
-+
-+ for (l = selection; l != NULL; l = l->next) {
-+ if (l->data == NEW_PRINTER_ICON) {
-+ new_printer_selected = TRUE;
-+ } else {
-+ printer = GNOME_CUPS_PRINTER (l->data);
-+ if (gnome_cups_printer_get_state (printer) == IPP_PRINTER_STOPPED) {
-+ all_running = FALSE;
-+ } else {
-+ all_paused = FALSE;
-+ }
-+
-+ is_default = gnome_cups_printer_get_is_default (printer);
-+ }
-+ }
-+
-+ g_list_free (selection);
-+
-+ nautilus_bonobo_set_sensitive (container->ui,
-+ COMMAND_PAUSE,
-+ !new_printer_selected && !all_paused);
-+ nautilus_bonobo_set_sensitive (container->ui,
-+ COMMAND_RESUME,
-+ !new_printer_selected && !all_running);
-+ nautilus_bonobo_set_sensitive (container->ui,
-+ COMMAND_MAKE_DEFAULT,
-+ (!new_printer_selected && num_selected == 1) && !is_default);
-+ nautilus_bonobo_set_sensitive (container->ui,
-+ COMMAND_PROPERTIES,
-+ !new_printer_selected);
-+ nautilus_bonobo_set_sensitive (container->ui,
-+ COMMAND_DELETE,
-+ !new_printer_selected);
-+}
-+
-+static void
-+get_icon_text (NautilusIconContainer *container,
-+ NautilusIconData *data,
-+ char **editable_text,
-+ char **additional_text)
-+{
-+ GnomeCupsPrinter *printer;
-+
-+ if (data == NEW_PRINTER_ICON) {
-+ *editable_text = g_strdup (_("New Printer"));
-+ *additional_text = NULL;
-+ } else {
-+ printer = GNOME_CUPS_PRINTER (data);
-+
-+ *editable_text = g_strdup (gnome_cups_printer_get_name (printer));
-+ *additional_text = g_strdup_printf (_("%s\n%d Jobs"),
-+ gnome_cups_printer_get_state_name (printer),
-+ gnome_cups_printer_get_job_count (printer));
-+ }
-+}
-+
-+static char *
-+get_icon_images (NautilusIconContainer *container,
-+ NautilusIconData *data,
-+ GList **emblem_icons,
-+ char **embedded_text)
-+{
-+ char *icon_name;
-+
-+ *embedded_text = NULL;
-+
-+ if (data == NEW_PRINTER_ICON) {
-+ icon_name = g_strdup ("gnome-dev-printer-new");
-+ } else {
-+ gnome_cups_printer_get_icon (GNOME_CUPS_PRINTER (data),
-+ &icon_name,
-+ emblem_icons);
-+ }
-+
-+ return icon_name;
-+}
-+
-+static int
-+compare_icons (NautilusIconContainer *container,
-+ NautilusIconData *data_a,
-+ NautilusIconData *data_b)
-+{
-+ if (data_a == data_b) {
-+ return 0;
-+ } else if (data_a == NEW_PRINTER_ICON && data_b != NEW_PRINTER_ICON) {
-+ return -1;
-+ } else if (data_b == NEW_PRINTER_ICON && data_a != NEW_PRINTER_ICON) {
-+ return 1;
-+ } else {
-+ return strcmp (gnome_cups_printer_get_name (GNOME_CUPS_PRINTER (data_a)),
-+ gnome_cups_printer_get_name (GNOME_CUPS_PRINTER (data_b)));
-+ }
-+}
-+
-+static int
-+compare_icons_by_name (NautilusIconContainer *container,
-+ NautilusIconData *data_a,
-+ NautilusIconData *data_b)
-+{
-+ if (data_a == data_b) {
-+ return 0;
-+ } else if (data_a == NEW_PRINTER_ICON && data_b != NEW_PRINTER_ICON) {
-+ return -1;
-+ } else if (data_b == NEW_PRINTER_ICON && data_a != NEW_PRINTER_ICON) {
-+ return 1;
-+ } else {
-+ return strcmp (gnome_cups_printer_get_name (GNOME_CUPS_PRINTER (data_a)),
-+ gnome_cups_printer_get_name (GNOME_CUPS_PRINTER (data_b)));
-+ }
-+}
-+
-+static gboolean
-+can_accept_item (NautilusIconContainer *container,
-+ NautilusIconData *target,
-+ const char *item_uri)
-+{
-+ return FALSE;
-+}
-+
-+static gboolean
-+get_stored_icon_position (NautilusIconContainer *container,
-+ NautilusIconData *data,
-+ NautilusIconPosition *position)
-+{
-+ return FALSE;
-+}
-+
-+static char *
-+get_icon_uri (NautilusIconContainer *container,
-+ NautilusIconData *data)
-+{
-+ return NULL;
-+}
-+
-+static char *
-+get_icon_drop_target_uri (NautilusIconContainer *container,
-+ NautilusIconData *data)
-+{
-+ return g_strdup ("printers:");
-+}
-+
-+static char *
-+get_container_uri (NautilusIconContainer *container)
-+{
-+ return g_strdup ("printers:");
-+}
-+
-+static void
-+printer_gone_cb (GnomeCupsPrinter *printer,
-+ gpointer user_data)
-+{
-+ NautilusPrinterContainer *container;
-+
-+ container = user_data;
-+
-+ remove_printer (container, printer);
-+}
-+
-+static void
-+printer_changed_cb (GnomeCupsPrinter *printer,
-+ gpointer user_data)
-+{
-+ NautilusIconContainer *container;
-+
-+ container = NAUTILUS_ICON_CONTAINER (user_data);
-+
-+ update_menus ((NautilusPrinterContainer*)container);
-+ nautilus_icon_container_request_update (container, (NautilusIconData*)printer);
-+}
-+
-+static void
-+disconnect_printer (NautilusPrinterContainer *container,
-+ GnomeCupsPrinter *printer)
-+{
-+ g_signal_handlers_disconnect_by_func (printer,
-+ G_CALLBACK (printer_changed_cb),
-+ printer);
-+ g_signal_handlers_disconnect_by_func (printer,
-+ G_CALLBACK (printer_gone_cb),
-+ printer);
-+ g_object_unref (printer);
-+}
-+
-+static void
-+remove_printer (NautilusPrinterContainer *container,
-+ GnomeCupsPrinter *printer)
-+{
-+ nautilus_icon_container_remove (NAUTILUS_ICON_CONTAINER (container),
-+ (NautilusIconData*)printer);
-+ container->printers = g_list_remove (container->printers, printer);
-+ disconnect_printer (container, printer);
-+}
-+
-+static void
-+watch_printer (NautilusPrinterContainer *container,
-+ const char *name)
-+{
-+ GnomeCupsPrinter *printer;
-+
-+ printer = gnome_cups_printer_get (name);
-+ if (!printer) {
-+ return;
-+ }
-+
-+ container->printers = g_list_append (container->printers, printer);
-+
-+ nautilus_icon_container_add (NAUTILUS_ICON_CONTAINER (container),
-+ (NautilusIconData*)printer);
-+
-+ g_signal_connect_object (printer, "is_default_changed",
-+ G_CALLBACK (printer_changed_cb),
-+ container, 0);
-+ g_signal_connect_object (printer, "attributes_changed",
-+ G_CALLBACK (printer_changed_cb),
-+ container, 0);
-+ g_signal_connect_object (printer, "gone",
-+ G_CALLBACK (printer_gone_cb),
-+ container, 0);
-+}
-+
-+static BonoboWindow *
-+get_bonobo_window (GtkWidget *widget)
-+{
-+ GtkWidget *window;
-+
-+ /* Note: This works only because we are in the same process
-+ * as the Nautilus shell. Bonobo components in their own
-+ * processes can't do this.
-+ */
-+ window = gtk_widget_get_ancestor (widget, BONOBO_TYPE_WINDOW);
-+ g_assert (window != NULL);
-+
-+ return BONOBO_WINDOW (window);
-+}
-+
-+static GtkMenu *
-+create_popup_menu (NautilusIconContainer *container, const char *popup_path)
-+{
-+ GtkMenu *menu;
-+
-+ menu = GTK_MENU (gtk_menu_new ());
-+ update_menus ((NautilusPrinterContainer*)container);
-+
-+ bonobo_window_add_popup (get_bonobo_window (GTK_WIDGET (container)),
-+ menu, popup_path);
-+
-+ return menu;
-+}
-+
-+static void
-+context_click_selection (NautilusIconContainer *container,
-+ GdkEventButton *event)
-+{
-+ eel_pop_up_context_menu (create_popup_menu (container,
-+ "/popups/selection"),
-+ EEL_DEFAULT_POPUP_MENU_DISPLACEMENT,
-+ EEL_DEFAULT_POPUP_MENU_DISPLACEMENT,
-+ event);
-+}
-+
-+static void
-+selection_changed (NautilusIconContainer *container)
-+{
-+ update_menus ((NautilusPrinterContainer *)container);
-+}
-+
-+static void
-+handle_error (NautilusPrinterContainer *container,
-+ const char *prefix,
-+ GError *error)
-+{
-+ GtkWidget *dialog;
-+ char *msg;
-+
-+ if (prefix) {
-+ msg = g_strdup_printf (_("%s: %s"),
-+ prefix,
-+ error ? error->message : _("Unknown Error"));
-+ } else {
-+ msg = g_strdup (error ? error->message : _("Unknown Error"));
-+ }
-+
-+ dialog = gtk_message_dialog_new (GTK_WINDOW (gtk_widget_get_toplevel (GTK_WIDGET (container))),
-+ GTK_DIALOG_DESTROY_WITH_PARENT | GTK_DIALOG_MODAL,
-+ GTK_MESSAGE_ERROR,
-+ GTK_BUTTONS_OK,
-+ "%s",
-+ msg);
-+ g_free (msg);
-+ gtk_dialog_run (GTK_DIALOG (dialog));
-+ gtk_widget_destroy (dialog);
-+}
-+
-+static void
-+new_printer (NautilusPrinterContainer *container)
-+{
-+ char *argv[] = { "gnome-cups-add", NULL };
-+ GError *error;
-+
-+ error = NULL;
-+
-+ g_spawn_async (NULL, argv, NULL,
-+ G_SPAWN_SEARCH_PATH, NULL, NULL, NULL, &error);
-+
-+ if (error) {
-+ handle_error (container, NULL, error);
-+ g_error_free (error);
-+ }
-+}
-+
-+static void
-+open_printers (NautilusPrinterContainer *container,
-+ GList *printer_names,
-+ const char *command)
-+{
-+ char **argv;
-+ int argc;
-+ GList *l;
-+ int i;
-+ GError *error;
-+
-+ argc = g_list_length (printer_names) + 4;
-+ argv = g_new0 (char *, argc);
-+
-+ i = 0;
-+
-+ argv[i++] = "gnome-cups-manager";
-+ argv[i++] = (char*)command;
-+
-+ for (l = printer_names; l != NULL; l = l->next, i++) {
-+ argv[i] = l->data;
-+ }
-+ argv[i] = NULL;
-+
-+ error = NULL;
-+ g_spawn_async (NULL, argv, NULL,
-+ G_SPAWN_SEARCH_PATH, NULL, NULL, NULL, &error);
-+
-+ if (error) {
-+ handle_error (container, NULL, error);
-+ g_error_free (error);
-+ }
-+
-+ g_free (argv);
-+}
-+
-+static void
-+activate_selection (NautilusPrinterContainer *container,
-+ GList *selection)
-+{
-+ GList *l;
-+ GnomeCupsPrinter *printer;
-+ GList *printer_names;
-+
-+ printer_names = NULL;
-+
-+
-+ for (l = selection; l != NULL; l = l->next) {
-+ if (l->data == NEW_PRINTER_ICON) {
-+ new_printer (container);
-+ } else {
-+ printer = GNOME_CUPS_PRINTER (l->data);
-+ printer_names = g_list_prepend (printer_names,
-+ g_strdup (gnome_cups_printer_get_name (printer)));
-+ }
-+ }
-+
-+ if (printer_names) {
-+ open_printers (container, printer_names, "-v");
-+ }
-+
-+ eel_g_list_free_deep (printer_names);
-+}
-+
-+static void
-+activate (NautilusIconContainer *container,
-+ /* FIXME */NautilusIconData *data)
-+{
-+ /* FIXME: nautilus-icon-container's header is busted, and lists this
-+ * argument as a NautilusIconData rather than a GList * */
-+ GList *items = (GList*)data;
-+
-+ activate_selection ((NautilusPrinterContainer*)container, items);
-+}
-+
-+static void
-+show_selection_properties (NautilusPrinterContainer *container,
-+ GList *selection)
-+{
-+ GList *l;
-+ GnomeCupsPrinter *printer;
-+ GList *printer_names;
-+
-+ printer_names = NULL;
-+
-+ for (l = selection; l != NULL; l = l->next) {
-+ if (l->data == NEW_PRINTER_ICON) {
-+ g_warning ("properties selected on New Printer");
-+ } else {
-+ printer = GNOME_CUPS_PRINTER (l->data);
-+ printer_names = g_list_prepend (printer_names,
-+ g_strdup (gnome_cups_printer_get_name (printer)));
-+ }
-+ }
-+
-+ if (printer_names) {
-+ open_printers (container, printer_names, "-p");
-+ }
-+
-+ eel_g_list_free_deep (printer_names);
-+}
-+
-+static void
-+nautilus_printer_container_unload_printers (NautilusPrinterContainer *container)
-+{
-+ GList *l;
-+ for (l = container->printers; l != NULL; l = l->next) {
-+ nautilus_icon_container_remove (NAUTILUS_ICON_CONTAINER (container),
-+ (NautilusIconData*)l->data);
-+ disconnect_printer (container, GNOME_CUPS_PRINTER (l->data));
-+ }
-+ g_list_free (container->printers);
-+ container->printers = NULL;
-+}
-+
-+static void
-+nautilus_printer_container_load_printers (NautilusPrinterContainer *container)
-+{
-+ GList *printer_names;
-+ GList *l;
-+
-+ nautilus_printer_container_unload_printers (container);
-+
-+ printer_names = gnome_cups_get_printers ();
-+ for (l = printer_names; l != NULL; l = l->next) {
-+ watch_printer (container, l->data);
-+ }
-+ gnome_cups_printer_list_free (printer_names);
-+}
-+
-+static void
-+nautilus_printer_container_dispose (GObject *object)
-+{
-+ NautilusPrinterContainer *container;
-+ GList *l;
-+
-+ container = (NautilusPrinterContainer*)object;
-+
-+ for (l = container->printers; l != NULL; l = l->next) {
-+ disconnect_printer (container, GNOME_CUPS_PRINTER (l->data));
-+ }
-+ g_list_free (container->printers);
-+ container->printers = NULL;
-+
-+ if (container->new_printer_notify) {
-+ gnome_cups_printer_new_printer_notify_remove (container->new_printer_notify);
-+ container->new_printer_notify = 0;
-+ }
-+
-+ GNOME_CALL_PARENT (G_OBJECT_CLASS, dispose, (object));
-+}
-+
-+
-+static void
-+update_click_mode (gpointer user_data)
-+{
-+ NautilusIconContainer *container;
-+ int click_mode;
-+
-+ container = NAUTILUS_ICON_CONTAINER (user_data);
-+
-+ click_mode = eel_preferences_get_enum (NAUTILUS_PREFERENCES_CLICK_POLICY);
-+
-+ nautilus_icon_container_set_single_click_mode (container,
-+ click_mode == NAUTILUS_CLICK_POLICY_SINGLE);
-+}
-+
-+static void
-+prioritize_thumbnailing (NautilusIconContainer *container,
-+ NautilusIconData *data)
-+{
-+}
-+
-+static void
-+nautilus_printer_container_instance_init (NautilusPrinterContainer *container)
-+{
-+}
-+
-+static void
-+nautilus_printer_container_class_init (NautilusPrinterContainerClass *klass)
-+{
-+ NautilusIconContainerClass *container_class;
-+ GObjectClass *object_class;
-+
-+ container_class = NAUTILUS_ICON_CONTAINER_CLASS (klass);
-+ object_class = G_OBJECT_CLASS (klass);
-+
-+ container_class->get_icon_text = get_icon_text;
-+ container_class->get_icon_images = get_icon_images;
-+ container_class->compare_icons = compare_icons;
-+ container_class->compare_icons_by_name = compare_icons_by_name;
-+ container_class->can_accept_item = can_accept_item;
-+ container_class->get_stored_icon_position = get_stored_icon_position;
-+ container_class->get_icon_uri = get_icon_uri;
-+ container_class->get_icon_drop_target_uri = get_icon_drop_target_uri;
-+ container_class->get_container_uri = get_container_uri;
-+
-+ container_class->context_click_selection = context_click_selection;
-+ container_class->selection_changed = selection_changed;
-+
-+ container_class->activate = activate;
-+ container_class->prioritize_thumbnailing = prioritize_thumbnailing;
-+
-+ object_class->dispose = nautilus_printer_container_dispose;
-+
-+}
-+
-+static void
-+printer_added_cb (const char *name, gpointer user_data)
-+{
-+ NautilusPrinterContainer *container;
-+
-+ container = (NautilusPrinterContainer*)user_data;
-+
-+ watch_printer (container, name);
-+}
-+
-+static void
-+printers_load_location (NautilusView *view,
-+ const char *location,
-+ gpointer user_data)
-+{
-+ NautilusPrinterContainer *container;
-+ GtkWidget *dialog;
-+
-+ container = (NautilusPrinterContainer*)user_data;
-+ if (gnome_cups_check_daemon ()) {
-+ if (!container->new_printer_notify) {
-+ container->new_printer_notify =
-+ gnome_cups_printer_new_printer_notify_add (printer_added_cb,
-+ user_data);
-+ }
-+
-+ nautilus_printer_container_load_printers (user_data);
-+
-+ nautilus_view_set_title (view, _("Printers"));
-+
-+ nautilus_view_report_load_complete (view);
-+ } else {
-+ dialog = gtk_message_dialog_new (GTK_WINDOW (gtk_widget_get_toplevel (GTK_WIDGET (container))),
-+ GTK_DIALOG_DESTROY_WITH_PARENT | GTK_DIALOG_MODAL,
-+ GTK_MESSAGE_ERROR,
-+ GTK_BUTTONS_OK,
-+ _("CUPS does not appear to be running. CUPS must be running for the printers: url to work correctly."));
-+ gtk_dialog_run (GTK_DIALOG (dialog));
-+ gtk_widget_destroy (dialog);
-+
-+ nautilus_view_report_load_failed (view);
-+ }
-+}
-+
-+static void
-+open_cb (BonoboUIComponent *component, gpointer user_data, const char *verb)
-+{
-+ NautilusPrinterContainer *container;
-+ GList *selection;
-+
-+ container = user_data;
-+
-+ selection = nautilus_icon_container_get_selection (NAUTILUS_ICON_CONTAINER (container));
-+ activate_selection (container, selection);
-+ g_list_free (selection);
-+}
-+
-+static void
-+properties_cb (BonoboUIComponent *component, gpointer user_data, const char *verb)
-+{
-+ NautilusPrinterContainer *container;
-+ GList *selection;
-+
-+ container = user_data;
-+
-+ selection = nautilus_icon_container_get_selection (NAUTILUS_ICON_CONTAINER (container));
-+ show_selection_properties (container, selection);
-+ g_list_free (selection);
-+}
-+
-+static void
-+pause_cb (BonoboUIComponent *component, gpointer user_data, const char *verb)
-+{
-+ NautilusPrinterContainer *container;
-+ GList *selection;
-+ GList *l;
-+ GnomeCupsPrinter *printer;
-+
-+ container = user_data;
-+
-+ selection = nautilus_icon_container_get_selection (NAUTILUS_ICON_CONTAINER (container));
-+ for (l = selection; l != NULL; l = l->next) {
-+ GError *error = NULL;
-+ g_return_if_fail (l->data != NEW_PRINTER_ICON);
-+ printer = GNOME_CUPS_PRINTER (l->data);
-+ gnome_cups_printer_pause (printer, &error);
-+ if (error) {
-+ char *msg;
-+ msg = g_strdup_printf ("Could not pause '%s'",
-+ gnome_cups_printer_get_name (printer));
-+ handle_error (container, msg, error);
-+ g_free (msg);
-+ g_error_free (error);
-+ }
-+
-+ }
-+ g_list_free (selection);
-+}
-+
-+static void
-+resume_cb (BonoboUIComponent *component, gpointer user_data, const char *verb)
-+{
-+ NautilusPrinterContainer *container;
-+ GList *selection;
-+ GList *l;
-+ GnomeCupsPrinter *printer;
-+
-+ container = user_data;
-+
-+ selection = nautilus_icon_container_get_selection (NAUTILUS_ICON_CONTAINER (container));
-+ for (l = selection; l != NULL; l = l->next) {
-+ GError *error = NULL;
-+ g_return_if_fail (l->data != NEW_PRINTER_ICON);
-+ printer = GNOME_CUPS_PRINTER (l->data);
-+ gnome_cups_printer_resume (printer, &error);
-+ if (error) {
-+ char *msg;
-+ msg = g_strdup_printf ("Could not resume '%s'",
-+ gnome_cups_printer_get_name (printer));
-+ handle_error (container, msg, error);
-+ g_free (msg);
-+ g_error_free (error);
-+ }
-+
-+ }
-+ g_list_free (selection);
-+}
-+
-+static void
-+make_default_cb (BonoboUIComponent *component, gpointer user_data, const char *verb)
-+{
-+ NautilusPrinterContainer *container;
-+ GList *selection;
-+ GnomeCupsPrinter *printer;
-+ GError *error = NULL;
-+
-+ container = user_data;
-+
-+ selection = nautilus_icon_container_get_selection (NAUTILUS_ICON_CONTAINER (container));
-+ g_return_if_fail (g_list_length (selection) == 1);
-+ g_return_if_fail (selection->data != NEW_PRINTER_ICON);
-+
-+ printer = GNOME_CUPS_PRINTER (selection->data);
-+ gnome_cups_printer_set_default (printer, &error);
-+ if (error) {
-+ char *msg;
-+ msg = g_strdup_printf ("Could not make '%s' the default printer",
-+ gnome_cups_printer_get_name (printer));
-+ handle_error (container, msg, error);
-+ g_free (msg);
-+ g_error_free (error);
-+ }
-+
-+ g_list_free (selection);
-+}
-+
-+static void
-+delete_cb (BonoboUIComponent *component, gpointer user_data, const char *verb)
-+{
-+ NautilusPrinterContainer *container;
-+ GList *selection;
-+ GList *l;
-+ GnomeCupsPrinter *printer;
-+
-+ container = user_data;
-+
-+ selection = nautilus_icon_container_get_selection (NAUTILUS_ICON_CONTAINER (container));
-+ for (l = selection; l != NULL; l = l->next) {
-+ GError *error = NULL;
-+ g_return_if_fail (l->data != NEW_PRINTER_ICON);
-+ printer = GNOME_CUPS_PRINTER (l->data);
-+ gnome_cups_printer_delete (printer, &error);
-+ if (error) {
-+ char *msg;
-+ msg = g_strdup_printf ("Could not delete '%s'",
-+ gnome_cups_printer_get_name (printer));
-+ handle_error (container, msg, error);
-+ g_free (msg);
-+ g_error_free (error);
-+ }
-+
-+ }
-+ g_list_free (selection);
-+}
-+
-+static void
-+new_printer_cb (BonoboUIComponent *component, gpointer user_data, const char *verb)
-+{
-+ NautilusPrinterContainer *container;
-+
-+ container = user_data;
-+
-+ new_printer (container);
-+}
-+
-+static BonoboUIVerb verbs[] = {
-+ BONOBO_UI_VERB ("Open", open_cb),
-+ BONOBO_UI_VERB ("Pause", pause_cb),
-+ BONOBO_UI_VERB ("Resume", resume_cb),
-+ BONOBO_UI_VERB ("Make Default", make_default_cb),
-+ BONOBO_UI_VERB ("Delete", delete_cb),
-+ BONOBO_UI_VERB ("Properties", properties_cb),
-+ BONOBO_UI_VERB ("New Printer", new_printer_cb),
-+ BONOBO_UI_VERB_END,
-+};
-+
-+static void
-+control_activate_cb (BonoboObject *control,
-+ gboolean state,
-+ gpointer callback_data)
-+{
-+ NautilusView *view;
-+ NautilusPrinterContainer *container;
-+
-+ view = NAUTILUS_VIEW (callback_data);
-+ container = g_object_get_data (G_OBJECT (view), "container");
-+
-+ if (state) {
-+ container->ui = nautilus_view_set_up_ui (view, DATADIR,
-+ "nautilus-printers-view-ui.xml",
-+ "nautilus-printers");
-+ bonobo_ui_component_add_verb_list_with_data (container->ui,
-+ verbs,
-+ container);
-+ update_menus (container);
-+ }
-+ /* Nothing to do on deactivate case, which necer happens
-+ * because of the way nautilus content views are handled */
-+}
-+
-+static BonoboObject *
-+make_printers_view (void)
-+{
-+ GtkWidget *scrolled;
-+ NautilusView *view;
-+ NautilusPrinterContainer *container;
-+
-+ gnome_cups_ui_init ();
-+
-+ scrolled = gtk_scrolled_window_new (NULL, NULL);
-+ gtk_scrolled_window_set_shadow_type (GTK_SCROLLED_WINDOW (scrolled),
-+ GTK_SHADOW_IN);
-+ gtk_scrolled_window_set_policy (GTK_SCROLLED_WINDOW (scrolled),
-+ GTK_POLICY_AUTOMATIC,
-+ GTK_POLICY_AUTOMATIC);
-+ container = g_object_new (nautilus_printer_container_get_type (), NULL);
-+ gtk_container_add (GTK_CONTAINER (scrolled),
-+ GTK_WIDGET (container));
-+
-+ update_click_mode (container);
-+ eel_preferences_add_callback (NAUTILUS_PREFERENCES_CLICK_POLICY,
-+ update_click_mode, container);
-+
-+
-+ nautilus_icon_container_set_auto_layout (NAUTILUS_ICON_CONTAINER (container), TRUE);
-+ nautilus_icon_container_add (NAUTILUS_ICON_CONTAINER (container),
-+ NEW_PRINTER_ICON);
-+
-+ gtk_widget_show_all (scrolled);
-+
-+ /* Create CORBA object. */
-+ view = nautilus_view_new (scrolled);
-+ g_object_set_data (G_OBJECT (view), "container", container);
-+
-+ g_signal_connect_object (nautilus_view_get_bonobo_control (view),
-+ "activate",
-+ G_CALLBACK (control_activate_cb), view, 0);
-+
-+ /* handle events */
-+ g_signal_connect (view, "load_location",
-+ G_CALLBACK (printers_load_location),
-+ container);
-+
-+ return BONOBO_OBJECT (view);
-+}
-+
-+static CORBA_Object
-+printers_shlib_make_object (PortableServer_POA poa,
-+ const char *iid,
-+ gpointer impl_ptr,
-+ CORBA_Environment *ev)
-+{
-+ BonoboObject *view;
-+
-+ if (strcmp (iid, VIEW_IID) != 0) {
-+ return CORBA_OBJECT_NIL;
-+ }
-+
-+ view = make_printers_view ();
-+
-+ bonobo_activation_plugin_use (poa, impl_ptr);
-+
-+ return CORBA_Object_duplicate (BONOBO_OBJREF (view), ev);
-+}
-+
-+static const BonoboActivationPluginObject printers_plugin_list[] = {
-+ { VIEW_IID, printers_shlib_make_object },
-+ { NULL }
-+};
-+
-+const BonoboActivationPlugin Bonobo_Plugin_info = {
-+ printers_plugin_list,
-+ "Nautilus Printers View"
-+};
-diff -Nru -x '*~' -x '*.o' -x '*.orig' -x '*.rej' nautilus-2.2.4.orig/components/printers/nautilus-printers-view-ui.xml nautilus-2.2.4/components/printers/nautilus-printers-view-ui.xml
---- nautilus-2.2.4.orig/components/printers/nautilus-printers-view-ui.xml 1969-12-31 19:00:00.000000000 -0500
-+++ nautilus-2.2.4/components/printers/nautilus-printers-view-ui.xml 2003-05-26 22:17:59.000000000 -0400
-@@ -0,0 +1,93 @@
-+<Root>
-+<commands>
-+ <cmd name="Delete"
-+ _label="_Delete"
-+ _tip="Delete each selected printer"/>
-+ <cmd name="New Printer"
-+ _label="_New Printer"
-+ _tip="Create a new printer"/>
-+ <cmd name="Open"
-+ _label="_Open"
-+ _tip="Open the selected item"/>
-+ <cmd name="Pause"
-+ _label="Pause"
-+ _tip="Pause the selected item"/>
-+ <cmd name="Resume"
-+ _label="Resume"
-+ _tip="Resume the selected item"/>
-+ <cmd name="Make Default"
-+ _label="Make _Default"
-+ _tip="Make the selected item the default"/>
-+ <cmd name="Properties"
-+ _label="_Properties"
-+ _tip="View or modify the properties of each selected item"/>
-+</commands>
-+<menu>
-+ <submenu name="File">
-+ <placeholder name="New Items Placeholder">
-+ <menuitem name="New Printer"
-+ accel="*Control*n"
-+ pixtype="stock" pixname="gtk-new"
-+ verb="New Printer"/>
-+ </placeholder>
-+ <placeholder name="Open Placeholder">
-+ <menuitem name="Open"
-+ accel="*Control*o"
-+ pixtype="stock" pixname="gtk-open"
-+ verb="Open"/>
-+ </placeholder>
-+ <placeholder name="File Items Placeholder">
-+ <menuitem name="Properties"
-+ accel="*Control*i"
-+ verb="Properties"/>
-+ </placeholder>
-+ </submenu>
-+
-+ <submenu name="Edit">
-+ <menuitem name="Select All"
-+ accel="*Control*a"
-+ verb="Select All"/>
-+
-+ <placeholder name="File Items Placeholder">
-+ <placeholder name="Printer Operations Placeholder" delimit="none">
-+ <menuitem name="Pause" verb="Pause"/>
-+ <menuitem name="Resume" verb="Resume"/>
-+ <menuitem name="Make Default" verb="Make Default"/>
-+ </placeholder>
-+ </placeholder>
-+
-+ <placeholder name="Dangerous File Items Placeholder">
-+ <menuitem name="Delete"
-+ verb="Delete"/>
-+ </placeholder>
-+
-+ </submenu>
-+</menu>
-+<popups>
-+ <popup name="background">
-+ <placeholder name="Before Zoom Items">
-+ <placeholder name="New Items">
-+ <menuitem name="New Printer"
-+ verb="New Printer"/>
-+ </placeholder>
-+ </placeholder>
-+ </popup>
-+
-+ <popup name="selection" tearoff="0">
-+ <placeholder name="Open Placeholder" delimit="none">
-+ <menuitem name="Open" verb="Open"
-+ pixtype="stock" pixname="gtk-open"/>
-+ </placeholder>
-+ <placeholder name="Printer Operations Placeholder" delimit="top">
-+ <menuitem name="Pause" verb="Pause"/>
-+ <menuitem name="Resume" verb="Resume"/>
-+ <menuitem name="Make Default" verb="Make Default"/>
-+ </placeholder>
-+ <placeholder name="Dangerous File Actions" delimit="top">
-+ <menuitem name="Delete" verb="Delete"/>
-+ </placeholder>
-+ <separator/>
-+ <menuitem name="Properties" verb="Properties"/>
-+ </popup>
-+</popups>
-+</Root>
-diff -Nru -x '*~' -x '*.o' -x '*.orig' -x '*.rej' nautilus-2.2.4.orig/components/printers/Nautilus_View_printers.server.in.in nautilus-2.2.4/components/printers/Nautilus_View_printers.server.in.in
---- nautilus-2.2.4.orig/components/printers/Nautilus_View_printers.server.in.in 1969-12-31 19:00:00.000000000 -0500
-+++ nautilus-2.2.4/components/printers/Nautilus_View_printers.server.in.in 2003-05-26 22:17:59.000000000 -0400
-@@ -0,0 +1,20 @@
-+<oaf_info>
-+
-+<oaf_server iid="OAFIID:Nautilus_Printers_View"
-+ type="shlib" location="@BONOBODIR@/libnautilus-printers-view.so">
-+ <oaf_attribute name="repo_ids" type="stringv">
-+ <item value="IDL:Bonobo/Unknown:1.0"/>
-+ <item value="IDL:Bonobo/Control:1.0"/>
-+ <item value="IDL:Nautilus/View:1.0"/>
-+ </oaf_attribute>
-+ <oaf_attribute name="description" type="string" _value="Printers view for nautilus"/>
-+ <oaf_attribute name="name" type="string" _value="Printers View"/>
-+ <oaf_attribute name="bonobo:supported_uri_schemes" type="stringv">
-+ <item value="printers"/>
-+ </oaf_attribute>
-+ <oaf_attribute name="nautilus:view_as_name" type="string" _value="Printers"/>
-+ <oaf_attribute name="nautilus:view_as_label" type="string" _value="View as Printers"/>
-+ <oaf_attribute name="nautilus:viewer_label" type="string" _value="Printer Viewer"/>
-+</oaf_server>
-+
-+</oaf_info>
-diff -Nru -x '*~' -x '*.o' -x '*.orig' -x '*.rej' nautilus-2.2.4.orig/configure.in nautilus-2.2.4/configure.in
---- nautilus-2.2.4.orig/configure.in 2003-05-07 13:51:36.000000000 -0400
-+++ nautilus-2.2.4/configure.in 2003-05-27 01:31:42.000000000 -0400
-@@ -296,6 +296,17 @@
- COMPONENT_LIBS="`$PKG_CONFIG --libs $COMPONENT_MODULES`"
- AC_SUBST(COMPONENT_LIBS)
-
-+dnl printer component
-+dnl FIXME: Make optional
-+
-+PRINTER_MODULES="eel-2.0 libbonoboui-2.0 gnome-vfs-module-2.0 gnome-desktop-2.0 libgnomecups-1.0 libgnomecupsui-1.0"
-+PKG_CHECK_MODULES(PRINTER, $PRINTER_MODULES)
-+PRINTER_CFLAGS="`$PKG_CONFIG --cflags $PRINTER_MODULES`"
-+AC_SUBST(PRINTER_CFLAGS)
-+PRINTER_LIBS="`$PKG_CONFIG --libs $PRINTER_MODULES`"
-+AC_SUBST(PRINTER_LIBS)
-+
-+
- dnl emblems component
- EMBLEM_COMPONENT_MODULES="$COMPONENT_MODULES librsvg-2.0"
- EMBLEM_COMPONENT_CFLAGS="`$PKG_CONFIG --cflags $EMBLEM_COMPONENT_MODULES`"
-@@ -352,6 +363,7 @@
- components/hardware/icons/Makefile
- components/history/Makefile
- components/notes/Makefile
-+components/printers/Makefile
- components/text/Makefile
- components/text/services/Makefile
- components/throbber/Makefile
diff --git a/gnome-base/nautilus/files/nautilus-2.8-x-printers.patch b/gnome-base/nautilus/files/nautilus-2.8-x-printers.patch
deleted file mode 100644
index 3280a523f9ee..000000000000
--- a/gnome-base/nautilus/files/nautilus-2.8-x-printers.patch
+++ /dev/null
@@ -1,1129 +0,0 @@
-diff -Nru -x '*~' -x '*.o' -x '*.orig' -x '*.rej' nautilus-2.2.4.orig/components/Makefile.am nautilus-2.2.4/components/Makefile.am
---- nautilus-2.2.4.orig/components/Makefile.am 2002-11-20 07:19:52.000000000 -0500
-+++ nautilus-2.2.4/components/Makefile.am 2003-05-27 01:31:42.000000000 -0400
-@@ -5,6 +5,7 @@
- hardware \
- history \
- notes \
-+ printers \
- text \
- throbber \
- tree \
-diff -Nru -x '*~' -x '*.o' -x '*.orig' -x '*.rej' nautilus-2.2.4.orig/components/printers/Makefile.am nautilus-2.2.4/components/printers/Makefile.am
---- nautilus-2.2.4.orig/components/printers/Makefile.am 1969-12-31 19:00:00.000000000 -0500
-+++ nautilus-2.2.4/components/printers/Makefile.am 2003-05-26 22:17:59.000000000 -0400
-@@ -0,0 +1,37 @@
-+NULL =
-+
-+INCLUDES=\
-+ -DG_LOG_DOMAIN=\"Nautilus-Printers\" \
-+ -I$(top_srcdir) \
-+ -DDATADIR=\""$(datadir)"\" \
-+ -DGNOMELOCALEDIR=\""$(prefix)/${DATADIRNAME}/locale"\" \
-+ $(PRINTER_CFLAGS) \
-+ $(NULL) \
-+ -DGTK_ENABLE_BROKEN
-+
-+bonobodir = $(libdir)/bonobo
-+bonobo_LTLIBRARIES = libnautilus-printers-view.la
-+
-+libnautilus_printers_view_la_SOURCES = nautilus-printers.c
-+
-+libnautilus_printers_view_la_LIBADD = \
-+ $(top_builddir)/libnautilus/libnautilus.la \
-+ $(top_builddir)/libnautilus-private/libnautilus-private.la \
-+ $(PRINTER_LIBS) \
-+ $(NULL)
-+
-+libnautilus_printers_view_la_LDFLAGS = -module -avoid-version
-+
-+server_in_files = Nautilus_View_printers.server.in.in
-+
-+serverdir = $(libdir)/bonobo/servers
-+server_DATA = $(server_in_files:.server.in.in=.server)
-+$(server_in_files:.server.in.in=.server.in): $(server_in_files)
-+ sed -e "s|\@BONOBODIR\@|$(bonobodir)|" $< > $@
-+@INTLTOOL_SERVER_RULE@
-+
-+uidir=$(datadir)/gnome-2.0/ui
-+ui_DATA = nautilus-printers-view-ui.xml
-+
-+EXTRA_DIST= $(server_in_files) $(ui_DATA)
-+CLEANFILES = $(server_DATA) $(server_DATA).in
-diff -Nru -x '*~' -x '*.o' -x '*.orig' -x '*.rej' nautilus-2.2.4.orig/components/printers/nautilus-printers.c nautilus-2.2.4/components/printers/nautilus-printers.c
---- nautilus-2.2.4.orig/components/printers/nautilus-printers.c 1969-12-31 19:00:00.000000000 -0500
-+++ nautilus-2.2.4/components/printers/nautilus-printers.c 2003-05-27 01:31:06.000000000 -0400
-@@ -0,0 +1,923 @@
-+/* -*- Mode: C; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 8 -*- */
-+
-+/*
-+ * Nautilus
-+ *
-+ * Copyright (C) 2002 Ximian Inc.
-+ *
-+ * This library is free software; you can redistribute it and/or
-+ * modify it under the terms of the GNU General Public License as
-+ * published by the Free Software Foundation; either version 2 of the
-+ * License, or (at your option) any later version.
-+ *
-+ * This library is distributed in the hope that it will be useful,
-+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
-+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-+ * General Public License for more details.
-+ *
-+ * You should have received a copy of the GNU General Public License
-+ * along with this library; if not, write to the Free Software
-+ * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
-+ *
-+ * Author: Dave Camp <dave@ximian.com>
-+ *
-+ */
-+
-+#define VIEW_IID "OAFIID:Nautilus_Printers_View"
-+
-+#include <config.h>
-+
-+#include <string.h>
-+#include <bonobo/bonobo-window.h>
-+#include <eel/eel-glib-extensions.h>
-+#include <eel/eel-gtk-extensions.h>
-+#include <gtk/gtklabel.h>
-+#include <gtk/gtklayout.h>
-+#include <gtk/gtkmessagedialog.h>
-+#include <gtk/gtkscrolledwindow.h>
-+#include <libgnome/gnome-i18n.h>
-+#include <libgnome/gnome-macros.h>
-+#include <libgnomecups/gnome-cups-init.h>
-+#include <libgnomecups/gnome-cups-printer.h>
-+#include <libgnomecups/gnome-cups-request.h>
-+#include <libgnomecups/gnome-cups-ui-init.h>
-+#include <libnautilus/nautilus-view.h>
-+#include <libnautilus/nautilus-view-standard-main.h>
-+#include <libnautilus-private/nautilus-bonobo-extensions.h>
-+#include <libnautilus-private/nautilus-icon-container.h>
-+#include <libnautilus-private/nautilus-icon-factory.h>
-+#include <libnautilus-private/nautilus-global-preferences.h>
-+
-+#define NEW_PRINTER_ICON ((NautilusIconData*)1)
-+
-+#define COMMAND_NEW_PRINTER "/commands/New Printer"
-+#define COMMAND_OPEN "/commands/Open"
-+#define COMMAND_DELETE "/commands/Delete"
-+#define COMMAND_PAUSE "/commands/Pause"
-+#define COMMAND_RESUME "/commands/Resume"
-+#define COMMAND_MAKE_DEFAULT "/commands/Make Default"
-+#define COMMAND_PROPERTIES "/commands/Properties"
-+
-+typedef struct {
-+ NautilusIconContainer container;
-+
-+ GList *printers;
-+ guint new_printer_notify;
-+ NautilusView *view;
-+ BonoboUIComponent *ui;
-+} NautilusPrinterContainer;
-+
-+typedef struct {
-+ NautilusIconContainerClass container;
-+} NautilusPrinterContainerClass;
-+
-+static GType nautilus_printer_container_get_type (void);
-+
-+static void remove_printer (NautilusPrinterContainer *container,
-+ GnomeCupsPrinter *printer);
-+
-+GNOME_CLASS_BOILERPLATE (NautilusPrinterContainer, nautilus_printer_container,
-+ NautilusIconContainer,
-+ nautilus_icon_container_get_type ());
-+
-+static void
-+update_menus (NautilusPrinterContainer *container)
-+{
-+ GList *selection;
-+ GList *l;
-+ GnomeCupsPrinter *printer;
-+ int num_selected;
-+ gboolean new_printer_selected;
-+ gboolean all_paused;
-+ gboolean all_running;
-+ gboolean is_default;
-+
-+ selection = nautilus_icon_container_get_selection (NAUTILUS_ICON_CONTAINER (container));
-+
-+ num_selected = g_list_length (selection);
-+
-+ new_printer_selected = FALSE;
-+ all_paused = TRUE;
-+ all_running = TRUE;
-+ is_default = FALSE;
-+
-+ for (l = selection; l != NULL; l = l->next) {
-+ if (l->data == NEW_PRINTER_ICON) {
-+ new_printer_selected = TRUE;
-+ } else {
-+ printer = GNOME_CUPS_PRINTER (l->data);
-+ if (gnome_cups_printer_get_state (printer) == IPP_PRINTER_STOPPED) {
-+ all_running = FALSE;
-+ } else {
-+ all_paused = FALSE;
-+ }
-+
-+ is_default = gnome_cups_printer_get_is_default (printer);
-+ }
-+ }
-+
-+ g_list_free (selection);
-+
-+ nautilus_bonobo_set_sensitive (container->ui,
-+ COMMAND_PAUSE,
-+ !new_printer_selected && !all_paused);
-+ nautilus_bonobo_set_sensitive (container->ui,
-+ COMMAND_RESUME,
-+ !new_printer_selected && !all_running);
-+ nautilus_bonobo_set_sensitive (container->ui,
-+ COMMAND_MAKE_DEFAULT,
-+ (!new_printer_selected && num_selected == 1) && !is_default);
-+ nautilus_bonobo_set_sensitive (container->ui,
-+ COMMAND_PROPERTIES,
-+ !new_printer_selected);
-+ nautilus_bonobo_set_sensitive (container->ui,
-+ COMMAND_DELETE,
-+ !new_printer_selected);
-+}
-+
-+static void
-+get_icon_text (NautilusIconContainer *container,
-+ NautilusIconData *data,
-+ char **editable_text,
-+ char **additional_text)
-+{
-+ GnomeCupsPrinter *printer;
-+
-+ if (data == NEW_PRINTER_ICON) {
-+ *editable_text = g_strdup (_("New Printer"));
-+ *additional_text = NULL;
-+ } else {
-+ printer = GNOME_CUPS_PRINTER (data);
-+
-+ *editable_text = g_strdup (gnome_cups_printer_get_name (printer));
-+ *additional_text = g_strdup_printf (_("%s\n%d Jobs"),
-+ gnome_cups_printer_get_state_name (printer),
-+ gnome_cups_printer_get_job_count (printer));
-+ }
-+}
-+
-+static char *
-+get_icon_images (NautilusIconContainer *container,
-+ NautilusIconData *data,
-+ GList **emblem_icons,
-+ char **embedded_text)
-+{
-+ char *icon_name;
-+
-+ *embedded_text = NULL;
-+
-+ if (data == NEW_PRINTER_ICON) {
-+ icon_name = g_strdup ("gnome-dev-printer-new");
-+ } else {
-+ gnome_cups_printer_get_icon (GNOME_CUPS_PRINTER (data),
-+ &icon_name,
-+ emblem_icons);
-+ }
-+
-+ return icon_name;
-+}
-+
-+static int
-+compare_icons (NautilusIconContainer *container,
-+ NautilusIconData *data_a,
-+ NautilusIconData *data_b)
-+{
-+ if (data_a == data_b) {
-+ return 0;
-+ } else if (data_a == NEW_PRINTER_ICON && data_b != NEW_PRINTER_ICON) {
-+ return -1;
-+ } else if (data_b == NEW_PRINTER_ICON && data_a != NEW_PRINTER_ICON) {
-+ return 1;
-+ } else {
-+ return strcmp (gnome_cups_printer_get_name (GNOME_CUPS_PRINTER (data_a)),
-+ gnome_cups_printer_get_name (GNOME_CUPS_PRINTER (data_b)));
-+ }
-+}
-+
-+static int
-+compare_icons_by_name (NautilusIconContainer *container,
-+ NautilusIconData *data_a,
-+ NautilusIconData *data_b)
-+{
-+ if (data_a == data_b) {
-+ return 0;
-+ } else if (data_a == NEW_PRINTER_ICON && data_b != NEW_PRINTER_ICON) {
-+ return -1;
-+ } else if (data_b == NEW_PRINTER_ICON && data_a != NEW_PRINTER_ICON) {
-+ return 1;
-+ } else {
-+ return strcmp (gnome_cups_printer_get_name (GNOME_CUPS_PRINTER (data_a)),
-+ gnome_cups_printer_get_name (GNOME_CUPS_PRINTER (data_b)));
-+ }
-+}
-+
-+static gboolean
-+can_accept_item (NautilusIconContainer *container,
-+ NautilusIconData *target,
-+ const char *item_uri)
-+{
-+ return FALSE;
-+}
-+
-+static gboolean
-+get_stored_icon_position (NautilusIconContainer *container,
-+ NautilusIconData *data,
-+ NautilusIconPosition *position)
-+{
-+ return FALSE;
-+}
-+
-+static char *
-+get_icon_uri (NautilusIconContainer *container,
-+ NautilusIconData *data)
-+{
-+ return NULL;
-+}
-+
-+static char *
-+get_icon_drop_target_uri (NautilusIconContainer *container,
-+ NautilusIconData *data)
-+{
-+ return g_strdup ("printers:");
-+}
-+
-+static char *
-+get_container_uri (NautilusIconContainer *container)
-+{
-+ return g_strdup ("printers:");
-+}
-+
-+static void
-+printer_gone_cb (GnomeCupsPrinter *printer,
-+ gpointer user_data)
-+{
-+ NautilusPrinterContainer *container;
-+
-+ container = user_data;
-+
-+ remove_printer (container, printer);
-+}
-+
-+static void
-+printer_changed_cb (GnomeCupsPrinter *printer,
-+ gpointer user_data)
-+{
-+ NautilusIconContainer *container;
-+
-+ container = NAUTILUS_ICON_CONTAINER (user_data);
-+
-+ update_menus ((NautilusPrinterContainer*)container);
-+ nautilus_icon_container_request_update (container, (NautilusIconData*)printer);
-+}
-+
-+static void
-+disconnect_printer (NautilusPrinterContainer *container,
-+ GnomeCupsPrinter *printer)
-+{
-+ g_signal_handlers_disconnect_by_func (printer,
-+ G_CALLBACK (printer_changed_cb),
-+ printer);
-+ g_signal_handlers_disconnect_by_func (printer,
-+ G_CALLBACK (printer_gone_cb),
-+ printer);
-+ g_object_unref (printer);
-+}
-+
-+static void
-+remove_printer (NautilusPrinterContainer *container,
-+ GnomeCupsPrinter *printer)
-+{
-+ nautilus_icon_container_remove (NAUTILUS_ICON_CONTAINER (container),
-+ (NautilusIconData*)printer);
-+ container->printers = g_list_remove (container->printers, printer);
-+ disconnect_printer (container, printer);
-+}
-+
-+static void
-+watch_printer (NautilusPrinterContainer *container,
-+ const char *name)
-+{
-+ GnomeCupsPrinter *printer;
-+
-+ printer = gnome_cups_printer_get (name);
-+ if (!printer) {
-+ return;
-+ }
-+
-+ container->printers = g_list_append (container->printers, printer);
-+
-+ nautilus_icon_container_add (NAUTILUS_ICON_CONTAINER (container),
-+ (NautilusIconData*)printer);
-+
-+ g_signal_connect_object (printer, "is_default_changed",
-+ G_CALLBACK (printer_changed_cb),
-+ container, 0);
-+ g_signal_connect_object (printer, "attributes_changed",
-+ G_CALLBACK (printer_changed_cb),
-+ container, 0);
-+ g_signal_connect_object (printer, "gone",
-+ G_CALLBACK (printer_gone_cb),
-+ container, 0);
-+}
-+
-+static BonoboWindow *
-+get_bonobo_window (GtkWidget *widget)
-+{
-+ GtkWidget *window;
-+
-+ /* Note: This works only because we are in the same process
-+ * as the Nautilus shell. Bonobo components in their own
-+ * processes can't do this.
-+ */
-+ window = gtk_widget_get_ancestor (widget, BONOBO_TYPE_WINDOW);
-+ g_assert (window != NULL);
-+
-+ return BONOBO_WINDOW (window);
-+}
-+
-+static GtkMenu *
-+create_popup_menu (NautilusIconContainer *container, const char *popup_path)
-+{
-+ GtkMenu *menu;
-+
-+ menu = GTK_MENU (gtk_menu_new ());
-+ update_menus ((NautilusPrinterContainer*)container);
-+
-+ bonobo_window_add_popup (get_bonobo_window (GTK_WIDGET (container)),
-+ menu, popup_path);
-+
-+ return menu;
-+}
-+
-+static void
-+context_click_selection (NautilusIconContainer *container,
-+ GdkEventButton *event)
-+{
-+ eel_pop_up_context_menu (create_popup_menu (container,
-+ "/popups/selection"),
-+ EEL_DEFAULT_POPUP_MENU_DISPLACEMENT,
-+ EEL_DEFAULT_POPUP_MENU_DISPLACEMENT,
-+ event);
-+}
-+
-+static void
-+selection_changed (NautilusIconContainer *container)
-+{
-+ update_menus ((NautilusPrinterContainer *)container);
-+}
-+
-+static void
-+handle_error (NautilusPrinterContainer *container,
-+ const char *prefix,
-+ GError *error)
-+{
-+ GtkWidget *dialog;
-+ char *msg;
-+
-+ if (prefix) {
-+ msg = g_strdup_printf (_("%s: %s"),
-+ prefix,
-+ error ? error->message : _("Unknown Error"));
-+ } else {
-+ msg = g_strdup (error ? error->message : _("Unknown Error"));
-+ }
-+
-+ dialog = gtk_message_dialog_new (GTK_WINDOW (gtk_widget_get_toplevel (GTK_WIDGET (container))),
-+ GTK_DIALOG_DESTROY_WITH_PARENT | GTK_DIALOG_MODAL,
-+ GTK_MESSAGE_ERROR,
-+ GTK_BUTTONS_OK,
-+ "%s",
-+ msg);
-+ g_free (msg);
-+ gtk_dialog_run (GTK_DIALOG (dialog));
-+ gtk_widget_destroy (dialog);
-+}
-+
-+static void
-+new_printer (NautilusPrinterContainer *container)
-+{
-+ char *argv[] = { "gnome-cups-add", NULL };
-+ GError *error;
-+
-+ error = NULL;
-+
-+ g_spawn_async (NULL, argv, NULL,
-+ G_SPAWN_SEARCH_PATH, NULL, NULL, NULL, &error);
-+
-+ if (error) {
-+ handle_error (container, NULL, error);
-+ g_error_free (error);
-+ }
-+}
-+
-+static void
-+open_printers (NautilusPrinterContainer *container,
-+ GList *printer_names,
-+ const char *command)
-+{
-+ char **argv;
-+ int argc;
-+ GList *l;
-+ int i;
-+ GError *error;
-+
-+ argc = g_list_length (printer_names) + 4;
-+ argv = g_new0 (char *, argc);
-+
-+ i = 0;
-+
-+ argv[i++] = "gnome-cups-manager";
-+ argv[i++] = (char*)command;
-+
-+ for (l = printer_names; l != NULL; l = l->next, i++) {
-+ argv[i] = l->data;
-+ }
-+ argv[i] = NULL;
-+
-+ error = NULL;
-+ g_spawn_async (NULL, argv, NULL,
-+ G_SPAWN_SEARCH_PATH, NULL, NULL, NULL, &error);
-+
-+ if (error) {
-+ handle_error (container, NULL, error);
-+ g_error_free (error);
-+ }
-+
-+ g_free (argv);
-+}
-+
-+static void
-+activate_selection (NautilusPrinterContainer *container,
-+ GList *selection)
-+{
-+ GList *l;
-+ GnomeCupsPrinter *printer;
-+ GList *printer_names;
-+
-+ printer_names = NULL;
-+
-+
-+ for (l = selection; l != NULL; l = l->next) {
-+ if (l->data == NEW_PRINTER_ICON) {
-+ new_printer (container);
-+ } else {
-+ printer = GNOME_CUPS_PRINTER (l->data);
-+ printer_names = g_list_prepend (printer_names,
-+ g_strdup (gnome_cups_printer_get_name (printer)));
-+ }
-+ }
-+
-+ if (printer_names) {
-+ open_printers (container, printer_names, "-v");
-+ }
-+
-+ eel_g_list_free_deep (printer_names);
-+}
-+
-+static void
-+activate (NautilusIconContainer *container,
-+ /* FIXME */NautilusIconData *data)
-+{
-+ /* FIXME: nautilus-icon-container's header is busted, and lists this
-+ * argument as a NautilusIconData rather than a GList * */
-+ GList *items = (GList*)data;
-+
-+ activate_selection ((NautilusPrinterContainer*)container, items);
-+}
-+
-+static void
-+show_selection_properties (NautilusPrinterContainer *container,
-+ GList *selection)
-+{
-+ GList *l;
-+ GnomeCupsPrinter *printer;
-+ GList *printer_names;
-+
-+ printer_names = NULL;
-+
-+ for (l = selection; l != NULL; l = l->next) {
-+ if (l->data == NEW_PRINTER_ICON) {
-+ g_warning ("properties selected on New Printer");
-+ } else {
-+ printer = GNOME_CUPS_PRINTER (l->data);
-+ printer_names = g_list_prepend (printer_names,
-+ g_strdup (gnome_cups_printer_get_name (printer)));
-+ }
-+ }
-+
-+ if (printer_names) {
-+ open_printers (container, printer_names, "-p");
-+ }
-+
-+ eel_g_list_free_deep (printer_names);
-+}
-+
-+static void
-+nautilus_printer_container_unload_printers (NautilusPrinterContainer *container)
-+{
-+ GList *l;
-+ for (l = container->printers; l != NULL; l = l->next) {
-+ nautilus_icon_container_remove (NAUTILUS_ICON_CONTAINER (container),
-+ (NautilusIconData*)l->data);
-+ disconnect_printer (container, GNOME_CUPS_PRINTER (l->data));
-+ }
-+ g_list_free (container->printers);
-+ container->printers = NULL;
-+}
-+
-+static void
-+nautilus_printer_container_load_printers (NautilusPrinterContainer *container)
-+{
-+ GList *printer_names;
-+ GList *l;
-+
-+ nautilus_printer_container_unload_printers (container);
-+
-+ printer_names = gnome_cups_get_printers ();
-+ for (l = printer_names; l != NULL; l = l->next) {
-+ watch_printer (container, l->data);
-+ }
-+ gnome_cups_printer_list_free (printer_names);
-+}
-+
-+static void
-+nautilus_printer_container_dispose (GObject *object)
-+{
-+ NautilusPrinterContainer *container;
-+ GList *l;
-+
-+ container = (NautilusPrinterContainer*)object;
-+
-+ for (l = container->printers; l != NULL; l = l->next) {
-+ disconnect_printer (container, GNOME_CUPS_PRINTER (l->data));
-+ }
-+ g_list_free (container->printers);
-+ container->printers = NULL;
-+
-+ if (container->new_printer_notify) {
-+ gnome_cups_printer_new_printer_notify_remove (container->new_printer_notify);
-+ container->new_printer_notify = 0;
-+ }
-+
-+ GNOME_CALL_PARENT (G_OBJECT_CLASS, dispose, (object));
-+}
-+
-+
-+static void
-+update_click_mode (gpointer user_data)
-+{
-+ NautilusIconContainer *container;
-+ int click_mode;
-+
-+ container = NAUTILUS_ICON_CONTAINER (user_data);
-+
-+ click_mode = eel_preferences_get_enum (NAUTILUS_PREFERENCES_CLICK_POLICY);
-+
-+ nautilus_icon_container_set_single_click_mode (container,
-+ click_mode == NAUTILUS_CLICK_POLICY_SINGLE);
-+}
-+
-+static void
-+prioritize_thumbnailing (NautilusIconContainer *container,
-+ NautilusIconData *data)
-+{
-+}
-+
-+static void
-+nautilus_printer_container_instance_init (NautilusPrinterContainer *container)
-+{
-+}
-+
-+static void
-+nautilus_printer_container_class_init (NautilusPrinterContainerClass *klass)
-+{
-+ NautilusIconContainerClass *container_class;
-+ GObjectClass *object_class;
-+
-+ container_class = NAUTILUS_ICON_CONTAINER_CLASS (klass);
-+ object_class = G_OBJECT_CLASS (klass);
-+
-+ container_class->get_icon_text = get_icon_text;
-+ container_class->get_icon_images = get_icon_images;
-+ container_class->compare_icons = compare_icons;
-+ container_class->compare_icons_by_name = compare_icons_by_name;
-+ container_class->can_accept_item = can_accept_item;
-+ container_class->get_stored_icon_position = get_stored_icon_position;
-+ container_class->get_icon_uri = get_icon_uri;
-+ container_class->get_icon_drop_target_uri = get_icon_drop_target_uri;
-+ container_class->get_container_uri = get_container_uri;
-+
-+ container_class->context_click_selection = context_click_selection;
-+ container_class->selection_changed = selection_changed;
-+
-+ container_class->activate = activate;
-+ container_class->prioritize_thumbnailing = prioritize_thumbnailing;
-+
-+ object_class->dispose = nautilus_printer_container_dispose;
-+
-+}
-+
-+static void
-+printer_added_cb (const char *name, gpointer user_data)
-+{
-+ NautilusPrinterContainer *container;
-+
-+ container = (NautilusPrinterContainer*)user_data;
-+
-+ watch_printer (container, name);
-+}
-+
-+static void
-+printers_load_location (NautilusView *view,
-+ const char *location,
-+ gpointer user_data)
-+{
-+ NautilusPrinterContainer *container;
-+ GtkWidget *dialog;
-+
-+ container = (NautilusPrinterContainer*)user_data;
-+ if (gnome_cups_check_daemon ()) {
-+ if (!container->new_printer_notify) {
-+ container->new_printer_notify =
-+ gnome_cups_printer_new_printer_notify_add (printer_added_cb,
-+ user_data);
-+ }
-+
-+ nautilus_printer_container_load_printers (user_data);
-+
-+ nautilus_view_set_title (view, _("Printers"));
-+
-+ nautilus_view_report_load_complete (view);
-+ } else {
-+ dialog = gtk_message_dialog_new (GTK_WINDOW (gtk_widget_get_toplevel (GTK_WIDGET (container))),
-+ GTK_DIALOG_DESTROY_WITH_PARENT | GTK_DIALOG_MODAL,
-+ GTK_MESSAGE_ERROR,
-+ GTK_BUTTONS_OK,
-+ _("CUPS does not appear to be running. CUPS must be running for the printers: url to work correctly."));
-+ gtk_dialog_run (GTK_DIALOG (dialog));
-+ gtk_widget_destroy (dialog);
-+
-+ nautilus_view_report_load_failed (view);
-+ }
-+}
-+
-+static void
-+open_cb (BonoboUIComponent *component, gpointer user_data, const char *verb)
-+{
-+ NautilusPrinterContainer *container;
-+ GList *selection;
-+
-+ container = user_data;
-+
-+ selection = nautilus_icon_container_get_selection (NAUTILUS_ICON_CONTAINER (container));
-+ activate_selection (container, selection);
-+ g_list_free (selection);
-+}
-+
-+static void
-+properties_cb (BonoboUIComponent *component, gpointer user_data, const char *verb)
-+{
-+ NautilusPrinterContainer *container;
-+ GList *selection;
-+
-+ container = user_data;
-+
-+ selection = nautilus_icon_container_get_selection (NAUTILUS_ICON_CONTAINER (container));
-+ show_selection_properties (container, selection);
-+ g_list_free (selection);
-+}
-+
-+static void
-+pause_cb (BonoboUIComponent *component, gpointer user_data, const char *verb)
-+{
-+ NautilusPrinterContainer *container;
-+ GList *selection;
-+ GList *l;
-+ GnomeCupsPrinter *printer;
-+
-+ container = user_data;
-+
-+ selection = nautilus_icon_container_get_selection (NAUTILUS_ICON_CONTAINER (container));
-+ for (l = selection; l != NULL; l = l->next) {
-+ GError *error = NULL;
-+ g_return_if_fail (l->data != NEW_PRINTER_ICON);
-+ printer = GNOME_CUPS_PRINTER (l->data);
-+ gnome_cups_printer_pause (printer, &error);
-+ if (error) {
-+ char *msg;
-+ msg = g_strdup_printf ("Could not pause '%s'",
-+ gnome_cups_printer_get_name (printer));
-+ handle_error (container, msg, error);
-+ g_free (msg);
-+ g_error_free (error);
-+ }
-+
-+ }
-+ g_list_free (selection);
-+}
-+
-+static void
-+resume_cb (BonoboUIComponent *component, gpointer user_data, const char *verb)
-+{
-+ NautilusPrinterContainer *container;
-+ GList *selection;
-+ GList *l;
-+ GnomeCupsPrinter *printer;
-+
-+ container = user_data;
-+
-+ selection = nautilus_icon_container_get_selection (NAUTILUS_ICON_CONTAINER (container));
-+ for (l = selection; l != NULL; l = l->next) {
-+ GError *error = NULL;
-+ g_return_if_fail (l->data != NEW_PRINTER_ICON);
-+ printer = GNOME_CUPS_PRINTER (l->data);
-+ gnome_cups_printer_resume (printer, &error);
-+ if (error) {
-+ char *msg;
-+ msg = g_strdup_printf ("Could not resume '%s'",
-+ gnome_cups_printer_get_name (printer));
-+ handle_error (container, msg, error);
-+ g_free (msg);
-+ g_error_free (error);
-+ }
-+
-+ }
-+ g_list_free (selection);
-+}
-+
-+static void
-+make_default_cb (BonoboUIComponent *component, gpointer user_data, const char *verb)
-+{
-+ NautilusPrinterContainer *container;
-+ GList *selection;
-+ GnomeCupsPrinter *printer;
-+ GError *error = NULL;
-+
-+ container = user_data;
-+
-+ selection = nautilus_icon_container_get_selection (NAUTILUS_ICON_CONTAINER (container));
-+ g_return_if_fail (g_list_length (selection) == 1);
-+ g_return_if_fail (selection->data != NEW_PRINTER_ICON);
-+
-+ printer = GNOME_CUPS_PRINTER (selection->data);
-+ gnome_cups_printer_set_default (printer, &error);
-+ if (error) {
-+ char *msg;
-+ msg = g_strdup_printf ("Could not make '%s' the default printer",
-+ gnome_cups_printer_get_name (printer));
-+ handle_error (container, msg, error);
-+ g_free (msg);
-+ g_error_free (error);
-+ }
-+
-+ g_list_free (selection);
-+}
-+
-+static void
-+delete_cb (BonoboUIComponent *component, gpointer user_data, const char *verb)
-+{
-+ NautilusPrinterContainer *container;
-+ GList *selection;
-+ GList *l;
-+ GnomeCupsPrinter *printer;
-+
-+ container = user_data;
-+
-+ selection = nautilus_icon_container_get_selection (NAUTILUS_ICON_CONTAINER (container));
-+ for (l = selection; l != NULL; l = l->next) {
-+ GError *error = NULL;
-+ g_return_if_fail (l->data != NEW_PRINTER_ICON);
-+ printer = GNOME_CUPS_PRINTER (l->data);
-+ gnome_cups_printer_delete (printer, &error);
-+ if (error) {
-+ char *msg;
-+ msg = g_strdup_printf ("Could not delete '%s'",
-+ gnome_cups_printer_get_name (printer));
-+ handle_error (container, msg, error);
-+ g_free (msg);
-+ g_error_free (error);
-+ }
-+
-+ }
-+ g_list_free (selection);
-+}
-+
-+static void
-+new_printer_cb (BonoboUIComponent *component, gpointer user_data, const char *verb)
-+{
-+ NautilusPrinterContainer *container;
-+
-+ container = user_data;
-+
-+ new_printer (container);
-+}
-+
-+static BonoboUIVerb verbs[] = {
-+ BONOBO_UI_VERB ("Open", open_cb),
-+ BONOBO_UI_VERB ("Pause", pause_cb),
-+ BONOBO_UI_VERB ("Resume", resume_cb),
-+ BONOBO_UI_VERB ("Make Default", make_default_cb),
-+ BONOBO_UI_VERB ("Delete", delete_cb),
-+ BONOBO_UI_VERB ("Properties", properties_cb),
-+ BONOBO_UI_VERB ("New Printer", new_printer_cb),
-+ BONOBO_UI_VERB_END,
-+};
-+
-+static void
-+control_activate_cb (BonoboObject *control,
-+ gboolean state,
-+ gpointer callback_data)
-+{
-+ NautilusView *view;
-+ NautilusPrinterContainer *container;
-+
-+ view = NAUTILUS_VIEW (callback_data);
-+ container = g_object_get_data (G_OBJECT (view), "container");
-+
-+ if (state) {
-+ container->ui = nautilus_view_set_up_ui (view, DATADIR,
-+ "nautilus-printers-view-ui.xml",
-+ "nautilus-printers");
-+ bonobo_ui_component_add_verb_list_with_data (container->ui,
-+ verbs,
-+ container);
-+ update_menus (container);
-+ }
-+ /* Nothing to do on deactivate case, which necer happens
-+ * because of the way nautilus content views are handled */
-+}
-+
-+static BonoboObject *
-+make_printers_view (void)
-+{
-+ GtkWidget *scrolled;
-+ NautilusView *view;
-+ NautilusPrinterContainer *container;
-+
-+ gnome_cups_ui_init (NULL);
-+
-+ scrolled = gtk_scrolled_window_new (NULL, NULL);
-+ gtk_scrolled_window_set_shadow_type (GTK_SCROLLED_WINDOW (scrolled),
-+ GTK_SHADOW_IN);
-+ gtk_scrolled_window_set_policy (GTK_SCROLLED_WINDOW (scrolled),
-+ GTK_POLICY_AUTOMATIC,
-+ GTK_POLICY_AUTOMATIC);
-+ container = g_object_new (nautilus_printer_container_get_type (), NULL);
-+ gtk_container_add (GTK_CONTAINER (scrolled),
-+ GTK_WIDGET (container));
-+
-+ update_click_mode (container);
-+ eel_preferences_add_callback (NAUTILUS_PREFERENCES_CLICK_POLICY,
-+ update_click_mode, container);
-+
-+
-+ nautilus_icon_container_set_auto_layout (NAUTILUS_ICON_CONTAINER (container), TRUE);
-+ nautilus_icon_container_add (NAUTILUS_ICON_CONTAINER (container),
-+ NEW_PRINTER_ICON);
-+
-+ gtk_widget_show_all (scrolled);
-+
-+ /* Create CORBA object. */
-+ view = nautilus_view_new (scrolled);
-+ g_object_set_data (G_OBJECT (view), "container", container);
-+
-+ g_signal_connect_object (nautilus_view_get_bonobo_control (view),
-+ "activate",
-+ G_CALLBACK (control_activate_cb), view, 0);
-+
-+ /* handle events */
-+ g_signal_connect (view, "load_location",
-+ G_CALLBACK (printers_load_location),
-+ container);
-+
-+ return BONOBO_OBJECT (view);
-+}
-+
-+static CORBA_Object
-+printers_shlib_make_object (PortableServer_POA poa,
-+ const char *iid,
-+ gpointer impl_ptr,
-+ CORBA_Environment *ev)
-+{
-+ BonoboObject *view;
-+
-+ if (strcmp (iid, VIEW_IID) != 0) {
-+ return CORBA_OBJECT_NIL;
-+ }
-+
-+ view = make_printers_view ();
-+
-+ bonobo_activation_plugin_use (poa, impl_ptr);
-+
-+ return CORBA_Object_duplicate (BONOBO_OBJREF (view), ev);
-+}
-+
-+static const BonoboActivationPluginObject printers_plugin_list[] = {
-+ { VIEW_IID, printers_shlib_make_object },
-+ { NULL }
-+};
-+
-+const BonoboActivationPlugin Bonobo_Plugin_info = {
-+ printers_plugin_list,
-+ "Nautilus Printers View"
-+};
-diff -Nru -x '*~' -x '*.o' -x '*.orig' -x '*.rej' nautilus-2.2.4.orig/components/printers/nautilus-printers-view-ui.xml nautilus-2.2.4/components/printers/nautilus-printers-view-ui.xml
---- nautilus-2.2.4.orig/components/printers/nautilus-printers-view-ui.xml 1969-12-31 19:00:00.000000000 -0500
-+++ nautilus-2.2.4/components/printers/nautilus-printers-view-ui.xml 2003-05-26 22:17:59.000000000 -0400
-@@ -0,0 +1,93 @@
-+<Root>
-+<commands>
-+ <cmd name="Delete"
-+ _label="_Delete"
-+ _tip="Delete each selected printer"/>
-+ <cmd name="New Printer"
-+ _label="_New Printer"
-+ _tip="Create a new printer"/>
-+ <cmd name="Open"
-+ _label="_Open"
-+ _tip="Open the selected item"/>
-+ <cmd name="Pause"
-+ _label="Pause"
-+ _tip="Pause the selected item"/>
-+ <cmd name="Resume"
-+ _label="Resume"
-+ _tip="Resume the selected item"/>
-+ <cmd name="Make Default"
-+ _label="Make _Default"
-+ _tip="Make the selected item the default"/>
-+ <cmd name="Properties"
-+ _label="_Properties"
-+ _tip="View or modify the properties of each selected item"/>
-+</commands>
-+<menu>
-+ <submenu name="File">
-+ <placeholder name="New Items Placeholder">
-+ <menuitem name="New Printer"
-+ accel="*Control*n"
-+ pixtype="stock" pixname="gtk-new"
-+ verb="New Printer"/>
-+ </placeholder>
-+ <placeholder name="Open Placeholder">
-+ <menuitem name="Open"
-+ accel="*Control*o"
-+ pixtype="stock" pixname="gtk-open"
-+ verb="Open"/>
-+ </placeholder>
-+ <placeholder name="File Items Placeholder">
-+ <menuitem name="Properties"
-+ accel="*Control*i"
-+ verb="Properties"/>
-+ </placeholder>
-+ </submenu>
-+
-+ <submenu name="Edit">
-+ <menuitem name="Select All"
-+ accel="*Control*a"
-+ verb="Select All"/>
-+
-+ <placeholder name="File Items Placeholder">
-+ <placeholder name="Printer Operations Placeholder" delimit="none">
-+ <menuitem name="Pause" verb="Pause"/>
-+ <menuitem name="Resume" verb="Resume"/>
-+ <menuitem name="Make Default" verb="Make Default"/>
-+ </placeholder>
-+ </placeholder>
-+
-+ <placeholder name="Dangerous File Items Placeholder">
-+ <menuitem name="Delete"
-+ verb="Delete"/>
-+ </placeholder>
-+
-+ </submenu>
-+</menu>
-+<popups>
-+ <popup name="background">
-+ <placeholder name="Before Zoom Items">
-+ <placeholder name="New Items">
-+ <menuitem name="New Printer"
-+ verb="New Printer"/>
-+ </placeholder>
-+ </placeholder>
-+ </popup>
-+
-+ <popup name="selection" tearoff="0">
-+ <placeholder name="Open Placeholder" delimit="none">
-+ <menuitem name="Open" verb="Open"
-+ pixtype="stock" pixname="gtk-open"/>
-+ </placeholder>
-+ <placeholder name="Printer Operations Placeholder" delimit="top">
-+ <menuitem name="Pause" verb="Pause"/>
-+ <menuitem name="Resume" verb="Resume"/>
-+ <menuitem name="Make Default" verb="Make Default"/>
-+ </placeholder>
-+ <placeholder name="Dangerous File Actions" delimit="top">
-+ <menuitem name="Delete" verb="Delete"/>
-+ </placeholder>
-+ <separator/>
-+ <menuitem name="Properties" verb="Properties"/>
-+ </popup>
-+</popups>
-+</Root>
-diff -Nru -x '*~' -x '*.o' -x '*.orig' -x '*.rej' nautilus-2.2.4.orig/components/printers/Nautilus_View_printers.server.in.in nautilus-2.2.4/components/printers/Nautilus_View_printers.server.in.in
---- nautilus-2.2.4.orig/components/printers/Nautilus_View_printers.server.in.in 1969-12-31 19:00:00.000000000 -0500
-+++ nautilus-2.2.4/components/printers/Nautilus_View_printers.server.in.in 2003-05-26 22:17:59.000000000 -0400
-@@ -0,0 +1,20 @@
-+<oaf_info>
-+
-+<oaf_server iid="OAFIID:Nautilus_Printers_View"
-+ type="shlib" location="@BONOBODIR@/libnautilus-printers-view.so">
-+ <oaf_attribute name="repo_ids" type="stringv">
-+ <item value="IDL:Bonobo/Unknown:1.0"/>
-+ <item value="IDL:Bonobo/Control:1.0"/>
-+ <item value="IDL:Nautilus/View:1.0"/>
-+ </oaf_attribute>
-+ <oaf_attribute name="description" type="string" _value="Printers view for nautilus"/>
-+ <oaf_attribute name="name" type="string" _value="Printers View"/>
-+ <oaf_attribute name="bonobo:supported_uri_schemes" type="stringv">
-+ <item value="printers"/>
-+ </oaf_attribute>
-+ <oaf_attribute name="nautilus:view_as_name" type="string" _value="Printers"/>
-+ <oaf_attribute name="nautilus:view_as_label" type="string" _value="View as Printers"/>
-+ <oaf_attribute name="nautilus:viewer_label" type="string" _value="Printer Viewer"/>
-+</oaf_server>
-+
-+</oaf_info>
-diff -Nru -x '*~' -x '*.o' -x '*.orig' -x '*.rej' nautilus-2.2.4.orig/configure.in nautilus-2.2.4/configure.in
---- nautilus-2.2.4.orig/configure.in 2003-05-07 13:51:36.000000000 -0400
-+++ nautilus-2.2.4/configure.in 2003-05-27 01:31:42.000000000 -0400
-@@ -296,6 +296,17 @@
- COMPONENT_LIBS="`$PKG_CONFIG --libs $COMPONENT_MODULES`"
- AC_SUBST(COMPONENT_LIBS)
-
-+dnl printer component
-+dnl FIXME: Make optional
-+
-+PRINTER_MODULES="eel-2.0 libbonoboui-2.0 gnome-vfs-module-2.0 gnome-desktop-2.0 libgnomecups-1.0 libgnomecupsui-1.0"
-+PKG_CHECK_MODULES(PRINTER, $PRINTER_MODULES)
-+PRINTER_CFLAGS="`$PKG_CONFIG --cflags $PRINTER_MODULES`"
-+AC_SUBST(PRINTER_CFLAGS)
-+PRINTER_LIBS="`$PKG_CONFIG --libs $PRINTER_MODULES`"
-+AC_SUBST(PRINTER_LIBS)
-+
-+
- dnl emblems component
- EMBLEM_COMPONENT_MODULES="$COMPONENT_MODULES librsvg-2.0"
- EMBLEM_COMPONENT_CFLAGS="`$PKG_CONFIG --cflags $EMBLEM_COMPONENT_MODULES`"
-@@ -352,6 +363,7 @@
- components/hardware/icons/Makefile
- components/history/Makefile
- components/notes/Makefile
-+components/printers/Makefile
- components/text/Makefile
- components/text/services/Makefile
- components/throbber/Makefile
diff --git a/gnome-base/nautilus/nautilus-2.10.1-r1.ebuild b/gnome-base/nautilus/nautilus-2.10.1-r1.ebuild
index 1c944a4a27f4..131873617b4b 100644
--- a/gnome-base/nautilus/nautilus-2.10.1-r1.ebuild
+++ b/gnome-base/nautilus/nautilus-2.10.1-r1.ebuild
@@ -1,6 +1,6 @@
# Copyright 1999-2005 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/gnome-base/nautilus/nautilus-2.10.1-r1.ebuild,v 1.1 2005/07/13 02:14:42 leonardop Exp $
+# $Header: /var/cvsroot/gentoo-x86/gnome-base/nautilus/nautilus-2.10.1-r1.ebuild,v 1.2 2005/07/26 23:25:35 leonardop Exp $
inherit gnome2 eutils
@@ -9,7 +9,7 @@ HOMEPAGE="http://www.gnome.org/projects/nautilus/"
LICENSE="GPL-2 LGPL-2 FDL-1.1"
SLOT="0"
-KEYWORDS="~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~sparc ~x86"
+KEYWORDS="~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~sparc x86"
IUSE="oggvorbis gstreamer mad flac"
# cups
@@ -79,18 +79,8 @@ src_unpack() {
# mode. See bug #95606.
epatch ${FILESDIR}/${P}-deselect.patch
- # -- Component architecture has changed in 2.9 -- this
-# -- patch no longer applies.
-
- # add libgnomeprint support
- # With extra 2.8 fun - fixes #65604
-# if use cups; then
-# if has_version ">=net-print/gnome-cups-manager-0.28"; then
-# epatch ${FILESDIR}/${PN}-2.8-x-printers.patch
-# else
-# epatch ${FILESDIR}/${PN}-2-x-printers.patch
-# fi
-# fi
+ # -- Component architecture has changed in 2.9 -- libgnomeprint patches
+ # no longer apply.
# stop nautilus linking to cdda/paranoia
sed -i -e "/^CORE_LIBS/s/\$CDDA_LIBS//" configure.in
diff --git a/gnome-base/nautilus/nautilus-2.10.1.ebuild b/gnome-base/nautilus/nautilus-2.10.1.ebuild
deleted file mode 100644
index 76b61bced647..000000000000
--- a/gnome-base/nautilus/nautilus-2.10.1.ebuild
+++ /dev/null
@@ -1,95 +0,0 @@
-# Copyright 1999-2005 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/gnome-base/nautilus/nautilus-2.10.1.ebuild,v 1.9 2005/07/12 12:39:57 leonardop Exp $
-
-inherit gnome2 eutils
-
-DESCRIPTION="A filemanager for the Gnome2 desktop"
-HOMEPAGE="http://www.gnome.org/projects/nautilus/"
-
-LICENSE="GPL-2 LGPL-2 FDL-1.1"
-SLOT="0"
-KEYWORDS="~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~sparc ~x86"
-IUSE="oggvorbis gstreamer mad flac"
-# cups
-
-RDEPEND=">=dev-libs/glib-2.6
- >=x11-libs/pango-1.2
- >=x11-libs/gtk+-2.3
- >=dev-libs/libxml2-2.4.7
- =gnome-base/eel-${PV}*
- >=gnome-base/gnome-vfs-2.9.1
- >=media-sound/esound-0.2.27
- >=gnome-base/gconf-2
- >=gnome-base/libgnome-2.6
- >=gnome-base/libgnomeui-2.6
- >=gnome-base/gnome-desktop-2.9.91
- >=media-libs/libart_lgpl-2.3.10
- >=gnome-base/libbonobo-2.2
- >=gnome-base/librsvg-2.0.1
- >=gnome-base/orbit-2.4
- >=x11-libs/startup-notification-0.8
- >=media-libs/libexif-0.5.12
- dev-libs/popt
- virtual/fam
- virtual/eject
- !gstreamer? ( oggvorbis? ( media-sound/vorbis-tools ) )
- gstreamer? (
- >=media-libs/gstreamer-0.8
- >=media-libs/gst-plugins-0.8
- >=media-plugins/gst-plugins-gnomevfs-0.8
- mad? ( >=media-plugins/gst-plugins-mad-0.8 )
- oggvorbis? (
- >=media-plugins/gst-plugins-ogg-0.8
- >=media-plugins/gst-plugins-vorbis-0.8
- )
- flac? ( >=media-plugins/gst-plugins-flac-0.8 )
- )"
-
-# FIXME : what to do with exif/jpeg config stuff ?
-
-DEPEND="${RDEPEND}
- sys-devel/gettext
- >=dev-util/intltool-0.29
- >=app-text/scrollkeeper-0.3.11
- >=dev-util/pkgconfig-0.12.0"
-
-PDEPEND=">=x11-themes/gnome-icon-theme-1.1.91
- x11-themes/gnome-themes"
-
-DOCS="AUTHORS ChangeLo* HACKING MAINTAINERS NEWS README THANKS TODO"
-
-G2CONF="${G2CONF} $(use_enable gstreamer)"
-
-src_unpack() {
-
- unpack ${A}
- cd ${S}
-
- # use gstreamer for audio preview (patch by <foser@gentoo.org>)
- use gstreamer && epatch ${FILESDIR}/${PN}-2.9.90-icon_view_gst.patch
-
- # -- Component architecture has changed in 2.9 -- this
-# -- patch no longer applies.
-
- # add libgnomeprint support
- # With extra 2.8 fun - fixes #65604
-# if use cups; then
-# if has_version ">=net-print/gnome-cups-manager-0.28"; then
-# epatch ${FILESDIR}/${PN}-2.8-x-printers.patch
-# else
-# epatch ${FILESDIR}/${PN}-2-x-printers.patch
-# fi
-# fi
-
- # stop nautilus linking to cdda/paranoia
- sed -i -e "/^CORE_LIBS/s/\$CDDA_LIBS//" configure.in
-
- if use gstreamer; then
- WANT_AUTOCONF=2.5 autoheader || die
- WANT_AUTOCONF=2.5 autoconf || die
- WANT_AUTOMAKE=1.7 automake || die
- fi
-}
-
-USE_DESTDIR="1"