[gnome-commander/gcmd-1-3] test plugin: migration to C++



commit 661270df819e87ab9c9ad7005b9dbb3bc8d3d71b
Author: Piotr Eljasiak <epiotr src gnome org>
Date:   Tue Dec 8 00:37:11 2009 +0100

    test plugin: migration to C++

 plugins/test/Makefile.am                       |    2 +-
 plugins/test/{test-plugin.c => test-plugin.cc} |    4 ++--
 2 files changed, 3 insertions(+), 3 deletions(-)
---
diff --git a/plugins/test/Makefile.am b/plugins/test/Makefile.am
index 69a372a..4df9783 100644
--- a/plugins/test/Makefile.am
+++ b/plugins/test/Makefile.am
@@ -11,7 +11,7 @@ plugindir = $(pkglibdir)/plugins
 noinst_LTLIBRARIES = libtest.la
 
 libtest_la_SOURCES = \
-	test-plugin.h test-plugin.c \
+	test-plugin.h test-plugin.cc \
 	test-plugin.xpm
 
 libtest_la_LDFLAGS = $(GNOMEUI_LIBS) $(GNOMEVFS_LIBS)
diff --git a/plugins/test/test-plugin.c b/plugins/test/test-plugin.cc
similarity index 97%
rename from plugins/test/test-plugin.c
rename to plugins/test/test-plugin.cc
index b3e4afb..ba1248d 100644
--- a/plugins/test/test-plugin.c
+++ b/plugins/test/test-plugin.cc
@@ -153,7 +153,7 @@ static void class_init (TestPluginClass *klass)
 
     object_class = GTK_OBJECT_CLASS (klass);
     plugin_class = GNOME_CMD_PLUGIN_CLASS (klass);
-    parent_class = gtk_type_class (gnome_cmd_plugin_get_type ());
+    parent_class = (GnomeCmdPluginClass *) gtk_type_class (gnome_cmd_plugin_get_type ());
 
     object_class->destroy = destroy;
 
@@ -201,7 +201,7 @@ GtkType test_plugin_get_type ()
 
 GnomeCmdPlugin *test_plugin_new ()
 {
-    TestPlugin *plugin = gtk_type_new (test_plugin_get_type ());
+    TestPlugin *plugin = (TestPlugin *) gtk_type_new (test_plugin_get_type ());
 
     return GNOME_CMD_PLUGIN (plugin);
 }



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]