diff options
author | Clinton Stimpson <clinton@elemtech.com> | 2008-02-01 15:41:29 (GMT) |
---|---|---|
committer | Clinton Stimpson <clinton@elemtech.com> | 2008-02-01 15:41:29 (GMT) |
commit | 41ad9d20df1b6d5466459e654f75094c008c9a0b (patch) | |
tree | 7f3fa76fbd229cdc3af798d45686dca0176209e1 /Source/QtDialog/CMakeSetup.cxx | |
parent | 587419db831b9e7e2172bcb6e5b04d81198c5eb8 (diff) | |
download | CMake-41ad9d20df1b6d5466459e654f75094c008c9a0b.zip CMake-41ad9d20df1b6d5466459e654f75094c008c9a0b.tar.gz CMake-41ad9d20df1b6d5466459e654f75094c008c9a0b.tar.bz2 |
ENH: Use translation file if it exists for the locale.
Consolidate some strings.
More responsive interrupting. Prompt user if they try to close during
configure, and allow them to close.
Diffstat (limited to 'Source/QtDialog/CMakeSetup.cxx')
-rw-r--r-- | Source/QtDialog/CMakeSetup.cxx | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/Source/QtDialog/CMakeSetup.cxx b/Source/QtDialog/CMakeSetup.cxx index 3543903..255b757 100644 --- a/Source/QtDialog/CMakeSetup.cxx +++ b/Source/QtDialog/CMakeSetup.cxx @@ -18,6 +18,7 @@ #include <QApplication> #include <QFileInfo> #include <QDir> +#include <QTranslator> #include "CMakeSetupDialog.h" #include "cmDocumentation.h" @@ -64,6 +65,12 @@ int main(int argc, char** argv) { cmSystemTools::FindExecutableDirectory(argv[0]); QApplication app(argc, argv); + + QTranslator translator; + QString transfile = QString("cmake_%1").arg(QLocale::system().name()); + translator.load(transfile, app.applicationDirPath()); + app.installTranslator(&translator); + app.setApplicationName("CMakeSetup"); app.setOrganizationName("Kitware"); app.setWindowIcon(QIcon(":/Icons/CMakeSetup.png")); @@ -99,7 +106,7 @@ int main(int argc, char** argv) } CMakeSetupDialog dialog; - dialog.setWindowTitle("CMakeSetup"); + dialog.setWindowTitle(QApplication::applicationName()); dialog.show(); // for now: args support specifying build and/or source directory |