summaryrefslogtreecommitdiffstats
path: root/src/file.cpp
diff options
context:
space:
mode:
authorTed Gould <ted@gould.cx>2012-11-25 19:41:24 +0000
committerTed Gould <ted@gould.cx>2012-11-25 19:41:24 +0000
commit18be0e5e3ab74823043e19dd6ea46c4b6b130e86 (patch)
treea62925ec4473c1a21e1c99d1415f4cccab59b432 /src/file.cpp
parentGetting all the filter headers (diff)
parentFix for 1036059 : Keyboard shortcut editor (diff)
downloadinkscape-18be0e5e3ab74823043e19dd6ea46c4b6b130e86.tar.gz
inkscape-18be0e5e3ab74823043e19dd6ea46c4b6b130e86.zip
Update to current trunk
(bzr r11804.1.8)
Diffstat (limited to 'src/file.cpp')
-rw-r--r--src/file.cpp15
1 files changed, 13 insertions, 2 deletions
diff --git a/src/file.cpp b/src/file.cpp
index a03c459da..14f70fc8c 100644
--- a/src/file.cpp
+++ b/src/file.cpp
@@ -675,7 +675,12 @@ file_save(Gtk::Window &parentWindow, SPDocument *doc, const Glib::ustring &uri,
}
SP_ACTIVE_DESKTOP->event_log->rememberFileSave();
- Glib::ustring msg = Glib::ustring::format(_("Document saved."), " ", doc->getURI());
+ Glib::ustring msg;
+ if (doc->getURI() == NULL) {
+ msg = Glib::ustring::format(_("Document saved."));
+ } else {
+ msg = Glib::ustring::format(_("Document saved."), " ", doc->getURI());
+ }
SP_ACTIVE_DESKTOP->messageStack()->flash(Inkscape::NORMAL_MESSAGE, msg.c_str());
return true;
}
@@ -952,7 +957,13 @@ sp_file_save_document(Gtk::Window &parentWindow, SPDocument *doc)
}
}
} else {
- Glib::ustring msg = Glib::ustring::format(_("No changes need to be saved."), " ", doc->getURI());
+ Glib::ustring msg;
+ if ( doc->getURI() == NULL )
+ {
+ msg = Glib::ustring::format(_("No changes need to be saved."));
+ } else {
+ msg = Glib::ustring::format(_("No changes need to be saved."), " ", doc->getURI());
+ }
SP_ACTIVE_DESKTOP->messageStack()->flash(Inkscape::WARNING_MESSAGE, msg.c_str());
success = TRUE;
}