summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Gryniewicz <dang@gentoo.org>2007-03-22 19:57:23 +0000
committerDaniel Gryniewicz <dang@gentoo.org>2007-03-22 19:57:23 +0000
commit6a5e84715e069b5ba758b6610fb4a587947e032e (patch)
tree5f53e927be5b628501894fdc64ae0a330536bcf0
parentBump to 0.1.4.2 (diff)
downloadmaintainer-6a5e84715e069b5ba758b6610fb4a587947e032e.tar.gz
maintainer-6a5e84715e069b5ba758b6610fb4a587947e032e.tar.bz2
maintainer-6a5e84715e069b5ba758b6610fb4a587947e032e.zip
Dates with import-ical-files patch
svn path=/maintainer/; revision=39
-rw-r--r--gnome-extra/dates/Manifest12
-rw-r--r--gnome-extra/dates/dates-0.3.1.ebuild28
-rw-r--r--gnome-extra/dates/files/dates-0.3.1-open-ical.patch146
-rw-r--r--gnome-extra/dates/files/digest-dates-0.3.13
4 files changed, 189 insertions, 0 deletions
diff --git a/gnome-extra/dates/Manifest b/gnome-extra/dates/Manifest
new file mode 100644
index 0000000..5eb292a
--- /dev/null
+++ b/gnome-extra/dates/Manifest
@@ -0,0 +1,12 @@
+AUX dates-0.3.1-open-ical.patch 3877 RMD160 9f7c2d466f373e301e1e1dbcf2254176fcf6a3d1 SHA1 71f8596c67bf7f262a9f80c845155f9dd989087f SHA256 7a1d0a71d8ed21ee7d646359d1d9612876556e50dac2f6111e576d8737469a52
+MD5 547c01b607a0faeccf27dca7e6fee4a5 files/dates-0.3.1-open-ical.patch 3877
+RMD160 9f7c2d466f373e301e1e1dbcf2254176fcf6a3d1 files/dates-0.3.1-open-ical.patch 3877
+SHA256 7a1d0a71d8ed21ee7d646359d1d9612876556e50dac2f6111e576d8737469a52 files/dates-0.3.1-open-ical.patch 3877
+DIST dates-0.3.1.tar.bz2 442196 RMD160 94b6d4a087955afae4e1817a850310c782a612f0 SHA1 18d30aeb8beff4f2fe0e9a0acc6cf7bbbc83eb41 SHA256 ad043858febc8306dc5281c0587632bc759d10592aa816188f01d5528dbb5efe
+EBUILD dates-0.3.1.ebuild 622 RMD160 00cbe380a6930111091ec8fa62a8a7ce96f9166a SHA1 2207377ba0ba778b3746a7c56ab7786fcd8fc00c SHA256 2ef1a770562d8e1e04b83bd4ab138fe6317b89ed1c46d17da9dee0a60ecf966a
+MD5 99aed642d873c663d10bdbede37243af dates-0.3.1.ebuild 622
+RMD160 00cbe380a6930111091ec8fa62a8a7ce96f9166a dates-0.3.1.ebuild 622
+SHA256 2ef1a770562d8e1e04b83bd4ab138fe6317b89ed1c46d17da9dee0a60ecf966a dates-0.3.1.ebuild 622
+MD5 7b751b535922e8dc95a67906d4b4fd55 files/digest-dates-0.3.1 238
+RMD160 4bade28fceb2e79216421799227dd76deb4c7865 files/digest-dates-0.3.1 238
+SHA256 ec39c8e2dc48523af3b75dd7e88d6192eb40bf0d576ad3cd1a440772794bc0db files/digest-dates-0.3.1 238
diff --git a/gnome-extra/dates/dates-0.3.1.ebuild b/gnome-extra/dates/dates-0.3.1.ebuild
new file mode 100644
index 0000000..b467e94
--- /dev/null
+++ b/gnome-extra/dates/dates-0.3.1.ebuild
@@ -0,0 +1,28 @@
+# Copyright 1999-2007 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: $
+
+inherit gnome2 eutils
+
+DESCRIPTION="A GTK Calendar frontend to Evolution Data Server"
+HOMEPAGE="http://projects.o-hand.com/dates"
+SRC_URI="http://www.gryniewicz.com/gentoo/${P}.tar.bz2"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE=""
+
+RDEPEND=">=dev-libs/glib-2
+ >=x11-libs/gtk+-2
+ >=gnome-extra/evolution-data-server-1.2
+ >=gnome-base/gconf-2"
+DEPEND="${RDEPEND}
+ >=dev-util/intltool-0.35
+ dev-util/pkgconfig"
+
+src_unpack() {
+ gnome2_src_unpack
+
+ epatch "${FILESDIR}"/${P}-open-ical.patch
+}
diff --git a/gnome-extra/dates/files/dates-0.3.1-open-ical.patch b/gnome-extra/dates/files/dates-0.3.1-open-ical.patch
new file mode 100644
index 0000000..53dab52
--- /dev/null
+++ b/gnome-extra/dates/files/dates-0.3.1-open-ical.patch
@@ -0,0 +1,146 @@
+Index: src/dates_callbacks.c
+===================================================================
+--- src/dates_callbacks.c (revision 355)
++++ src/dates_callbacks.c (working copy)
+@@ -21,6 +21,10 @@
+
+ #include <gdk/gdkkeysyms.h>
+ #include <string.h>
++#include <sys/types.h>
++#include <sys/stat.h>
++#include <unistd.h>
++#include <stdio.h>
+
+ #include <libecal/e-cal-time-util.h>
+ #include <libical/icaltime.h>
+@@ -627,6 +631,7 @@ dates_ical_drop_cb (DatesView *view, con
+ icalcomponent *icalcomp, *icalcomp2;
+ gint events;
+
++ g_warning("DFG d: %p", d);
+ if (!d->cal_loaded) {
+ /* TODO: Toggle the default calendar here maybe? */
+ g_warning ("No calendars selected to add new event to");
+@@ -673,6 +678,44 @@ dates_ical_drop_cb (DatesView *view, con
+ icalcomponent_free (icalcomp);
+ }
+
++gboolean
++dates_ical_option_cb (void *userdata)
++{
++ FILE *f;
++ struct stat st;
++ gchar *ical;
++ size_t size;
++ struct ical_open *open = userdata;
++
++ if (stat(open->ical_file, &st)) {
++ g_error ("Could not stat ical file %s", open->ical_file);
++ return (FALSE);
++ }
++
++ ical = g_malloc0(st.st_size + 1);
++ if (!ical) {
++ g_error ("Could not allocate buffer for ical file (%z)", st.st_size + 1);
++ return (FALSE);
++ }
++
++ f = fopen(open->ical_file, "r");
++ if (!f) {
++ g_error ("Could not open ical file %s for importing", open->ical_file);
++ return (FALSE);
++ }
++
++ size = fread(ical, sizeof(char), st.st_size, f);
++ if (size != st.st_size) {
++ g_error ("Error importing ical file: Not enough read: got %z expected %u", size, st.st_size);
++ return (FALSE);
++ }
++
++ g_warning("ical: %s", ical);
++ dates_ical_drop_cb(open->data->view, ical, open->data);
++ g_free(ical);
++ return (FALSE);
++}
++
+ void
+ dates_details_time_entry_changed (GtkEditable *entry, gchar *new_text,
+ gint new_text_length,
+Index: src/dates_main.c
+===================================================================
+--- src/dates_main.c (revision 355)
++++ src/dates_main.c (working copy)
+@@ -325,6 +325,7 @@ main (int argc, char **argv)
+ GConfBridge *bridge;
+ GOptionContext *context;
+ static gint plug = 0;
++ static gchar *ical = NULL;
+ #ifdef DEBUG
+ const gchar *debug;
+ #endif
+@@ -332,6 +333,8 @@ main (int argc, char **argv)
+ static GOptionEntry entries[] = {
+ { "plug", 'p', 0, G_OPTION_ARG_INT, &plug,
+ "Socket ID of an XEmbed socket to plug into", NULL },
++ { "ical", 'i', 0, G_OPTION_ARG_STRING, &ical,
++ "ICal file to import", NULL },
+ { NULL }
+ };
+
+@@ -501,6 +504,26 @@ main (int argc, char **argv)
+ gtk_widget_show (data.main_window);
+ }
+
++ if (ical) {
++ struct ical_open *open = g_malloc0(sizeof(struct ical_open));
++ if (!open) {
++ g_error ("Failed to malloc ical_open!");
++ exit(1);
++ }
++ open->ical_file = g_strdup(ical);
++ if (!open->ical_file) {
++ g_error ("Failed to malloc ical_open!");
++ g_free(open);
++ exit(1);
++ }
++ open->data = &data;
++
++#ifdef DEBUG
++ g_debug ("Loading ical file %s", open->ical_file);
++#endif
++ g_idle_add (dates_ical_option_cb, open);
++ }
++
+ gtk_main ();
+
+ /* clean up */
+Index: src/dates_callbacks.h
+===================================================================
+--- src/dates_callbacks.h (revision 355)
++++ src/dates_callbacks.h (working copy)
+@@ -65,6 +65,9 @@ dates_event_sized_cb (DatesView *view, E
+ void
+ dates_ical_drop_cb (DatesView *view, const gchar *ical, DatesData *d);
+
++gboolean
++dates_ical_option_cb (void *userdata);
++
+ void
+ dates_details_time_entry_changed (GtkEditable *entry, gchar *new_text,
+ gint new_text_length,
+Index: src/dates_types.h
+===================================================================
+--- src/dates_types.h (revision 355)
++++ src/dates_types.h (working copy)
+@@ -155,5 +155,11 @@ typedef struct {
+ #endif
+ } DatesData;
+
++/* Hack for open of ical */
++struct ical_open {
++ DatesData *data;
++ gchar *ical_file;
++};
++
+
+ #endif /* DATES_TYPES_H */
diff --git a/gnome-extra/dates/files/digest-dates-0.3.1 b/gnome-extra/dates/files/digest-dates-0.3.1
new file mode 100644
index 0000000..6a2e9eb
--- /dev/null
+++ b/gnome-extra/dates/files/digest-dates-0.3.1
@@ -0,0 +1,3 @@
+MD5 425ee1b307a63278f151bd4958657f14 dates-0.3.1.tar.bz2 442196
+RMD160 94b6d4a087955afae4e1817a850310c782a612f0 dates-0.3.1.tar.bz2 442196
+SHA256 ad043858febc8306dc5281c0587632bc759d10592aa816188f01d5528dbb5efe dates-0.3.1.tar.bz2 442196