aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--calendar/gui/dialogs/comp-editor.c6
-rw-r--r--calendar/gui/dialogs/event-editor.c2
-rw-r--r--doc/reference/libeutil/libeutil-docs.sgml1
-rw-r--r--doc/reference/libeutil/libeutil-sections.txt22
-rw-r--r--doc/reference/libeutil/libeutil.types1
-rw-r--r--e-util/Makefile.am2
-rw-r--r--e-util/e-attachment-view.c3
-rw-r--r--e-util/e-plugin-ui.c10
-rw-r--r--e-util/e-ui-manager.c323
-rw-r--r--e-util/e-ui-manager.h78
-rw-r--r--e-util/e-util.h1
-rw-r--r--mail/e-mail-browser.c10
-rw-r--r--modules/mail/e-mail-shell-view.c4
-rw-r--r--shell/e-shell-view.c4
-rw-r--r--shell/e-shell-window-actions.c4
-rw-r--r--shell/e-shell-window-private.c2
16 files changed, 17 insertions, 456 deletions
diff --git a/calendar/gui/dialogs/comp-editor.c b/calendar/gui/dialogs/comp-editor.c
index f269cf226b..77477c319d 100644
--- a/calendar/gui/dialogs/comp-editor.c
+++ b/calendar/gui/dialogs/comp-editor.c
@@ -2030,9 +2030,7 @@ comp_editor_init (CompEditor *editor)
priv->is_group_item = FALSE;
priv->saved = FALSE;
- priv->ui_manager = e_ui_manager_new ();
- e_ui_manager_set_express_mode (
- E_UI_MANAGER (priv->ui_manager), express_mode);
+ priv->ui_manager = gtk_ui_manager_new ();
gtk_window_add_accel_group (
GTK_WINDOW (editor),
@@ -2142,7 +2140,7 @@ comp_editor_init (CompEditor *editor)
action = comp_editor_get_action (editor, "save");
gtk_action_set_sensitive (action, FALSE);
- e_ui_manager_add_ui_from_string (E_UI_MANAGER (priv->ui_manager), ui, &error);
+ gtk_ui_manager_add_ui_from_string (priv->ui_manager, ui, -1, &error);
if (error != NULL) {
g_warning ("%s: %s", G_STRFUNC, error->message);
g_error_free (error);
diff --git a/calendar/gui/dialogs/event-editor.c b/calendar/gui/dialogs/event-editor.c
index 81517c3cdd..16f83d1e84 100644
--- a/calendar/gui/dialogs/event-editor.c
+++ b/calendar/gui/dialogs/event-editor.c
@@ -559,7 +559,7 @@ event_editor_init (EventEditor *ee)
G_N_ELEMENTS (meeting_entries), ee);
ui_manager = comp_editor_get_ui_manager (editor);
- e_ui_manager_add_ui_from_string (E_UI_MANAGER (ui_manager), ui, &error);
+ gtk_ui_manager_add_ui_from_string (ui_manager, ui, -1, &error);
id = "org.gnome.evolution.event-editor";
e_plugin_ui_register_manager (ui_manager, id, ee);
diff --git a/doc/reference/libeutil/libeutil-docs.sgml b/doc/reference/libeutil/libeutil-docs.sgml
index 701cdceb1c..2442b435eb 100644
--- a/doc/reference/libeutil/libeutil-docs.sgml
+++ b/doc/reference/libeutil/libeutil-docs.sgml
@@ -266,7 +266,6 @@
<xi:include href="xml/e-spell-entry.xml"/>
<xi:include href="xml/e-timezone-dialog.xml"/>
<xi:include href="xml/e-tree-model-generator.xml"/>
- <xi:include href="xml/e-ui-manager.xml"/>
<xi:include href="xml/e-url-entry.xml"/>
</chapter>
diff --git a/doc/reference/libeutil/libeutil-sections.txt b/doc/reference/libeutil/libeutil-sections.txt
index 6300e8c10a..d9d75fb9ab 100644
--- a/doc/reference/libeutil/libeutil-sections.txt
+++ b/doc/reference/libeutil/libeutil-sections.txt
@@ -4488,28 +4488,6 @@ e_xml_get_translated_utf8_string_prop_by_name
</SECTION>
<SECTION>
-<FILE>e-ui-manager</FILE>
-<TITLE>EUIManager</TITLE>
-EUIManager
-e_ui_manager_new
-e_ui_manager_get_express_mode
-e_ui_manager_set_express_mode
-e_ui_manager_add_ui_from_file
-e_ui_manager_add_ui_from_string
-<SUBSECTION Standard>
-E_UI_MANAGER
-E_IS_UI_MANAGER
-E_TYPE_UI_MANAGER
-E_UI_MANAGER_CLASS
-E_IS_UI_MANAGER_CLASS
-E_UI_MANAGER_GET_CLASS
-EUIManagerClass
-e_ui_manager_get_type
-<SUBSECTION Private>
-EUIManagerPrivate
-</SECTION>
-
-<SECTION>
<FILE>e-url-entry</FILE>
<TITLE>EUrlEntry</TITLE>
EUrlEntry
diff --git a/doc/reference/libeutil/libeutil.types b/doc/reference/libeutil/libeutil.types
index f8bfae4b83..bd1ec8d1bf 100644
--- a/doc/reference/libeutil/libeutil.types
+++ b/doc/reference/libeutil/libeutil.types
@@ -158,7 +158,6 @@ e_tree_model_get_type
e_tree_selection_model_get_type
e_tree_sorted_get_type
e_tree_table_adapter_get_type
-e_ui_manager_get_type
e_url_entry_get_type
e_web_view_get_type
e_web_view_gtkhtml_get_type
diff --git a/e-util/Makefile.am b/e-util/Makefile.am
index 9fa1877396..5e974f20bc 100644
--- a/e-util/Makefile.am
+++ b/e-util/Makefile.am
@@ -294,7 +294,6 @@ eutilinclude_HEADERS = \
e-tree-sorted.h \
e-tree-table-adapter.h \
e-tree.h \
- e-ui-manager.h \
e-unicode.h \
e-url-entry.h \
e-util-enums.h \
@@ -539,7 +538,6 @@ libeutil_la_SOURCES = \
e-tree-sorted.c \
e-tree-table-adapter.c \
e-tree.c \
- e-ui-manager.c \
e-unicode.c \
e-url-entry.c \
e-util-enumtypes.c \
diff --git a/e-util/e-attachment-view.c b/e-util/e-attachment-view.c
index b1abda1e47..d078bd4b26 100644
--- a/e-util/e-attachment-view.c
+++ b/e-util/e-attachment-view.c
@@ -33,7 +33,6 @@
#include "e-attachment-handler-sendto.h"
#include "e-misc-utils.h"
#include "e-selection.h"
-#include "e-ui-manager.h"
enum {
UPDATE_ACTIONS,
@@ -882,7 +881,7 @@ e_attachment_view_init (EAttachmentView *view)
priv = e_attachment_view_get_private (view);
- ui_manager = e_ui_manager_new ();
+ ui_manager = gtk_ui_manager_new ();
priv->merge_id = gtk_ui_manager_new_merge_id (ui_manager);
priv->ui_manager = ui_manager;
diff --git a/e-util/e-plugin-ui.c b/e-util/e-plugin-ui.c
index 3ef863c2a3..a8d0368e3e 100644
--- a/e-util/e-plugin-ui.c
+++ b/e-util/e-plugin-ui.c
@@ -21,8 +21,6 @@
#include "e-plugin-ui.h"
-#include "e-ui-manager.h"
-
#include <string.h>
#define E_PLUGIN_UI_HOOK_GET_PRIVATE(obj) \
@@ -247,12 +245,8 @@ plugin_ui_hook_merge_ui (EPluginUIHook *hook,
ui_definition = g_hash_table_lookup (hash_table, id);
g_return_val_if_fail (ui_definition != NULL, 0);
- if (E_IS_UI_MANAGER (ui_manager))
- merge_id = e_ui_manager_add_ui_from_string (
- E_UI_MANAGER (ui_manager), ui_definition, &error);
- else
- merge_id = gtk_ui_manager_add_ui_from_string (
- ui_manager, ui_definition, -1, &error);
+ merge_id = gtk_ui_manager_add_ui_from_string (
+ ui_manager, ui_definition, -1, &error);
if (error != NULL) {
g_warning ("%s", error->message);
diff --git a/e-util/e-ui-manager.c b/e-util/e-ui-manager.c
deleted file mode 100644
index 4661cbc7cb..0000000000
--- a/e-util/e-ui-manager.c
+++ /dev/null
@@ -1,323 +0,0 @@
-/*
- * e-ui-manager.c
- *
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) version 3.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with the program; if not, see <http://www.gnu.org/licenses/>
- *
- */
-
-/**
- * SECTION: e-ui-manager
- * @short_description: construct menus and toolbars from a UI definition
- * @include: e-util/e-util.h
- *
- * This is a #GtkUIManager with support for Evolution's "express" mode,
- * which influences the parsing of UI definitions.
- **/
-
-#ifdef HAVE_CONFIG_H
-#include <config.h>
-#endif
-
-#include "e-ui-manager.h"
-#include "e-util-private.h"
-
-#include <string.h>
-
-#define E_UI_MANAGER_GET_PRIVATE(obj) \
- (G_TYPE_INSTANCE_GET_PRIVATE \
- ((obj), E_TYPE_UI_MANAGER, EUIManagerPrivate))
-
-/*
- * --- NOTE TO SELF ---
- *
- * While creating this class I was tempted to add an "id" property which
- * EPluginUI could extract from a given EUIManager instead of having the
- * public EPluginUI functions take a separate "id" argument. Seemed like
- * a nice cleanup until I remembered that an EUIManager instance can have
- * multiple IDs ("aliases"), as in the case of EShellWindow's UI manager.
- * So the UI Manager ID and the instance still need to be kept separate.
- *
- * Mentioning it here in case I forget why I didn't go through with it.
- */
-
-struct _EUIManagerPrivate {
- guint express_mode : 1;
-};
-
-enum {
- PROP_0,
- PROP_EXPRESS_MODE
-};
-
-G_DEFINE_TYPE (
- EUIManager,
- e_ui_manager,
- GTK_TYPE_UI_MANAGER)
-
-static void
-ui_manager_set_property (GObject *object,
- guint property_id,
- const GValue *value,
- GParamSpec *pspec)
-{
- switch (property_id) {
- case PROP_EXPRESS_MODE:
- e_ui_manager_set_express_mode (
- E_UI_MANAGER (object),
- g_value_get_boolean (value));
- return;
- }
-
- G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
-}
-
-static void
-ui_manager_get_property (GObject *object,
- guint property_id,
- GValue *value,
- GParamSpec *pspec)
-{
- switch (property_id) {
- case PROP_EXPRESS_MODE:
- g_value_set_boolean (
- value, e_ui_manager_get_express_mode (
- E_UI_MANAGER (object)));
- return;
- }
-
- G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
-}
-
-static gchar *
-ui_manager_filter_ui (EUIManager *ui_manager,
- const gchar *ui_definition)
-{
- gchar **lines;
- gchar *filtered;
- gboolean express_mode;
- gboolean include = TRUE;
- gint ii;
-
- express_mode = e_ui_manager_get_express_mode (ui_manager);
-
- /*
- * Very simple C style pre-processing in-line in the XML:
- * #if [!]EXPRESS\n ... \n#endif\n
- */
- lines = g_strsplit (ui_definition, "\n", -1);
-
- for (ii = 0; lines[ii] != NULL; ii++) {
- if (lines[ii][0] == '#') {
- if (!strncmp (lines[ii], "#if ", 4)) {
- gboolean not_express = lines[ii][4] == '!';
- include = express_mode ^ not_express;
- lines[ii][0] = '\0';
- } else if (!strncmp (lines[ii], "#endif", 6)) {
- lines[ii][0] = '\0';
- include = TRUE;
- }
- }
- if (!include)
- lines[ii][0] = '\0';
- }
-
- filtered = g_strjoinv ("\n", lines);
-
- g_strfreev (lines);
-
- return filtered;
-}
-
-static void
-e_ui_manager_class_init (EUIManagerClass *class)
-{
- GObjectClass *object_class;
-
- g_type_class_add_private (class, sizeof (EUIManagerPrivate));
-
- object_class = G_OBJECT_CLASS (class);
- object_class->set_property = ui_manager_set_property;
- object_class->get_property = ui_manager_get_property;
-
- class->filter_ui = ui_manager_filter_ui;
-
- g_object_class_install_property (
- object_class,
- PROP_EXPRESS_MODE,
- g_param_spec_boolean (
- "express-mode",
- "Express Mode",
- NULL,
- FALSE,
- G_PARAM_READWRITE |
- G_PARAM_CONSTRUCT));
-}
-
-static void
-e_ui_manager_init (EUIManager *ui_manager)
-{
- ui_manager->priv = E_UI_MANAGER_GET_PRIVATE (ui_manager);
-}
-
-/**
- * e_ui_manager_new:
- *
- * Returns a new #EUIManager instance.
- *
- * Returns: a new #EUIManager instance
- **/
-GtkUIManager *
-e_ui_manager_new (void)
-{
- return g_object_new (E_TYPE_UI_MANAGER, NULL);
-}
-
-/**
- * e_ui_manager_get_express_mode:
- * @ui_manager: an #EUIManager
- *
- * Returns the "express mode" flag in @ui_manager.
- *
- * Returns: %TRUE if @ui_manager is set to express mode
- **/
-gboolean
-e_ui_manager_get_express_mode (EUIManager *ui_manager)
-{
- g_return_val_if_fail (E_IS_UI_MANAGER (ui_manager), FALSE);
-
- return ui_manager->priv->express_mode;
-}
-
-/**
- * e_ui_manager_set_express_mode:
- * @ui_manager: an #EUIManager
- * @express_mode: express mode flag
- *
- * Sets the "express mode" flag in @ui_manager, which influences how
- * UI definitions are loaded.
- **/
-void
-e_ui_manager_set_express_mode (EUIManager *ui_manager,
- gboolean express_mode)
-{
- g_return_if_fail (E_IS_UI_MANAGER (ui_manager));
-
- if (ui_manager->priv->express_mode == express_mode)
- return;
-
- ui_manager->priv->express_mode = express_mode;
-
- g_object_notify (G_OBJECT (ui_manager), "express-mode");
-}
-
-/**
- * e_ui_manager_add_ui_from_file:
- * @ui_manager: an #EUIManager
- * @basename: basename of the UI definition file
- *
- * Loads a UI definition into @ui_manager from Evolution's UI directory.
- * If the EUIManager:express-mode property is %TRUE, a simplified version
- * of the UI may be presented.
- *
- * Failure here is fatal, since the application can't function without
- * its core UI definitions.
- *
- * Returns: The merge ID for the merged UI. The merge ID can be used to
- * unmerge the UI with gtk_ui_manager_remove_ui().
- **/
-guint
-e_ui_manager_add_ui_from_file (EUIManager *ui_manager,
- const gchar *basename)
-{
- EUIManagerClass *class;
- gchar *filename;
- gchar *contents;
- guint merge_id = 0;
- GError *error = NULL;
-
- g_return_val_if_fail (E_IS_UI_MANAGER (ui_manager), 0);
- g_return_val_if_fail (basename != NULL, 0);
-
- class = E_UI_MANAGER_GET_CLASS (ui_manager);
- g_return_val_if_fail (class->filter_ui != NULL, 0);
-
- filename = g_build_filename (EVOLUTION_UIDIR, basename, NULL);
-
- if (g_file_get_contents (filename, &contents, NULL, &error)) {
- gchar *filtered;
-
- /* We could call e_ui_manager_add_ui_from_string() here,
- * but if an error occurs we'd like to include the file
- * name in the error message. */
-
- filtered = class->filter_ui (ui_manager, contents);
-
- merge_id = gtk_ui_manager_add_ui_from_string (
- GTK_UI_MANAGER (ui_manager), filtered, -1, &error);
-
- g_free (filtered);
- g_free (contents);
- }
-
- g_free (filename);
-
- if (error != NULL) {
- g_error ("%s: %s", basename, error->message);
- g_assert_not_reached ();
- }
-
- return merge_id;
-}
-
-/**
- * e_ui_manager_add_ui_from_string:
- * @ui_manager: an #EUIManager
- * @ui_definition: the UI XML in NULL terminated string form
- * @error: return location for a #GError, or %NULL
- *
- * Loads the given UI definition into @ui_manager. If the
- * EUIManager:express-mode property is %TRUE, a simplified version of
- * the UI may be presented.
- *
- * Failure here is <emphasis>not</emphasis> fatal, since the function is
- * primarily used to load UI definitions for plugins, which we can get by
- * without.
- *
- * Returns: The merge ID for the merged UI. The merge ID can be used to
- * unmerge the UI with gtk_ui_manager_remove_ui().
- **/
-guint
-e_ui_manager_add_ui_from_string (EUIManager *ui_manager,
- const gchar *ui_definition,
- GError **error)
-{
- EUIManagerClass *class;
- gchar *filtered;
- guint merge_id;
-
- g_return_val_if_fail (E_IS_UI_MANAGER (ui_manager), 0);
- g_return_val_if_fail (ui_definition != NULL, 0);
-
- class = E_UI_MANAGER_GET_CLASS (ui_manager);
- g_return_val_if_fail (class->filter_ui != NULL, 0);
-
- filtered = class->filter_ui (ui_manager, ui_definition);
-
- merge_id = gtk_ui_manager_add_ui_from_string (
- GTK_UI_MANAGER (ui_manager), filtered, -1, error);
-
- g_free (filtered);
-
- return merge_id;
-}
diff --git a/e-util/e-ui-manager.h b/e-util/e-ui-manager.h
deleted file mode 100644
index 65948d1678..0000000000
--- a/e-util/e-ui-manager.h
+++ /dev/null
@@ -1,78 +0,0 @@
-/*
- * e-ui-manager.h
- *
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) version 3.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with the program; if not, see <http://www.gnu.org/licenses/>
- *
- */
-
-#if !defined (__E_UTIL_H_INSIDE__) && !defined (LIBEUTIL_COMPILATION)
-#error "Only <e-util/e-util.h> should be included directly."
-#endif
-
-#ifndef E_UI_MANAGER_H
-#define E_UI_MANAGER_H
-
-#include <gtk/gtk.h>
-
-/* Standard GObject macros */
-#define E_TYPE_UI_MANAGER \
- (e_ui_manager_get_type ())
-#define E_UI_MANAGER(obj) \
- (G_TYPE_CHECK_INSTANCE_CAST \
- ((obj), E_TYPE_UI_MANAGER, EUIManager))
-#define E_UI_MANAGER_CLASS(cls) \
- (G_TYPE_CHECK_CLASS_CAST \
- ((cls), E_TYPE_UI_MANAGER, EUIManagerClass))
-#define E_IS_UI_MANAGER(obj) \
- (G_TYPE_CHECK_INSTANCE_TYPE \
- ((obj), E_TYPE_UI_MANAGER))
-#define E_IS_UI_MANAGER_CLASS(cls) \
- (G_TYPE_CHECK_CLASS_TYPE \
- ((cls), E_TYPE_UI_MANAGER))
-#define E_UI_MANAGER_GET_CLASS(obj) \
- (G_TYPE_INSTANCE_GET_CLASS \
- ((obj), E_TYPE_UI_MANAGER, EUIManagerClass))
-
-G_BEGIN_DECLS
-
-typedef struct _EUIManager EUIManager;
-typedef struct _EUIManagerClass EUIManagerClass;
-typedef struct _EUIManagerPrivate EUIManagerPrivate;
-
-struct _EUIManager {
- GtkUIManager parent;
- EUIManagerPrivate *priv;
-};
-
-struct _EUIManagerClass {
- GtkUIManagerClass parent_class;
-
- gchar * (*filter_ui) (EUIManager *ui_manager,
- const gchar *ui_definition);
-};
-
-GType e_ui_manager_get_type (void) G_GNUC_CONST;
-GtkUIManager * e_ui_manager_new (void);
-gboolean e_ui_manager_get_express_mode (EUIManager *ui_manager);
-void e_ui_manager_set_express_mode (EUIManager *ui_manager,
- gboolean express_mode);
-guint e_ui_manager_add_ui_from_file (EUIManager *ui_manager,
- const gchar *basename);
-guint e_ui_manager_add_ui_from_string (EUIManager *ui_manager,
- const gchar *ui_definition,
- GError **error);
-
-G_END_DECLS
-
-#endif /* E_UI_MANAGER_H */
diff --git a/e-util/e-util.h b/e-util/e-util.h
index 17c4e60d14..d60a6f0f62 100644
--- a/e-util/e-util.h
+++ b/e-util/e-util.h
@@ -215,7 +215,6 @@
#include <e-util/e-tree-sorted.h>
#include <e-util/e-tree-table-adapter.h>
#include <e-util/e-tree.h>
-#include <e-util/e-ui-manager.h>
#include <e-util/e-unicode.h>
#include <e-util/e-url-entry.h>
#include <e-util/e-util-enums.h>
diff --git a/mail/e-mail-browser.c b/mail/e-mail-browser.c
index 8556fb2d3e..19b74fc311 100644
--- a/mail/e-mail-browser.c
+++ b/mail/e-mail-browser.c
@@ -553,7 +553,7 @@ mail_browser_constructed (GObject *object)
shell_backend = E_SHELL_BACKEND (backend);
shell = e_shell_backend_get_shell (shell_backend);
- ui_manager = e_ui_manager_new ();
+ ui_manager = gtk_ui_manager_new ();
browser->priv->ui_manager = ui_manager;
domain = GETTEXT_PACKAGE;
@@ -618,12 +618,10 @@ mail_browser_constructed (GObject *object)
e_mail_reader_init (reader, TRUE, TRUE);
- e_ui_manager_add_ui_from_file (
- E_UI_MANAGER (ui_manager), E_MAIL_READER_UI_DEFINITION);
- e_ui_manager_add_ui_from_string (
- E_UI_MANAGER (ui_manager), ui, NULL);
+ e_load_ui_manager_definition (ui_manager, E_MAIL_READER_UI_DEFINITION);
+ gtk_ui_manager_add_ui_from_string (ui_manager, ui, -1, NULL);
- merge_id = gtk_ui_manager_new_merge_id (GTK_UI_MANAGER (ui_manager));
+ merge_id = gtk_ui_manager_new_merge_id (ui_manager);
e_mail_reader_create_charset_menu (reader, ui_manager, merge_id);
accel_group = gtk_ui_manager_get_accel_group (ui_manager);
diff --git a/modules/mail/e-mail-shell-view.c b/modules/mail/e-mail-shell-view.c
index f739ca6660..285bb5db1f 100644
--- a/modules/mail/e-mail-shell-view.c
+++ b/modules/mail/e-mail-shell-view.c
@@ -253,8 +253,8 @@ mail_shell_view_toggled (EShellView *shell_view)
if (view_is_active && priv->merge_id == 0) {
EMailView *mail_view;
- priv->merge_id = e_ui_manager_add_ui_from_file (
- E_UI_MANAGER (ui_manager), basename);
+ priv->merge_id = e_load_ui_manager_definition (
+ ui_manager, basename);
mail_view = e_mail_shell_content_get_mail_view (
priv->mail_shell_content);
e_mail_reader_create_charset_menu (
diff --git a/shell/e-shell-view.c b/shell/e-shell-view.c
index 77597d0595..2d876ff80c 100644
--- a/shell/e-shell-view.c
+++ b/shell/e-shell-view.c
@@ -719,8 +719,8 @@ shell_view_toggled (EShellView *shell_view)
id = shell_view_class->ui_manager_id;
if (view_is_active && priv->merge_id == 0) {
- priv->merge_id = e_ui_manager_add_ui_from_file (
- E_UI_MANAGER (ui_manager), basename);
+ priv->merge_id = e_load_ui_manager_definition (
+ ui_manager, basename);
e_plugin_ui_enable_manager (ui_manager, id);
} else if (!view_is_active && priv->merge_id != 0) {
e_plugin_ui_disable_manager (ui_manager, id);
diff --git a/shell/e-shell-window-actions.c b/shell/e-shell-window-actions.c
index 2b70a5eea2..0863c1bdcd 100644
--- a/shell/e-shell-window-actions.c
+++ b/shell/e-shell-window-actions.c
@@ -1283,8 +1283,8 @@ e_shell_window_actions_init (EShellWindow *shell_window)
g_return_if_fail (E_IS_SHELL_WINDOW (shell_window));
ui_manager = e_shell_window_get_ui_manager (shell_window);
- e_ui_manager_add_ui_from_file (
- E_UI_MANAGER (ui_manager), "evolution-shell.ui");
+
+ e_load_ui_manager_definition (ui_manager, "evolution-shell.ui");
/* Shell Actions */
action_group = ACTION_GROUP (SHELL);
diff --git a/shell/e-shell-window-private.c b/shell/e-shell-window-private.c
index 69e3ff24ad..b3070a6bcf 100644
--- a/shell/e-shell-window-private.c
+++ b/shell/e-shell-window-private.c
@@ -220,7 +220,7 @@ e_shell_window_private_init (EShellWindow *shell_window)
signal_handler_ids = g_array_new (FALSE, FALSE, sizeof (gulong));
- priv->ui_manager = e_ui_manager_new ();
+ priv->ui_manager = gtk_ui_manager_new ();
priv->loaded_views = loaded_views;
priv->signal_handler_ids = signal_handler_ids;