[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-bugs-dist
Subject: [Bug 86816] save with write protect forgets file change status
From: Jens Dagerbo <jens.dagerbo () swipnet ! se>
Date: 2004-08-30 20:34:57
Message-ID: 20040830203457.29038.qmail () ktown ! kde ! org
[Download RAW message or body]
------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.
http://bugs.kde.org/show_bug.cgi?id=86816
jens.dagerbo swipnet se changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |RESOLVED
Resolution| |FIXED
------- Additional Comments From jens.dagerbo swipnet se 2004-08-30 22:34 -------
CVS commit by dagerbo:
Right, filesaves can fail. (D'oh!) + minor cleanup.
CCMAIL: 86816-done bugs kde org
M +10 -17 partcontroller.cpp 1.142
--- kdevelop/src/partcontroller.cpp #1.141:1.142
@ -954,8 +954,10 @ bool PartController::saveFile( const KUR
}
- part->save();
+ if ( part->save() )
+ {
_dirtyDocuments.remove( part );
emit documentChangedState( url, Clean );
emit savedFile( url );
+ }
return true;
@ -1074,17 +1076,8 @ bool PartController::closeAllOthers( con
void PartController::slotCloseOtherWindows()
{
- KParts::ReadOnlyPart * active = dynamic_cast<KParts::ReadOnlyPart*>(activePart());
- if ( !active ) return;
-
+ if ( KParts::ReadOnlyPart * active = dynamic_cast<KParts::ReadOnlyPart*>( activePart() ) )
+ {
closeAllOthers( active->url() );
- /*
- KParts::ReadOnlyPart * active = dynamic_cast<KParts::ReadOnlyPart*>(activePart());
- if ( !active ) return;
-
- KURL::List ignoreList;
- ignoreList.append( active->url() );
-
- closeFilesDialog( ignoreList );
- */
+ }
}
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic