summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNirbheek Chauhan <nirbheek@gentoo.org>2012-02-18 20:35:18 +0530
committerNirbheek Chauhan <nirbheek@gentoo.org>2012-02-18 21:11:32 +0530
commit8145c99e22a4068e58ebbc878e9e2bceacf2f770 (patch)
treeff9c0fbf452077eeca2c2b5cba3b4dc1e948f3c6 /gnome-extra/gnome-utils/files
parentgnome-extra/gnome-utils: add a patch to upload screenshots to imgur (diff)
downloadnirbheek-8145c99e22a4068e58ebbc878e9e2bceacf2f770.tar.gz
nirbheek-8145c99e22a4068e58ebbc878e9e2bceacf2f770.tar.bz2
nirbheek-8145c99e22a4068e58ebbc878e9e2bceacf2f770.zip
Brown-paper-bag fix
Just because it's your own damn overlay doesn't mean you don't test shit before pushing.
Diffstat (limited to 'gnome-extra/gnome-utils/files')
-rw-r--r--gnome-extra/gnome-utils/files/gnome-utils-3.2.1-upload-screenshots.patch (renamed from gnome-extra/gnome-utils/files/0001-New-feature-uploading-screenshots-to-imgur.com.patch)175
1 files changed, 73 insertions, 102 deletions
diff --git a/gnome-extra/gnome-utils/files/0001-New-feature-uploading-screenshots-to-imgur.com.patch b/gnome-extra/gnome-utils/files/gnome-utils-3.2.1-upload-screenshots.patch
index 7fb0ec7..4267108 100644
--- a/gnome-extra/gnome-utils/files/0001-New-feature-uploading-screenshots-to-imgur.com.patch
+++ b/gnome-extra/gnome-utils/files/gnome-utils-3.2.1-upload-screenshots.patch
@@ -1,26 +1,7 @@
-From 2cc75e214336b858a6e634bb109592dc712f9cd7 Mon Sep 17 00:00:00 2001
-From: Nirbheek Chauhan <nirbheek@gentoo.org>
-Date: Sat, 18 Feb 2012 20:03:53 +0530
-Subject: [PATCH] New feature: uploading screenshots to imgur.com
-
----
- configure.ac | 9 ++
- gnome-screenshot/Makefile.am | 6 ++
- gnome-screenshot/gnome-screenshot.c | 12 +++
- gnome-screenshot/gnome-screenshot.ui | 18 ++++
- gnome-screenshot/screenshot-dialog.c | 11 ---
- gnome-screenshot/screenshot-dialog.h | 12 +++
- gnome-screenshot/screenshot-share.c | 155 ++++++++++++++++++++++++++++++++++
- gnome-screenshot/screenshot-share.h | 32 +++++++
- 8 files changed, 244 insertions(+), 11 deletions(-)
- create mode 100644 gnome-screenshot/screenshot-share.c
- create mode 100644 gnome-screenshot/screenshot-share.h
-
-diff --git a/configure.ac b/configure.ac
-index d75bbe2..93b54f0 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -142,6 +142,15 @@ AS_IF([test "x$GCONFTOOL" = "xno"],
+diff -Naur gnome-utils-3.2.1//configure.ac gnome-utils-3.2.1.new//configure.ac
+--- gnome-utils-3.2.1//configure.ac 2011-10-17 19:44:53.000000000 +0530
++++ gnome-utils-3.2.1.new//configure.ac 2012-02-18 20:23:01.776675767 +0530
+@@ -142,6 +142,15 @@
[AC_MSG_ERROR([gconftool-2 executable not found in your path - should be installed with GConf])]
)
@@ -36,56 +17,24 @@ index d75bbe2..93b54f0 100644
# Baobab checks
PKG_CHECK_MODULES([LIBGTOP], [libgtop-2.0 >= $LIBGTOP_REQUIRED])
AC_SUBST(LIBGTOP_CFLAGS)
-diff --git a/gnome-screenshot/Makefile.am b/gnome-screenshot/Makefile.am
-index d9a11c7..3be0074 100644
---- a/gnome-screenshot/Makefile.am
-+++ b/gnome-screenshot/Makefile.am
-@@ -28,6 +28,8 @@ gnome_screenshot_SOURCES = \
- screenshot-interactive-dialog.h \
- screenshot-shadow.c \
- screenshot-shadow.h \
-+ screenshot-share.c \
-+ screenshot-share.h \
- screenshot-utils.c \
- screenshot-utils.h \
- $(NULL)
-@@ -36,6 +38,8 @@ gnome_screenshot_CFLAGS = \
- $(GLIB_CFLAGS) \
- $(GIO_CFLAGS) \
- $(LIBCANBERRA_GTK_CFLAGS) \
-+ $(LIBSOUP_CFLAGS) \
-+ $(JSON_GLIB_CFLAGS) \
- $(GTHREAD_CFLAGS) \
- $(GTK_CFLAGS) \
- $(NULL)
-@@ -47,6 +51,8 @@ gnome_screenshot_LDADD = \
- $(GLIB_LIBS) \
- $(GIO_LIBS) \
- $(LIBCANBERRA_GTK_LIBS) \
-+ $(LIBSOUP_LIBS) \
-+ $(JSON_GLIB_LIBS) \
- $(GTHREAD_LIBS) \
- $(GTK_LIBS) \
- -lm \
-diff --git a/gnome-screenshot/gnome-screenshot.c b/gnome-screenshot/gnome-screenshot.c
-index 3390914..714b2d1 100644
---- a/gnome-screenshot/gnome-screenshot.c
-+++ b/gnome-screenshot/gnome-screenshot.c
+diff -Naur gnome-utils-3.2.1//gnome-screenshot/gnome-screenshot.c gnome-utils-3.2.1.new//gnome-screenshot/gnome-screenshot.c
+--- gnome-utils-3.2.1//gnome-screenshot/gnome-screenshot.c 2011-10-17 19:40:18.000000000 +0530
++++ gnome-utils-3.2.1.new//gnome-screenshot/gnome-screenshot.c 2012-02-18 20:29:34.978650924 +0530
@@ -1,4 +1,5 @@
/* gnome-screenshot.c - Take a screenshot of the desktop
+ * vim: set sts=2 sw=2 et :
*
* Copyright (C) 2001 Jonathan Blandford <jrb@alum.mit.edu>
* Copyright (C) 2006 Emmanuele Bassi <ebassi@gnome.org>
-@@ -47,6 +48,7 @@
- #include "screenshot-filename-builder.h"
- #include "screenshot-interactive-dialog.h"
+@@ -42,6 +43,7 @@
+ #include <canberra-gtk.h>
+
#include "screenshot-shadow.h"
+#include "screenshot-share.h"
#include "screenshot-utils.h"
+ #include "screenshot-save.h"
#include "screenshot-dialog.h"
- #include "cheese-flash.h"
-@@ -260,6 +262,13 @@ screenshot_save_to_clipboard (void)
+@@ -722,6 +724,13 @@
}
static void
@@ -99,20 +48,20 @@ index 3390914..714b2d1 100644
screenshot_dialog_response_cb (GtkDialog *d,
gint response_id,
ScreenshotDialog *dialog)
-@@ -275,6 +284,9 @@ screenshot_dialog_response_cb (GtkDialog *d,
- case SCREENSHOT_RESPONSE_COPY:
- screenshot_save_to_clipboard ();
- break;
-+ case SCREENSHOT_RESPONSE_UPLOAD:
+@@ -745,6 +754,10 @@
+ try_to_save (dialog);
+ }
+ }
++ else if (response_id == SCREENSHOT_RESPONSE_UPLOAD)
++ {
+ screenshot_upload (dialog);
-+ break;
- default:
- gtk_widget_destroy (GTK_WIDGET (d));
- gtk_main_quit ();
-diff --git a/gnome-screenshot/gnome-screenshot.ui b/gnome-screenshot/gnome-screenshot.ui
-index 62f1265..6ce9612 100644
---- a/gnome-screenshot/gnome-screenshot.ui
-+++ b/gnome-screenshot/gnome-screenshot.ui
++ }
+ else if (response_id == SCREENSHOT_RESPONSE_COPY)
+ {
+ GtkClipboard *clipboard;
+diff -Naur gnome-utils-3.2.1//gnome-screenshot/gnome-screenshot.ui gnome-utils-3.2.1.new//gnome-screenshot/gnome-screenshot.ui
+--- gnome-utils-3.2.1//gnome-screenshot/gnome-screenshot.ui 2011-09-28 02:57:36.000000000 +0530
++++ gnome-utils-3.2.1.new//gnome-screenshot/gnome-screenshot.ui 2012-02-18 20:23:01.779675766 +0530
@@ -42,6 +42,23 @@
</packing>
</child>
@@ -145,12 +94,41 @@ index 62f1265..6ce9612 100644
</action-widgets>
</object>
</interface>
-diff --git a/gnome-screenshot/screenshot-dialog.c b/gnome-screenshot/screenshot-dialog.c
-index d6d954d..6cb8bba 100644
---- a/gnome-screenshot/screenshot-dialog.c
-+++ b/gnome-screenshot/screenshot-dialog.c
-@@ -36,17 +36,6 @@ static GtkTargetEntry drag_types[] =
- { "image/png", 0, TYPE_IMAGE_PNG },
+diff -Naur gnome-utils-3.2.1//gnome-screenshot/Makefile.am gnome-utils-3.2.1.new//gnome-screenshot/Makefile.am
+--- gnome-utils-3.2.1//gnome-screenshot/Makefile.am 2011-10-17 19:35:06.000000000 +0530
++++ gnome-utils-3.2.1.new//gnome-screenshot/Makefile.am 2012-02-18 20:23:01.777675767 +0530
+@@ -19,6 +19,8 @@
+ screenshot-dialog.h \
+ screenshot-shadow.c \
+ screenshot-shadow.h \
++ screenshot-share.c \
++ screenshot-share.h \
+ screenshot-utils.c \
+ screenshot-utils.h \
+ screenshot-save.c \
+@@ -29,6 +31,8 @@
+ $(GLIB_CFLAGS) \
+ $(GIO_CFLAGS) \
+ $(LIBCANBERRA_GTK_CFLAGS) \
++ $(LIBSOUP_CFLAGS) \
++ $(JSON_GLIB_CFLAGS) \
+ $(GTHREAD_CFLAGS) \
+ $(GTK_CFLAGS) \
+ $(NULL)
+@@ -40,6 +44,8 @@
+ $(GLIB_LIBS) \
+ $(GIO_LIBS) \
+ $(LIBCANBERRA_GTK_LIBS) \
++ $(LIBSOUP_LIBS) \
++ $(JSON_GLIB_LIBS) \
+ $(GTHREAD_LIBS) \
+ $(GTK_LIBS) \
+ -lm \
+diff -Naur gnome-utils-3.2.1//gnome-screenshot/screenshot-dialog.c gnome-utils-3.2.1.new//gnome-screenshot/screenshot-dialog.c
+--- gnome-utils-3.2.1//gnome-screenshot/screenshot-dialog.c 2011-10-17 19:35:06.000000000 +0530
++++ gnome-utils-3.2.1.new//gnome-screenshot/screenshot-dialog.c 2012-02-18 20:23:01.779675766 +0530
+@@ -39,17 +39,6 @@
+ { "text/uri-list", 0, TYPE_TEXT_URI_LIST },
};
-struct ScreenshotDialog
@@ -167,10 +145,9 @@ index d6d954d..6cb8bba 100644
static void
on_preview_draw (GtkWidget *drawing_area,
cairo_t *cr,
-diff --git a/gnome-screenshot/screenshot-dialog.h b/gnome-screenshot/screenshot-dialog.h
-index 7741198..8f2cff7 100644
---- a/gnome-screenshot/screenshot-dialog.h
-+++ b/gnome-screenshot/screenshot-dialog.h
+diff -Naur gnome-utils-3.2.1//gnome-screenshot/screenshot-dialog.h gnome-utils-3.2.1.new//gnome-screenshot/screenshot-dialog.h
+--- gnome-utils-3.2.1//gnome-screenshot/screenshot-dialog.h 2011-10-17 19:35:06.000000000 +0530
++++ gnome-utils-3.2.1.new//gnome-screenshot/screenshot-dialog.h 2012-02-18 20:23:01.780675765 +0530
@@ -22,10 +22,22 @@
#include <gtk/gtk.h>
@@ -193,13 +170,11 @@ index 7741198..8f2cff7 100644
+#define SCREENSHOT_RESPONSE_UPLOAD 2
ScreenshotDialog *screenshot_dialog_new (GdkPixbuf *screenshot,
- char *initial_uri);
-diff --git a/gnome-screenshot/screenshot-share.c b/gnome-screenshot/screenshot-share.c
-new file mode 100644
-index 0000000..2442cfa
---- /dev/null
-+++ b/gnome-screenshot/screenshot-share.c
-@@ -0,0 +1,155 @@
+ char *initial_uri,
+diff -Naur gnome-utils-3.2.1//gnome-screenshot/screenshot-share.c gnome-utils-3.2.1.new//gnome-screenshot/screenshot-share.c
+--- gnome-utils-3.2.1//gnome-screenshot/screenshot-share.c 1970-01-01 05:30:00.000000000 +0530
++++ gnome-utils-3.2.1.new//gnome-screenshot/screenshot-share.c 2012-02-18 20:23:01.780675765 +0530
+@@ -0,0 +1,156 @@
+/* screenshot-share.c - online screenshot sharing
+ * vim: set sts=2 sw=2 et :
+ *
@@ -220,13 +195,14 @@ index 0000000..2442cfa
+ * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+ */
+
++#include <math.h>
++
+#include <glib.h>
+#include <gtk/gtk.h>
+#include <libsoup/soup.h>
+#include <json-glib/json-glib.h>
+#include <gdk-pixbuf/gdk-pixbuf.h>
+
-+#include "gnome-screenshot.h"
+#include "screenshot-share.h"
+#include "screenshot-dialog.h"
+
@@ -355,11 +331,9 @@ index 0000000..2442cfa
+ g_app_info_launch_default_for_uri (image_uri, NULL, NULL);
+ g_app_info_launch_default_for_uri (delete_uri, NULL, NULL);
+}
-diff --git a/gnome-screenshot/screenshot-share.h b/gnome-screenshot/screenshot-share.h
-new file mode 100644
-index 0000000..6d39220
---- /dev/null
-+++ b/gnome-screenshot/screenshot-share.h
+diff -Naur gnome-utils-3.2.1//gnome-screenshot/screenshot-share.h gnome-utils-3.2.1.new//gnome-screenshot/screenshot-share.h
+--- gnome-utils-3.2.1//gnome-screenshot/screenshot-share.h 1970-01-01 05:30:00.000000000 +0530
++++ gnome-utils-3.2.1.new//gnome-screenshot/screenshot-share.h 2012-02-18 20:23:01.780675765 +0530
@@ -0,0 +1,32 @@
+/* screenshot-share.h - online screenshot sharing
+ * vim: set sts=2 sw=2 et :
@@ -393,6 +367,3 @@ index 0000000..6d39220
+G_END_DECLS
+
+#endif /* __SCREENSHOT_SHARE_H__ */
---
-1.7.3.4
-