summaryrefslogtreecommitdiffstats
path: root/src/extension/system.cpp
diff options
context:
space:
mode:
authorMaximilian Albert <maximilian.albert@gmail.com>2009-08-12 13:18:51 +0000
committercilix42 <cilix42@users.sourceforge.net>2009-08-12 13:18:51 +0000
commit9f9e21dec8cc697d91646924da431fc04a2b78bd (patch)
treed6bf9ceefb896740bb5a79fb8c16aec0845d8a17 /src/extension/system.cpp
parentMinor changes. (diff)
downloadinkscape-9f9e21dec8cc697d91646924da431fc04a2b78bd.tar.gz
inkscape-9f9e21dec8cc697d91646924da431fc04a2b78bd.zip
Don't open 'Save as ...' dialog inside the application bundle on OS X when it is invoked for the first time
(bzr r8472)
Diffstat (limited to 'src/extension/system.cpp')
-rw-r--r--src/extension/system.cpp10
1 files changed, 6 insertions, 4 deletions
diff --git a/src/extension/system.cpp b/src/extension/system.cpp
index 2251ac7b6..365ea925b 100644
--- a/src/extension/system.cpp
+++ b/src/extension/system.cpp
@@ -568,7 +568,6 @@ get_file_save_extension (Inkscape::Extension::FileSaveMethod method) {
break;
}
- // this is probably unnecessary, but just to be on the safe side ...
if(extension.empty())
extension = SP_MODULE_KEY_OUTPUT_SVG_INKSCAPE;
@@ -591,14 +590,17 @@ get_file_save_path (SPDocument *doc, FileSaveMethod method) {
if (doc->uri) {
path = Glib::path_get_dirname(doc->uri);
} else {
- // FIXME: should we use the save_as path here or the current directory or even something else?
+ // FIXME: should we use the save_as path here or something else? Maybe we should
+ // leave this as a choice to the user.
path = prefs->getString("/dialogs/save_as/path");
}
}
- // this is probably unnecessary, but just to be on the safe side ...
if(path.empty())
- path = g_get_current_dir(); // is this the most sensible solution?
+ path = g_get_home_dir(); // Is this the most sensible solution? Note that we should avoid
+ // g_get_current_dir because this leads to problems on OS X where
+ // Inkscape opens the dialog inside application bundle when it is
+ // invoked for the first teim.
return path;
}