aboutsummaryrefslogtreecommitdiffstats
path: root/shell/test
diff options
context:
space:
mode:
authorMatthew Barnes <mbarnes@src.gnome.org>2008-08-27 04:22:32 +0800
committerMatthew Barnes <mbarnes@src.gnome.org>2008-08-27 04:22:32 +0800
commitcf3b01017162cbba568ee4317eee2efe5f6fdc10 (patch)
tree448dc3adee36e401a6aea2ebc1c27a586b14a644 /shell/test
parent2ef1b5bf42b5d429e00f94710458f237d18315b2 (diff)
downloadgsoc2013-evolution-cf3b01017162cbba568ee4317eee2efe5f6fdc10.tar
gsoc2013-evolution-cf3b01017162cbba568ee4317eee2efe5f6fdc10.tar.gz
gsoc2013-evolution-cf3b01017162cbba568ee4317eee2efe5f6fdc10.tar.bz2
gsoc2013-evolution-cf3b01017162cbba568ee4317eee2efe5f6fdc10.tar.lz
gsoc2013-evolution-cf3b01017162cbba568ee4317eee2efe5f6fdc10.tar.xz
gsoc2013-evolution-cf3b01017162cbba568ee4317eee2efe5f6fdc10.tar.zst
gsoc2013-evolution-cf3b01017162cbba568ee4317eee2efe5f6fdc10.zip
Progress update:
- Further refinements of the shell API. - Kill ESMenu and EUserCreatableItemsHandler. - Start ripping apart the addressbook component. svn path=/branches/kill-bonobo/; revision=36093
Diffstat (limited to 'shell/test')
-rw-r--r--shell/test/e-test-shell-module.c35
-rw-r--r--shell/test/e-test-shell-view.c18
-rw-r--r--shell/test/e-test-shell-view.h2
3 files changed, 29 insertions, 26 deletions
diff --git a/shell/test/e-test-shell-module.c b/shell/test/e-test-shell-module.c
index f7deaaca67..2aec01a444 100644
--- a/shell/test/e-test-shell-module.c
+++ b/shell/test/e-test-shell-module.c
@@ -1,5 +1,5 @@
/* -*- Mode: C; indent-tabs-mode: t; c-basic-offset: 8; tab-width: 8 -*- */
-/* e-test-module.c
+/* e-test-shell-module.c
*
* Copyright (C) 1999-2008 Novell, Inc. (www.novell.com)
*
@@ -32,17 +32,17 @@
#define MODULE_SORT_ORDER 100
/* Module Entry Point */
-void e_shell_module_init (GTypeModule *module);
+void e_shell_module_init (GTypeModule *type_module);
static void
-action_new_test_item_cb (GtkAction *action,
+action_test_item_new_cb (GtkAction *action,
EShellWindow *shell_window)
{
g_debug ("%s", G_STRFUNC);
}
static void
-action_new_test_source_cb (GtkAction *action,
+action_test_source_new_cb (GtkAction *action,
EShellWindow *shell_window)
{
g_debug ("%s", G_STRFUNC);
@@ -50,22 +50,22 @@ action_new_test_source_cb (GtkAction *action,
static GtkActionEntry item_entries[] = {
- { "new-test-item",
+ { "test-item-new",
"document-new",
N_("_Test Item"),
NULL,
N_("Create a new test item"),
- G_CALLBACK (action_new_test_item_cb) }
+ G_CALLBACK (action_test_item_new_cb) }
};
static GtkActionEntry source_entries[] = {
- { "new-test-source",
+ { "test-source-new",
"folder-new",
N_("Test _Source"),
NULL,
N_("Create a new test source"),
- G_CALLBACK (action_new_test_source_cb) }
+ G_CALLBACK (action_test_source_new_cb) }
};
static gboolean
@@ -139,27 +139,30 @@ static EShellModuleInfo module_info = {
};
void
-e_shell_module_init (GTypeModule *module)
+e_shell_module_init (GTypeModule *type_module)
{
EShell *shell;
+ EShellModule *shell_module;
- e_test_shell_view_get_type (module);
- shell = e_shell_module_get_shell (E_SHELL_MODULE (module));
- e_shell_module_set_info (E_SHELL_MODULE (module), &module_info);
+ shell_module = E_SHELL_MODULE (type_module);
+ shell = e_shell_module_get_shell (shell_module);
+
+ e_test_shell_view_get_type (type_module);
+ e_shell_module_set_info (shell_module, &module_info);
g_signal_connect_swapped (
shell, "handle-uri",
- G_CALLBACK (test_module_handle_uri), module);
+ G_CALLBACK (test_module_handle_uri), shell_module);
g_signal_connect_swapped (
shell, "send-receive",
- G_CALLBACK (test_module_send_receive), module);
+ G_CALLBACK (test_module_send_receive), shell_module);
g_signal_connect_swapped (
shell, "window-created",
- G_CALLBACK (test_module_window_created), module);
+ G_CALLBACK (test_module_window_created), shell_module);
g_signal_connect_swapped (
shell, "window-destroyed",
- G_CALLBACK (test_module_window_destroyed), module);
+ G_CALLBACK (test_module_window_destroyed), shell_module);
}
diff --git a/shell/test/e-test-shell-view.c b/shell/test/e-test-shell-view.c
index c76d459160..adba6ae3b8 100644
--- a/shell/test/e-test-shell-view.c
+++ b/shell/test/e-test-shell-view.c
@@ -35,7 +35,7 @@ static gpointer parent_class;
static void
test_shell_view_class_init (ETestShellViewClass *class,
- GTypeModule *module)
+ GTypeModule *type_module)
{
EShellViewClass *shell_view_class;
@@ -45,17 +45,17 @@ test_shell_view_class_init (ETestShellViewClass *class,
shell_view_class = E_SHELL_VIEW_CLASS (class);
shell_view_class->label = N_("Test");
shell_view_class->icon_name = "face-monkey";
- shell_view_class->module = module;
+ shell_view_class->type_module = type_module;
}
static void
-test_shell_view_init (ETestShellView *test_view)
+test_shell_view_init (ETestShellView *view)
{
- test_view->priv = E_TEST_SHELL_VIEW_GET_PRIVATE (test_view);
+ view->priv = E_TEST_SHELL_VIEW_GET_PRIVATE (view);
}
GType
-e_test_shell_view_get_type (GTypeModule *module)
+e_test_shell_view_get_type (GTypeModule *type_module)
{
if (e_test_shell_view_type == 0) {
const GTypeInfo type_info = {
@@ -64,16 +64,16 @@ e_test_shell_view_get_type (GTypeModule *module)
(GBaseFinalizeFunc) NULL,
(GClassInitFunc) test_shell_view_class_init,
(GClassFinalizeFunc) NULL,
- module, /* class_data */
+ type_module,
sizeof (ETestShellView),
- 0, /* n_preallocs */
+ 0, /* n_preallocs */
(GInstanceInitFunc) test_shell_view_init,
- NULL /* value_table */
+ NULL /* value_table */
};
e_test_shell_view_type =
g_type_module_register_type (
- module, E_TYPE_SHELL_VIEW,
+ type_module, E_TYPE_SHELL_VIEW,
"ETestShellView", &type_info, 0);
}
diff --git a/shell/test/e-test-shell-view.h b/shell/test/e-test-shell-view.h
index 036ebc3877..d349f63f0b 100644
--- a/shell/test/e-test-shell-view.h
+++ b/shell/test/e-test-shell-view.h
@@ -59,7 +59,7 @@ struct _ETestShellViewClass {
EShellViewClass parent_class;
};
-GType e_test_shell_view_get_type (GTypeModule *module);
+GType e_test_shell_view_get_type (GTypeModule *type_module);
G_END_DECLS