summaryrefslogtreecommitdiff
authorllornkcor <llornkcor>2004-10-18 09:18:50 (UTC)
committer llornkcor <llornkcor>2004-10-18 09:18:50 (UTC)
commitb4a613303322cd557915baa621d4a1cef749af59 (patch) (unidiff)
tree2bb7ba0e89ce00d0ccb408a69ae79b5c38af6b0e
parente95fcb09fc069a83b3c10c19c081873daba49831 (diff)
downloadopie-b4a613303322cd557915baa621d4a1cef749af59.zip
opie-b4a613303322cd557915baa621d4a1cef749af59.tar.gz
opie-b4a613303322cd557915baa621d4a1cef749af59.tar.bz2
change doclnk handling
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--core/apps/textedit/textedit.cpp7
1 files changed, 4 insertions, 3 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,9 +788,10 @@ bool TextEdit::save() {
788 name = doc->name(); 788 name = doc->name();
789 odebug << "File named "+name << oendl; 789 odebug << "File named "+name << oendl;
790 } else { 790 } else {
791 name = file = currentFileName; 791 file = currentFileName;
792 name = QFileInfo(currentFileName).baseName();
792 } 793 }
793 794
794 QString rt = editor->text(); 795 QString rt = editor->text();
795 if( !rt.isEmpty() ) { 796 if( !rt.isEmpty() ) {
796 if(name.isEmpty()) { 797 if(name.isEmpty()) {
@@ -924,7 +925,7 @@ bool TextEdit::saveAs() {
924 doc = new DocLnk(nf); 925 doc = new DocLnk(nf);
925// editor->setText(rt); 926// editor->setText(rt);
926 odebug << "Saving file as "+currentFileName << oendl; 927 odebug << "Saving file as "+currentFileName << oendl;
927 doc->setName( currentFileName); 928 doc->setName( fi.baseName() /*currentFileName*/);
928 updateCaption( currentFileName); 929 updateCaption( currentFileName);
929 930
930 FileManager fm; 931 FileManager fm;