diff options
author | Marco Pesenti Gritti <marco@gnome.org> | 2003-10-30 19:52:45 +0800 |
---|---|---|
committer | Marco Pesenti Gritti <marco@src.gnome.org> | 2003-10-30 19:52:45 +0800 |
commit | a28245ea668203b1b2ffabb0b054660e88986a3f (patch) | |
tree | a5c2d1a9d1967d21d622839f6869c00e5debfaeb | |
parent | 956c01fa73fe077bcec0d9cb92d6284dabc037bc (diff) | |
download | gsoc2013-epiphany-a28245ea668203b1b2ffabb0b054660e88986a3f.tar gsoc2013-epiphany-a28245ea668203b1b2ffabb0b054660e88986a3f.tar.gz gsoc2013-epiphany-a28245ea668203b1b2ffabb0b054660e88986a3f.tar.bz2 gsoc2013-epiphany-a28245ea668203b1b2ffabb0b054660e88986a3f.tar.lz gsoc2013-epiphany-a28245ea668203b1b2ffabb0b054660e88986a3f.tar.xz gsoc2013-epiphany-a28245ea668203b1b2ffabb0b054660e88986a3f.tar.zst gsoc2013-epiphany-a28245ea668203b1b2ffabb0b054660e88986a3f.zip |
Add a title param to dnd iterator and remove unused screen location
2003-10-30 Marco Pesenti Gritti <marco@gnome.org>
* lib/ephy-dnd.c: (add_one_netscape_url), (add_one_uri),
(add_one_topic):
* lib/ephy-dnd.h:
* lib/widgets/ephy-tree-model-sort.c:
(each_property_get_data_binder):
* src/ephy-favicon-action.c: (each_url_get_data_binder):
Add a title param to dnd iterator and remove unused screen
location params.
-rw-r--r-- | ChangeLog | 12 | ||||
-rw-r--r-- | lib/ephy-dnd.c | 14 | ||||
-rw-r--r-- | lib/ephy-dnd.h | 2 | ||||
-rw-r--r-- | lib/widgets/ephy-tree-model-sort.c | 2 | ||||
-rw-r--r-- | src/ephy-favicon-action.c | 6 |
5 files changed, 25 insertions, 11 deletions
@@ -1,3 +1,15 @@ +2003-10-30 Marco Pesenti Gritti <marco@gnome.org> + + * lib/ephy-dnd.c: (add_one_netscape_url), (add_one_uri), + (add_one_topic): + * lib/ephy-dnd.h: + * lib/widgets/ephy-tree-model-sort.c: + (each_property_get_data_binder): + * src/ephy-favicon-action.c: (each_url_get_data_binder): + + Add a title param to dnd iterator and remove unused screen + location params. + 2003-10-29 Christian Persch <chpe@cvs.gnome.org> * embed/ephy-history.c: (ephy_history_add_host), diff --git a/lib/ephy-dnd.c b/lib/ephy-dnd.c index a9e4b0c33..857dd26df 100644 --- a/lib/ephy-dnd.c +++ b/lib/ephy-dnd.c @@ -31,18 +31,24 @@ * GMC also fails to do this as well. */ static void -add_one_netscape_url (const char *url, int x, int y, int w, int h, gpointer data) +add_one_netscape_url (const char *url, const char *title, gpointer data) { GString *result; result = (GString *) data; - if (result->len == 0) { + if (result->len == 0) + { g_string_append (result, url); + if (title) + { + g_string_append (result, "\n"); + g_string_append (result, title); + } } } static void -add_one_uri (const char *uri, int x, int y, int w, int h, gpointer data) +add_one_uri (const char *uri, const char *title, gpointer data) { GString *result; @@ -53,7 +59,7 @@ add_one_uri (const char *uri, int x, int y, int w, int h, gpointer data) } static void -add_one_topic (const char *uri, int x, int y, int w, int h, gpointer data) +add_one_topic (const char *uri, const char *title, gpointer data) { GString *result; diff --git a/lib/ephy-dnd.h b/lib/ephy-dnd.h index 8f6a16a51..d65d2fd3c 100644 --- a/lib/ephy-dnd.h +++ b/lib/ephy-dnd.h @@ -32,7 +32,7 @@ G_BEGIN_DECLS #define EPHY_DND_TOPIC_TYPE "ephy_topic_node" typedef void (* EphyDragEachSelectedItemDataGet) (const char *url, - int x, int y, int w, int h, + const char *title, gpointer data); typedef void (* EphyDragEachSelectedItemIterator) (EphyDragEachSelectedItemDataGet iteratee, diff --git a/lib/widgets/ephy-tree-model-sort.c b/lib/widgets/ephy-tree-model-sort.c index 40c519aa2..97e276150 100644 --- a/lib/widgets/ephy-tree-model-sort.c +++ b/lib/widgets/ephy-tree-model-sort.c @@ -188,7 +188,7 @@ each_property_get_data_binder (EphyDragEachSelectedItemDataGet iteratee, LOG ("Data get %s", svalue) - iteratee (svalue, -1, -1, -1, -1, data); + iteratee (svalue, NULL, data); gtk_tree_path_free (path); g_value_unset (&value); diff --git a/src/ephy-favicon-action.c b/src/ephy-favicon-action.c index 9e68af1f3..e3c39ac0c 100644 --- a/src/ephy-favicon-action.c +++ b/src/ephy-favicon-action.c @@ -94,7 +94,6 @@ each_url_get_data_binder (EphyDragEachSelectedItemDataGet iteratee, { const char *title; char *location; - char *netscape_url; EphyTab *tab; EphyEmbed *embed; EphyWindow *window = EPHY_WINDOW(iterator_context); @@ -104,11 +103,8 @@ each_url_get_data_binder (EphyDragEachSelectedItemDataGet iteratee, ephy_embed_get_location (embed, TRUE, &location); title = ephy_tab_get_title (tab); - netscape_url = g_strconcat (location, "\n", title, NULL); + iteratee (location, title, data); - iteratee (netscape_url, -1, -1, -1, -1, data); - - g_free (netscape_url); g_free (location); } |