mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
Only load default file if no file is given on the command line
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
3335f083bf
commit
dda3253b77
1 changed files with 5 additions and 3 deletions
8
main.cpp
8
main.cpp
|
@ -16,7 +16,7 @@
|
||||||
int main(int argc, char **argv)
|
int main(int argc, char **argv)
|
||||||
{
|
{
|
||||||
int i;
|
int i;
|
||||||
bool no_filenames = TRUE;
|
bool no_filenames = true;
|
||||||
const char *path;
|
const char *path;
|
||||||
|
|
||||||
/* set up l18n - the search directory needs to change
|
/* set up l18n - the search directory needs to change
|
||||||
|
@ -43,10 +43,12 @@ int main(int argc, char **argv)
|
||||||
parse_argument(a);
|
parse_argument(a);
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
if (imported)
|
if (imported) {
|
||||||
importedFiles.push_back( QString(a) );
|
importedFiles.push_back( QString(a) );
|
||||||
else
|
} else {
|
||||||
|
no_filenames = false;
|
||||||
files.push_back( QString(a) );
|
files.push_back( QString(a) );
|
||||||
|
}
|
||||||
}
|
}
|
||||||
if (no_filenames) {
|
if (no_filenames) {
|
||||||
files.push_back( QString(prefs.default_filename) );
|
files.push_back( QString(prefs.default_filename) );
|
||||||
|
|
Loading…
Add table
Reference in a new issue