aboutsummaryrefslogtreecommitdiff
path: root/src/main.cc
diff options
context:
space:
mode:
authorfluxgen <fluxgen>2002-04-04 11:28:19 (GMT)
committerfluxgen <fluxgen>2002-04-04 11:28:19 (GMT)
commit2526e4bce821eedcd4bcc13e0f27ac7b9e255350 (patch)
treef86898efe146ecb882e597955e1e94b375154b19 /src/main.cc
parentbd05695cfa6d066e5e5368d857eef8c0b11987c1 (diff)
downloadfluxbox-2526e4bce821eedcd4bcc13e0f27ac7b9e255350.zip
fluxbox-2526e4bce821eedcd4bcc13e0f27ac7b9e255350.tar.bz2
moved nls defines to enums in namespace FBNLS
Diffstat (limited to 'src/main.cc')
-rw-r--r--src/main.cc23
1 files changed, 9 insertions, 14 deletions
diff --git a/src/main.cc b/src/main.cc
index ba2ef26..0ab2b24 100644
--- a/src/main.cc
+++ b/src/main.cc
@@ -22,10 +22,9 @@
22// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER 22// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
23// DEALINGS IN THE SOFTWARE. 23// DEALINGS IN THE SOFTWARE.
24 24
25// $Id: main.cc,v 1.5 2002/03/08 12:21:46 fluxgen Exp $ 25// $Id: main.cc,v 1.6 2002/04/04 11:28:19 fluxgen Exp $
26 26
27// stupid macros needed to access some functions in version 2 of the GNU C 27//use GNU extensions
28// library
29#ifndef _GNU_SOURCE 28#ifndef _GNU_SOURCE
30#define _GNU_SOURCE 29#define _GNU_SOURCE
31#endif // _GNU_SOURCE 30#endif // _GNU_SOURCE
@@ -75,12 +74,12 @@ uds::uds_flags_t uds::flags = uds::leak_check;
75const char *getNLSYesNoMsg(bool val) { 74const char *getNLSYesNoMsg(bool val) {
76 if (val) { 75 if (val) {
77 return I18n::instance()->getMessage( 76 return I18n::instance()->getMessage(
78 CommonSet, CommonYes, 77 FBNLS::CommonSet, FBNLS::CommonYes,
79 "yes"); 78 "yes");
80 } 79 }
81 80
82 return I18n::instance()->getMessage( 81 return I18n::instance()->getMessage(
83 CommonSet, CommonNo, 82 FBNLS::CommonSet, FBNLS::CommonNo,
84 "no"); 83 "no");
85} 84}
86 85
@@ -103,7 +102,7 @@ int main(int argc, char **argv) {
103 if ((++i) >= argc) { 102 if ((++i) >= argc) {
104 fprintf(stderr, 103 fprintf(stderr,
105 i18n->getMessage( 104 i18n->getMessage(
106 mainSet, mainRCRequiresArg, 105 FBNLS::mainSet, FBNLS::mainRCRequiresArg,
107 "error: '-rc' requires and argument\n")); 106 "error: '-rc' requires and argument\n"));
108 exit(1); 107 exit(1);
109 } 108 }
@@ -116,7 +115,7 @@ int main(int argc, char **argv) {
116 if ((++i) >= argc) { 115 if ((++i) >= argc) {
117 fprintf(stderr, 116 fprintf(stderr,
118 i18n->getMessage( 117 i18n->getMessage(
119 mainSet, mainDISPLAYRequiresArg, 118 FBNLS::mainSet, FBNLS::mainDISPLAYRequiresArg,
120 "error: '-display' requires an argument\n")); 119 "error: '-display' requires an argument\n"));
121 exit(1); 120 exit(1);
122 } 121 }
@@ -129,7 +128,7 @@ int main(int argc, char **argv) {
129 fprintf(stderr, 128 fprintf(stderr,
130 i18n-> 129 i18n->
131 getMessage( 130 getMessage(
132 mainSet, mainWarnDisplaySet, 131 FBNLS::mainSet, FBNLS::mainWarnDisplaySet,
133 "warning: couldn't set environment variable 'DISPLAY'\n")); 132 "warning: couldn't set environment variable 'DISPLAY'\n"));
134 perror("putenv()"); 133 perror("putenv()");
135 } 134 }
@@ -143,7 +142,7 @@ int main(int argc, char **argv) {
143 // print program usage and command line options 142 // print program usage and command line options
144 printf(i18n-> 143 printf(i18n->
145 getMessage( 144 getMessage(
146 mainSet, mainUsage, 145 FBNLS::mainSet, FBNLS::mainUsage,
147 "Fluxbox %s : (c) 2001-2002 Henrik Kinnunen\n\n" 146 "Fluxbox %s : (c) 2001-2002 Henrik Kinnunen\n\n"
148 " -display <string>\t\tuse display connection.\n" 147 " -display <string>\t\tuse display connection.\n"
149 " -rc <string>\t\t\tuse alternate resource file.\n" 148 " -rc <string>\t\t\tuse alternate resource file.\n"
@@ -155,11 +154,7 @@ int main(int argc, char **argv) {
155 // as well 154 // as well
156 printf(i18n-> 155 printf(i18n->
157 getMessage( 156 getMessage(
158 #ifdef NLS 157 FBNLS::mainSet, FBNLS::mainCompileOptions,
159 mainSet, mainCompileOptions,
160 #else // !NLS
161 0, 0,
162 #endif // NLS
163 "Compile time options:\n" 158 "Compile time options:\n"
164 " Debugging:\t\t\t%s\n" 159 " Debugging:\t\t\t%s\n"
165 " Interlacing:\t\t\t%s\n" 160 " Interlacing:\t\t\t%s\n"