summaryrefslogtreecommitdiff
Side-by-side diff
Diffstat (more/less context) (show whitespace changes)
-rw-r--r--core/apps/textedit/textedit.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/core/apps/textedit/textedit.cpp b/core/apps/textedit/textedit.cpp
index 571df27..cabeb20 100644
--- a/core/apps/textedit/textedit.cpp
+++ b/core/apps/textedit/textedit.cpp
@@ -788,7 +788,8 @@ bool TextEdit::save() {
name = doc->name();
odebug << "File named "+name << oendl;
} else {
- name = file = currentFileName;
+ file = currentFileName;
+ name = QFileInfo(currentFileName).baseName();
}
QString rt = editor->text();
@@ -924,7 +925,7 @@ bool TextEdit::saveAs() {
doc = new DocLnk(nf);
// editor->setText(rt);
odebug << "Saving file as "+currentFileName << oendl;
- doc->setName( currentFileName);
+ doc->setName( fi.baseName() /*currentFileName*/);
updateCaption( currentFileName);
FileManager fm;