diff options
author | Marco Pesenti Gritti <marco@gnome.org> | 2004-06-09 19:00:22 +0800 |
---|---|---|
committer | Marco Pesenti Gritti <marco@src.gnome.org> | 2004-06-09 19:00:22 +0800 |
commit | 029c9d46c634e62950ca2761deb0159f90a45cac (patch) | |
tree | 76f16e4990c168ecabd7279b84b421130da44d63 /lib/egg/egg-toolbars-model.c | |
parent | 97084e9c8c3435b994cdafe546b9f86e281ced5b (diff) | |
download | gsoc2013-epiphany-029c9d46c634e62950ca2761deb0159f90a45cac.tar gsoc2013-epiphany-029c9d46c634e62950ca2761deb0159f90a45cac.tar.gz gsoc2013-epiphany-029c9d46c634e62950ca2761deb0159f90a45cac.tar.bz2 gsoc2013-epiphany-029c9d46c634e62950ca2761deb0159f90a45cac.tar.lz gsoc2013-epiphany-029c9d46c634e62950ca2761deb0159f90a45cac.tar.xz gsoc2013-epiphany-029c9d46c634e62950ca2761deb0159f90a45cac.tar.zst gsoc2013-epiphany-029c9d46c634e62950ca2761deb0159f90a45cac.zip |
Retain custom types when moving items around
2004-06-09 Marco Pesenti Gritti <marco@gnome.org>
* lib/egg/egg-editable-toolbar.c: (drag_data_get_cb),
(set_item_drag_source), (create_item_from_action), (create_item),
(drag_data_received_cb), (egg_editable_toolbar_set_edit_mode):
* lib/egg/egg-toolbar-editor.c: (model_has_action):
* lib/egg/egg-toolbars-model.c: (egg_toolbars_model_item_nth):
* lib/egg/egg-toolbars-model.h:
* src/ephy-toolbars-model.c: (get_toolbar_and_item_pos),
(ephy_toolbars_model_class_init), (item_added):
Retain custom types when moving items around
Diffstat (limited to 'lib/egg/egg-toolbars-model.c')
-rwxr-xr-x | lib/egg/egg-toolbars-model.c | 20 |
1 files changed, 15 insertions, 5 deletions
diff --git a/lib/egg/egg-toolbars-model.c b/lib/egg/egg-toolbars-model.c index 0da5cbd69..7535c7d66 100755 --- a/lib/egg/egg-toolbars-model.c +++ b/lib/egg/egg-toolbars-model.c @@ -632,27 +632,37 @@ egg_toolbars_model_n_items (EggToolbarsModel *t, return g_node_n_children (toolbar); } -const char * +void egg_toolbars_model_item_nth (EggToolbarsModel *t, int toolbar_position, int position, - gboolean *is_separator) + gboolean *is_separator, + const char **id, + const char **type) { GNode *toolbar; GNode *item; EggToolbarsItem *idata; toolbar = g_node_nth_child (t->priv->toolbars, toolbar_position); - g_return_val_if_fail (toolbar != NULL, NULL); + g_return_if_fail (toolbar != NULL); item = g_node_nth_child (toolbar, position); - g_return_val_if_fail (item != NULL, NULL); + g_return_if_fail (item != NULL); idata = item->data; *is_separator = idata->separator; - return idata->id; + if (id) + { + *id = idata->id; + } + + if (type) + { + *type = idata->type; + } } int |