mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
Initialize QSettings earlier & change the Organization to "Subsurface"
The first change allows the default_filename to be found again. The second change switches us to .config/Subsurface/Subsurface.conf which I find much more useful. QtCreator also fixed a few indentation issues for me. How helpful. Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
238c80a708
commit
6d3a4ec9b2
2 changed files with 6 additions and 6 deletions
2
main.c
2
main.c
|
@ -217,7 +217,7 @@ int main(int argc, char **argv)
|
||||||
subsurface_command_line_init(&argc, &argv);
|
subsurface_command_line_init(&argc, &argv);
|
||||||
parse_xml_init();
|
parse_xml_init();
|
||||||
|
|
||||||
init_ui(&argc, &argv); /* the gtk stuff is needed for parsing below */
|
init_ui(&argc, &argv);
|
||||||
|
|
||||||
for (i = 1; i < argc; i++) {
|
for (i = 1; i < argc; i++) {
|
||||||
const char *a = argv[i];
|
const char *a = argv[i];
|
||||||
|
|
|
@ -61,9 +61,6 @@ const char *existing_filename;
|
||||||
void init_qt_ui(int *argcp, char ***argvp)
|
void init_qt_ui(int *argcp, char ***argvp)
|
||||||
{
|
{
|
||||||
application->installTranslator(new Translator(application));
|
application->installTranslator(new Translator(application));
|
||||||
QCoreApplication::setOrganizationName("hohndel");
|
|
||||||
QCoreApplication::setOrganizationDomain("hohndel.org");
|
|
||||||
QCoreApplication::setApplicationName("Subsurface");
|
|
||||||
MainWindow *window = new MainWindow();
|
MainWindow *window = new MainWindow();
|
||||||
window->show();
|
window->show();
|
||||||
}
|
}
|
||||||
|
@ -80,6 +77,9 @@ void init_ui(int *argcp, char ***argvp)
|
||||||
// [http://www.iana.org/assignments/character-sets/character-sets.xml]
|
// [http://www.iana.org/assignments/character-sets/character-sets.xml]
|
||||||
QTextCodec::setCodecForCStrings(QTextCodec::codecForMib(106));
|
QTextCodec::setCodecForCStrings(QTextCodec::codecForMib(106));
|
||||||
#endif
|
#endif
|
||||||
|
QCoreApplication::setOrganizationName("Subsurface");
|
||||||
|
QCoreApplication::setOrganizationDomain("subsurface.hohndel.org");
|
||||||
|
QCoreApplication::setApplicationName("Subsurface");
|
||||||
|
|
||||||
QSettings settings;
|
QSettings settings;
|
||||||
settings.beginGroup("GeneralSettings");
|
settings.beginGroup("GeneralSettings");
|
||||||
|
|
Loading…
Add table
Reference in a new issue