PERFORCE change 166659 for review
Jonathan Anderson
jona at FreeBSD.org
Mon Jul 27 22:02:51 UTC 2009
http://perforce.freebsd.org/chv.cgi?CH=166659
Change 166659 by jona at jona-trustedbsd-belle-vmware on 2009/07/27 22:02:23
Only close the current file if we successfully open another one
Affected files ...
.. //depot/projects/trustedbsd/capabilities/src/tools/cap/sandbox_qt/TextEditor.cpp#6 edit
Differences ...
==== //depot/projects/trustedbsd/capabilities/src/tools/cap/sandbox_qt/TextEditor.cpp#6 (text+ko) ====
@@ -65,8 +65,6 @@
void TextEditor::open()
{
- close();
-
struct ua_powerbox_options options;
options.ui = UA_QT;
options.operation = UA_OPEN_FILE;
@@ -103,6 +101,8 @@
return;
}
+ close();
+
QFile file(this);
file.open(fd, QFile::ReadWrite | QFile::Unbuffered);
ui.text->setPlainText(file.readAll());
More information about the p4-projects
mailing list