basicly cosmetic changes, patch by slava semushin
This commit is contained in:
parent
20a339fc06
commit
6ac57655d9
13 changed files with 34 additions and 63 deletions
|
@ -1,5 +1,10 @@
|
||||||
(Format: Year/Month/Day)
|
(Format: Year/Month/Day)
|
||||||
Changes for 1.0.0:
|
Changes for 1.0.0:
|
||||||
|
*07/04/17:
|
||||||
|
* cosmetic changes (Mathias, thanks Slava Semushin)
|
||||||
|
configure.in Screen.cc Keys.cc main.cc FbTk/MenuItem.hh FbTk/Timer.hh
|
||||||
|
FbTk/XLayerItem.hh FbTk/ImageControl.cc FbTk/I18n.hh FbTk/FbWindow.hh
|
||||||
|
FbTk/XLayer.hh fluxbox.cc
|
||||||
*07/04/11:
|
*07/04/11:
|
||||||
* updated asciidoc-docs, (Mathias, thanks Christian Loosli for fluxbox.de.txt)
|
* updated asciidoc-docs, (Mathias, thanks Christian Loosli for fluxbox.de.txt)
|
||||||
*07/04/08:
|
*07/04/08:
|
||||||
|
|
|
@ -16,7 +16,7 @@ dnl Locate required external software
|
||||||
AC_PROG_CC
|
AC_PROG_CC
|
||||||
AC_PROG_CXX
|
AC_PROG_CXX
|
||||||
AC_PROG_INSTALL
|
AC_PROG_INSTALL
|
||||||
AM_PROG_LIBTOOL
|
AC_PROG_RANLIB
|
||||||
|
|
||||||
AC_CHECK_PROGS(regex_cmd, sed)
|
AC_CHECK_PROGS(regex_cmd, sed)
|
||||||
if test x$regex_cmd = "x"; then
|
if test x$regex_cmd = "x"; then
|
||||||
|
|
|
@ -26,7 +26,6 @@
|
||||||
|
|
||||||
#include "FbDrawable.hh"
|
#include "FbDrawable.hh"
|
||||||
|
|
||||||
#include <X11/Xlib.h>
|
|
||||||
#include <memory>
|
#include <memory>
|
||||||
#include <string>
|
#include <string>
|
||||||
#include <set>
|
#include <set>
|
||||||
|
|
|
@ -60,8 +60,6 @@ void catclose(nl_catd cat);
|
||||||
|
|
||||||
#endif // HAVE_NL_TYPES_H
|
#endif // HAVE_NL_TYPES_H
|
||||||
|
|
||||||
#include <string>
|
|
||||||
|
|
||||||
// Some defines to help out
|
// Some defines to help out
|
||||||
#ifdef NLS
|
#ifdef NLS
|
||||||
#define _FB_USES_NLS \
|
#define _FB_USES_NLS \
|
||||||
|
|
|
@ -61,10 +61,6 @@
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef HAVE_CTYPE_H
|
|
||||||
#include <ctype.h>
|
|
||||||
#endif // HAVE_CTYPE_H
|
|
||||||
|
|
||||||
#include <iostream>
|
#include <iostream>
|
||||||
|
|
||||||
using std::cerr;
|
using std::cerr;
|
||||||
|
|
|
@ -30,7 +30,6 @@
|
||||||
#include "ITypeAheadable.hh"
|
#include "ITypeAheadable.hh"
|
||||||
#include "FbString.hh"
|
#include "FbString.hh"
|
||||||
|
|
||||||
#include <string>
|
|
||||||
#include <memory>
|
#include <memory>
|
||||||
|
|
||||||
namespace FbTk {
|
namespace FbTk {
|
||||||
|
|
|
@ -105,7 +105,6 @@ private:
|
||||||
|
|
||||||
timeval m_start; ///< start time
|
timeval m_start; ///< start time
|
||||||
timeval m_timeout; ///< time length
|
timeval m_timeout; ///< time length
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
} // end namespace FbTk
|
} // end namespace FbTk
|
||||||
|
|
|
@ -30,9 +30,6 @@
|
||||||
#include "NotCopyable.hh"
|
#include "NotCopyable.hh"
|
||||||
#include "FbWindow.hh"
|
#include "FbWindow.hh"
|
||||||
|
|
||||||
#include <X11/Xlib.h>
|
|
||||||
|
|
||||||
|
|
||||||
namespace FbTk {
|
namespace FbTk {
|
||||||
|
|
||||||
class XLayerItem : public LayerItem, private NotCopyable {
|
class XLayerItem : public LayerItem, private NotCopyable {
|
||||||
|
|
|
@ -39,9 +39,11 @@
|
||||||
#endif // HAVE_CONFIG_H
|
#endif // HAVE_CONFIG_H
|
||||||
|
|
||||||
|
|
||||||
#ifdef HAVE_CTYPE_H
|
#ifdef HAVE_CCTYPE
|
||||||
|
#include <cctype>
|
||||||
|
#else
|
||||||
#include <ctype.h>
|
#include <ctype.h>
|
||||||
#endif // HAVE_CTYPE_H
|
#endif // HAVE_CCTYPE
|
||||||
|
|
||||||
#ifdef HAVE_CSTDIO
|
#ifdef HAVE_CSTDIO
|
||||||
#include <cstdio>
|
#include <cstdio>
|
||||||
|
|
|
@ -101,10 +101,6 @@ class Slit {};
|
||||||
#include <sys/types.h>
|
#include <sys/types.h>
|
||||||
#endif // STDC_HEADERS
|
#endif // STDC_HEADERS
|
||||||
|
|
||||||
#ifdef HAVE_CTYPE_H
|
|
||||||
#include <ctype.h>
|
|
||||||
#endif // HAVE_CTYPE_H
|
|
||||||
|
|
||||||
#ifdef HAVE_UNISTD_H
|
#ifdef HAVE_UNISTD_H
|
||||||
#include <sys/types.h>
|
#include <sys/types.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
|
|
@ -134,21 +134,9 @@ class Toolbar { };
|
||||||
#include <sys/stat.h>
|
#include <sys/stat.h>
|
||||||
#endif // HAVE_SYS_STAT_H
|
#endif // HAVE_SYS_STAT_H
|
||||||
|
|
||||||
#ifdef TIME_WITH_SYS_TIME
|
|
||||||
#include <sys/time.h>
|
|
||||||
#include <time.h>
|
|
||||||
#else // !TIME_WITH_SYS_TIME
|
|
||||||
#ifdef HAVE_SYS_TIME_H
|
|
||||||
#include <sys/time.h>
|
|
||||||
#else // !HAVE_SYS_TIME_H
|
|
||||||
#include <time.h>
|
|
||||||
#endif // HAVE_SYS_TIME_H
|
|
||||||
#endif // TIME_WITH_SYS_TIME
|
|
||||||
|
|
||||||
#include <sys/wait.h>
|
#include <sys/wait.h>
|
||||||
|
|
||||||
#include <iostream>
|
#include <iostream>
|
||||||
#include <string>
|
|
||||||
#include <memory>
|
#include <memory>
|
||||||
#include <algorithm>
|
#include <algorithm>
|
||||||
#include <typeinfo>
|
#include <typeinfo>
|
||||||
|
|
42
src/main.cc
42
src/main.cc
|
@ -39,21 +39,12 @@
|
||||||
#define _GNU_SOURCE
|
#define _GNU_SOURCE
|
||||||
#endif // _GNU_SOURCE
|
#endif // _GNU_SOURCE
|
||||||
|
|
||||||
#ifdef HAVE_CSTDIO
|
|
||||||
#include <cstdio>
|
|
||||||
#else
|
|
||||||
#include <stdio.h>
|
|
||||||
#endif
|
|
||||||
#ifdef HAVE_CSTDLIB
|
#ifdef HAVE_CSTDLIB
|
||||||
#include <cstdlib>
|
#include <cstdlib>
|
||||||
#else
|
#else
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#endif
|
#endif
|
||||||
#ifdef HAVE_CSTRING
|
|
||||||
#include <cstring>
|
|
||||||
#else
|
|
||||||
#include <string.h>
|
|
||||||
#endif
|
|
||||||
#include <iostream>
|
#include <iostream>
|
||||||
#include <fstream>
|
#include <fstream>
|
||||||
#include <stdexcept>
|
#include <stdexcept>
|
||||||
|
@ -199,17 +190,18 @@ int main(int argc, char **argv) {
|
||||||
|
|
||||||
int i;
|
int i;
|
||||||
for (i = 1; i < argc; ++i) {
|
for (i = 1; i < argc; ++i) {
|
||||||
if (! strcmp(argv[i], "-rc")) {
|
string arg(argv[i]);
|
||||||
|
if (arg == "-rc") {
|
||||||
// look for alternative rc file to use
|
// look for alternative rc file to use
|
||||||
|
|
||||||
if ((++i) >= argc) {
|
if ((++i) >= argc) {
|
||||||
cerr<<_FB_CONSOLETEXT(main, RCRequiresArg,
|
cerr<<_FB_CONSOLETEXT(main, RCRequiresArg,
|
||||||
"error: '-rc' requires an argument", "the -rc option requires a file argument")<<endl;
|
"error: '-rc' requires an argument", "the -rc option requires a file argument")<<endl;
|
||||||
exit(1);
|
exit(EXIT_FAILURE);
|
||||||
}
|
}
|
||||||
|
|
||||||
rc_file = argv[i];
|
rc_file = arg;
|
||||||
} else if (! strcmp(argv[i], "-display")) {
|
} else if (arg == "-display") {
|
||||||
// check for -display option... to run on a display other than the one
|
// check for -display option... to run on a display other than the one
|
||||||
// set by the environment variable DISPLAY
|
// set by the environment variable DISPLAY
|
||||||
|
|
||||||
|
@ -217,10 +209,10 @@ int main(int argc, char **argv) {
|
||||||
cerr<<_FB_CONSOLETEXT(main, DISPLAYRequiresArg,
|
cerr<<_FB_CONSOLETEXT(main, DISPLAYRequiresArg,
|
||||||
"error: '-display' requires an argument",
|
"error: '-display' requires an argument",
|
||||||
"")<<endl;
|
"")<<endl;
|
||||||
exit(1);
|
exit(EXIT_FAILURE);
|
||||||
}
|
}
|
||||||
|
|
||||||
session_display = argv[i];
|
session_display = arg;
|
||||||
string display_env = "DISPLAY=" + session_display;
|
string display_env = "DISPLAY=" + session_display;
|
||||||
if (putenv(const_cast<char *>(display_env.c_str()))) {
|
if (putenv(const_cast<char *>(display_env.c_str()))) {
|
||||||
cerr<<_FB_CONSOLETEXT(main, WarnDisplayEnv,
|
cerr<<_FB_CONSOLETEXT(main, WarnDisplayEnv,
|
||||||
|
@ -228,17 +220,17 @@ int main(int argc, char **argv) {
|
||||||
"")<<endl;
|
"")<<endl;
|
||||||
perror("putenv()");
|
perror("putenv()");
|
||||||
}
|
}
|
||||||
} else if (strcmp(argv[i], "-version") == 0 || strcmp(argv[i], "-v") == 0) {
|
} else if (arg == "-version" || arg == "-v") {
|
||||||
// print current version string
|
// print current version string
|
||||||
cout << "Fluxbox " << __fluxbox_version << " : (c) 2001-2007 Henrik Kinnunen " << endl << endl;
|
cout << "Fluxbox " << __fluxbox_version << " : (c) 2001-2007 Henrik Kinnunen " << endl << endl;
|
||||||
exit(0);
|
exit(EXIT_SUCCESS);
|
||||||
} else if (strcmp(argv[i], "-log") == 0 ) {
|
} else if (arg == "-log") {
|
||||||
if (i + 1 >= argc) {
|
if (i + 1 >= argc) {
|
||||||
cerr<<_FB_CONSOLETEXT(main, LOGRequiresArg, "error: '-log' needs an argument", "")<<endl;
|
cerr<<_FB_CONSOLETEXT(main, LOGRequiresArg, "error: '-log' needs an argument", "")<<endl;
|
||||||
exit(1);
|
exit(EXIT_FAILURE);
|
||||||
}
|
}
|
||||||
log_filename = argv[++i];
|
log_filename = argv[++i];
|
||||||
} else if (strcmp(argv[i], "-help") == 0 || strcmp(argv[i], "-h") == 0) {
|
} else if (arg == "-help" || arg == "-h") {
|
||||||
// print program usage and command line options
|
// print program usage and command line options
|
||||||
printf(_FB_CONSOLETEXT(main, Usage,
|
printf(_FB_CONSOLETEXT(main, Usage,
|
||||||
"Fluxbox %s : (c) %s Henrik Kinnunen\n"
|
"Fluxbox %s : (c) %s Henrik Kinnunen\n"
|
||||||
|
@ -253,11 +245,11 @@ int main(int argc, char **argv) {
|
||||||
|
|
||||||
"Main usage string. Please lay it out nicely. There is one %s that is given the version").c_str(),
|
"Main usage string. Please lay it out nicely. There is one %s that is given the version").c_str(),
|
||||||
__fluxbox_version, "2001-2007");
|
__fluxbox_version, "2001-2007");
|
||||||
exit(0);
|
exit(EXIT_SUCCESS);
|
||||||
} else if (strcmp(argv[i], "-info") == 0 || strcmp(argv[i], "-i") == 0) {
|
} else if (arg == "-info" || arg == "-i") {
|
||||||
showInfo(cout);
|
showInfo(cout);
|
||||||
exit(0);
|
exit(EXIT_SUCCESS);
|
||||||
} else if (strcmp(argv[i], "-verbose") == 0) {
|
} else if (arg == "-verbose") {
|
||||||
FbTk::ThemeManager::instance().setVerbose(true);
|
FbTk::ThemeManager::instance().setVerbose(true);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue