[anjuta] project-wizard: Don't replace hyphen with underscore in filenames



commit 01ffb959963eb2d45efbacc61e5db2a8bd7068a0
Author: Arnel A. Borja <kyoushuu yahoo com>
Date:   Sat Dec 24 15:54:28 2011 +0100

    project-wizard: Don't replace hyphen with underscore in filenames

 .../project-wizard/templates/anjuta-plugin.wiz.in  |    1 +
 .../templates/anjuta-plugin/src/plugin.c           |    2 +-
 .../templates/library/src/Makefile.am.tpl          |    2 +-
 plugins/project-wizard/templates/library/src/lib.c |    2 +-
 plugins/project-wizard/templates/library/src/lib.h |    2 +-
 5 files changed, 5 insertions(+), 4 deletions(-)
---
diff --git a/plugins/project-wizard/templates/anjuta-plugin.wiz.in b/plugins/project-wizard/templates/anjuta-plugin.wiz.in
index 8505e6c..6db6fe1 100644
--- a/plugins/project-wizard/templates/anjuta-plugin.wiz.in
+++ b/plugins/project-wizard/templates/anjuta-plugin.wiz.in
@@ -31,6 +31,7 @@
 		<property type="hidden" name="NameCUpper" default='[+(string->c-name! (string-substitute (string-upcase (get "Name")) " " "_"))+]'/>
 		<property type="hidden" name="NameCLower" default='[+(string->c-name! (string-substitute (string-downcase (get "Name")) " " "_"))+]'/>
 		<property type="hidden" name="NameHLower" default='[+(string-substitute (string->c-name! (string-downcase (get "Name"))) " " "-")+]'/>
+		<property type="hidden" name="NameCClass" default='[+(string-capitalize! (string-substitute (get "Name") "-" ""))+]'/>
 		<property type="string" name="PluginTitle" _label="Plugin Title:" _description="Display title of the plugin" default="Anjuta Foobar Sample Plugin" summary="yes" mandatory="yes"/>
 		<property type="string" name="PluginDescription" _label="Plugin Description:" _description="Display description of the plugin" default="A sample demonstration plugin for Anjuta" summary="yes" mandatory="yes"/>
 		<property type="string" name="PluginClass" _label="Plugin Class Name:" _description="Plugin class name" default="AnjutaFoobarPlugin" summary="yes" mandatory="yes"/>
diff --git a/plugins/project-wizard/templates/anjuta-plugin/src/plugin.c b/plugins/project-wizard/templates/anjuta-plugin/src/plugin.c
index 66c0cf6..932584e 100644
--- a/plugins/project-wizard/templates/anjuta-plugin/src/plugin.c
+++ b/plugins/project-wizard/templates/anjuta-plugin/src/plugin.c
@@ -80,7 +80,7 @@ static gboolean
 	ui = anjuta_shell_get_ui (plugin->shell, NULL);
 	
 	[+NameCLower+]->action_group = 
-		anjuta_ui_add_action_group_entries (ui, "ActionGroupFile[+NameHLower+]",
+		anjuta_ui_add_action_group_entries (ui, "ActionGroup[+NameCClass+]",
 											_("Sample file operations"),
 											actions_file,
 											G_N_ELEMENTS (actions_file),
diff --git a/plugins/project-wizard/templates/library/src/Makefile.am.tpl b/plugins/project-wizard/templates/library/src/Makefile.am.tpl
index 87c1b52..53122e6 100644
--- a/plugins/project-wizard/templates/library/src/Makefile.am.tpl
+++ b/plugins/project-wizard/templates/library/src/Makefile.am.tpl
@@ -16,7 +16,7 @@ AM_CFLAGS =\
 lib_LTLIBRARIES = lib[+NameHLower+].la
 
 
-lib[+NameHLower+]_la_SOURCES = \
+lib[+NameCLower+]_la_SOURCES = \
 	lib.c
 
 lib[+NameCLower+]_la_LDFLAGS = 
diff --git a/plugins/project-wizard/templates/library/src/lib.c b/plugins/project-wizard/templates/library/src/lib.c
index 910f8c2..7f0c8e4 100644
--- a/plugins/project-wizard/templates/library/src/lib.c
+++ b/plugins/project-wizard/templates/library/src/lib.c
@@ -12,7 +12,7 @@
 
 #include <stdio.h>
 
-int [+NameHLower+]_func(void)
+int [+NameCLower+]_func(void)
 {
 	printf("Hello world\n");
 	return (0);
diff --git a/plugins/project-wizard/templates/library/src/lib.h b/plugins/project-wizard/templates/library/src/lib.h
index 9eea75e..ac1c1b4 100644
--- a/plugins/project-wizard/templates/library/src/lib.h
+++ b/plugins/project-wizard/templates/library/src/lib.h
@@ -10,4 +10,4 @@
 [+ == "GPL"  +][+(gpl  (get "Name")                " * ")+]
 [+ESAC+] */
 
-int [+NameHLower+]_func (void);
+int [+NameCLower+]_func (void);



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