diff options
author | Ettore Perazzoli <ettore@ximian.com> | 2001-08-29 11:49:21 +0800 |
---|---|---|
committer | Federico Mena Quintero <federico@src.gnome.org> | 2001-08-29 11:49:21 +0800 |
commit | 24a4d864f0ed2ea58e60e1efd83d817418896a1d (patch) | |
tree | e30e64f785c1139439621573a6b8e8fdddf60e84 /widgets/misc/e-search-bar.c | |
parent | cc3ec1cb4827f8deb3b755778ed657dc9c26430e (diff) | |
download | gsoc2013-evolution-24a4d864f0ed2ea58e60e1efd83d817418896a1d.tar gsoc2013-evolution-24a4d864f0ed2ea58e60e1efd83d817418896a1d.tar.gz gsoc2013-evolution-24a4d864f0ed2ea58e60e1efd83d817418896a1d.tar.bz2 gsoc2013-evolution-24a4d864f0ed2ea58e60e1efd83d817418896a1d.tar.lz gsoc2013-evolution-24a4d864f0ed2ea58e60e1efd83d817418896a1d.tar.xz gsoc2013-evolution-24a4d864f0ed2ea58e60e1efd83d817418896a1d.tar.zst gsoc2013-evolution-24a4d864f0ed2ea58e60e1efd83d817418896a1d.zip |
New prototype here.
2001-08-27 Ettore Perazzoli <ettore@ximian.com>
* e-timezone-dialog/e-timezone-dialog.h
(e_timezone_dialog_reparent): New prototype here.
svn path=/trunk/; revision=12511
Diffstat (limited to 'widgets/misc/e-search-bar.c')
-rw-r--r-- | widgets/misc/e-search-bar.c | 33 |
1 files changed, 33 insertions, 0 deletions
diff --git a/widgets/misc/e-search-bar.c b/widgets/misc/e-search-bar.c index 9f6d46a2bb..f96d8a8752 100644 --- a/widgets/misc/e-search-bar.c +++ b/widgets/misc/e-search-bar.c @@ -875,6 +875,39 @@ e_search_bar_get_subitem_id (ESearchBar *search_bar) } /** + * e_search_bar_set_ids: + * @search_bar: A search bar. + * @item_id: Identifier of the item to set. + * @subitem_id: Identifier of the subitem to set. + * + * Sets the item and subitem ids for a search bar. This is intended to switch + * to an item that has subitems. + **/ +void +e_search_bar_set_ids (ESearchBar *search_bar, int item_id, int subitem_id) +{ + int item_row; + GtkWidget *item_widget; + ESearchBarSubitem *subitems; + + g_return_if_fail (search_bar != NULL); + g_return_if_fail (E_IS_SEARCH_BAR (search_bar)); + + item_row = find_id (search_bar->option_menu, item_id, "EsbChoiceId", &item_widget); + g_return_if_fail (item_row != -1); + g_assert (item_widget != NULL); + + subitems = gtk_object_get_data (GTK_OBJECT (item_widget), "EsbChoiceSubitems"); + g_return_if_fail (subitems != NULL); + + search_bar->item_id = item_id; + gtk_option_menu_set_history (GTK_OPTION_MENU (search_bar->option), item_row); + + activate_by_subitems (search_bar, item_id, subitems); + e_search_bar_set_subitem_id (search_bar, subitem_id); +} + +/** * e_search_bar_set_text: * @search_bar: A search bar. * @text: Text to set in the search bar's entry line. |