aboutsummaryrefslogtreecommitdiffstats
path: root/src/bookmarks
diff options
context:
space:
mode:
authorMarco Pesenti Gritti <marco@it.gnome.org>2003-05-11 20:24:35 +0800
committerMarco Pesenti Gritti <mpeseng@src.gnome.org>2003-05-11 20:24:35 +0800
commit1ffbaefc6b9d99f76fb666215709b6ab4e83d547 (patch)
treebf6cbc16d0f0a87c19ebcbe507f490c222a90d90 /src/bookmarks
parent3ab85f2df9c5f3201d984d7e6fbe65767f340143 (diff)
downloadgsoc2013-epiphany-1ffbaefc6b9d99f76fb666215709b6ab4e83d547.tar
gsoc2013-epiphany-1ffbaefc6b9d99f76fb666215709b6ab4e83d547.tar.gz
gsoc2013-epiphany-1ffbaefc6b9d99f76fb666215709b6ab4e83d547.tar.bz2
gsoc2013-epiphany-1ffbaefc6b9d99f76fb666215709b6ab4e83d547.tar.lz
gsoc2013-epiphany-1ffbaefc6b9d99f76fb666215709b6ab4e83d547.tar.xz
gsoc2013-epiphany-1ffbaefc6b9d99f76fb666215709b6ab4e83d547.tar.zst
gsoc2013-epiphany-1ffbaefc6b9d99f76fb666215709b6ab4e83d547.zip
Update
2003-05-11 Marco Pesenti Gritti <marco@it.gnome.org> * lib/egg/egg-action.c: * lib/egg/eggseparatortoolitem.c: * lib/egg/eggtoggletoolbutton.c: * lib/egg/eggtoolbar.c: * lib/egg/eggtoolbutton.c: * lib/egg/eggtoolitem.c: * lib/egg/eggtoolitem.h: Update * src/bookmarks/Makefile.am: * src/bookmarks/ephy-bookmarks.c: * src/bookmarks/ephy-bookmarks-export.c: * src/bookmarks/ephy-bookmarks-export.h: Export bookmarks in an rdf format (RSS was perfect, so I just used it instead of inventing a new one). This is useful to ensure compatibility in case of database formats changes. It will be used also as import format for ephy. Also I think it can be easily displayed, need to talk with Edd about the css url though. Thanks to Edd Dumbill for the help with this.
Diffstat (limited to 'src/bookmarks')
-rw-r--r--src/bookmarks/Makefile.am2
-rw-r--r--src/bookmarks/ephy-bookmarks.c11
2 files changed, 12 insertions, 1 deletions
diff --git a/src/bookmarks/Makefile.am b/src/bookmarks/Makefile.am
index 04ecbe356..6df51dd14 100644
--- a/src/bookmarks/Makefile.am
+++ b/src/bookmarks/Makefile.am
@@ -24,6 +24,8 @@ libephybookmarks_la_SOURCES = \
ephy-bookmark-action.h \
ephy-bookmarks-editor.c \
ephy-bookmarks-editor.h \
+ ephy-bookmarks-export.c \
+ ephy-bookmarks-export.h \
ephy-bookmarks-import.c \
ephy-bookmarks-import.h \
ephy-bookmark-properties.c \
diff --git a/src/bookmarks/ephy-bookmarks.c b/src/bookmarks/ephy-bookmarks.c
index 084d8a343..b67e5cd11 100644
--- a/src/bookmarks/ephy-bookmarks.c
+++ b/src/bookmarks/ephy-bookmarks.c
@@ -24,6 +24,7 @@
#include "ephy-tree-model-node.h"
#include "ephy-node-common.h"
#include "ephy-toolbars-model.h"
+#include "ephy-bookmarks-export.h"
#include <string.h>
#include <libgnome/gnome-i18n.h>
@@ -243,7 +244,7 @@ ephy_bookmarks_init_defaults (EphyBookmarks *eb)
ephy_bookmarks_add (eb, default_bookmarks[i].title,
default_bookmarks[i].location,
default_bookmarks[i].smart_url);
-
+
id = ephy_bookmarks_get_bookmark_id (eb, default_bookmarks[i].location);
ephy_toolbars_model_add_bookmark (model, FALSE, id);
}
@@ -289,6 +290,7 @@ ephy_bookmarks_save (EphyBookmarks *eb)
xmlNodePtr root;
GPtrArray *children;
int i;
+ char *rdf_file;
LOG ("Saving bookmarks")
@@ -329,6 +331,13 @@ ephy_bookmarks_save (EphyBookmarks *eb)
xmlSaveFormatFile (eb->priv->xml_file, doc, 1);
xmlFreeDoc(doc);
+
+ /* Export bookmarks in rdf */
+ rdf_file = g_build_filename (ephy_dot_dir (),
+ "bookmarks.rdf",
+ NULL);
+ ephy_bookmarks_export_rdf (eb, rdf_file);
+ g_free (rdf_file);
}
static double