[gnac/devel] Better separation between gnac-main and gnac-ui
- From: Benoît Dupasquier <bdupasqu src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnac/devel] Better separation between gnac-main and gnac-ui
- Date: Mon, 8 Nov 2010 09:00:49 +0000 (UTC)
commit 8b5c886f9dcf3b0cb25381ccc2e3df146e7042d9
Author: Benoît Dupasquier <bdupasqu src gnome org>
Date: Mon Nov 8 09:00:42 2010 +0000
Better separation between gnac-main and gnac-ui
data/ui/gnac.xml | 2 +-
src/gnac-main.c | 15 ---------------
src/gnac-main.h | 4 ----
src/gnac-ui.c | 14 ++++++++++++++
src/gnac-ui.h | 4 ++++
5 files changed, 19 insertions(+), 20 deletions(-)
---
diff --git a/data/ui/gnac.xml b/data/ui/gnac.xml
index a6bacc5..0a3eb05 100644
--- a/data/ui/gnac.xml
+++ b/data/ui/gnac.xml
@@ -70,7 +70,7 @@
<property name="stock_id">gtk-clear</property>
<property name="name">clear_item</property>
<property name="sensitive">False</property>
- <signal handler="gnac_on_ui_clear_cb" name="activate"/>
+ <signal handler="gnac_ui_on_clear_cb" name="activate"/>
</object>
<accelerator key="C" modifiers="GDK_CONTROL_MASK | GDK_SHIFT_MASK"/>
</child>
diff --git a/src/gnac-main.c b/src/gnac-main.c
index a796fd7..6554487 100644
--- a/src/gnac-main.c
+++ b/src/gnac-main.c
@@ -758,21 +758,6 @@ gnac_on_ui_convert_cb(GtkWidget *widget,
}
-void
-gnac_on_ui_clear_cb(GtkAction *action,
- gpointer data)
-{
- GError *error = NULL;
-
- libgnac_converter_clear(converter);
- if (error)
- {
- g_printerr("%s: %s\n", _("Error"), error->message);
- g_clear_error(&error);
- }
-}
-
-
/*static void
gnac_on_file_monitor_changed_cb(GFileMonitor *monitor,
GFile *file,
diff --git a/src/gnac-main.h b/src/gnac-main.h
index b32bff0..477ee69 100644
--- a/src/gnac-main.h
+++ b/src/gnac-main.h
@@ -61,10 +61,6 @@ void
gnac_on_ui_pause_cb(GtkWidget *widget,
gpointer data);
-void
-gnac_on_ui_clear_cb(GtkAction *action,
- gpointer data);
-
G_GNUC_NORETURN void
gnac_exit(gint status);
diff --git a/src/gnac-ui.c b/src/gnac-ui.c
index a58754a..62a0055 100644
--- a/src/gnac-ui.c
+++ b/src/gnac-ui.c
@@ -931,6 +931,20 @@ gnac_ui_on_focus_in_event_cb(GtkWidget *widget,
void
+gnac_ui_on_clear_cb(GtkAction *action,
+ gpointer data)
+{
+ GError *error = NULL;
+
+ libgnac_converter_clear(converter);
+ if (error) {
+ g_printerr("%s: %s\n", _("Error"), error->message);
+ g_clear_error(&error);
+ }
+}
+
+
+void
gnac_ui_on_view_toolbar_cb(GtkAction *action,
gpointer user_data)
{
diff --git a/src/gnac-ui.h b/src/gnac-ui.h
index 20cd102..f991e9a 100644
--- a/src/gnac-ui.h
+++ b/src/gnac-ui.h
@@ -127,6 +127,10 @@ gnac_ui_on_focus_in_event_cb(GtkWidget *widget,
gpointer data);
void
+gnac_ui_on_clear_cb(GtkAction *action,
+ gpointer data);
+
+void
gnac_ui_on_view_toolbar_cb(GtkAction *action,
gpointer user_data);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]