<table><tr><td style="">russellg created this revision.<br />russellg set the repository for this revision to R39 KTextEditor.<br />Restricted Application added subscribers: Frameworks, kwrite-devel.<br />Restricted Application added a project: Frameworks.
</td><a style="text-decoration: none; padding: 4px 8px; margin: 0 8px 8px; float: right; color: #464C5C; font-weight: bold; border-radius: 3px; background-color: #F7F7F9; background-image: linear-gradient(to bottom,#fff,#f1f0f1); display: inline-block; border: 1px solid rgba(71,87,120,.2);" href="https://phabricator.kde.org/D4628" rel="noreferrer">View Revision</a></tr></table><br /><div><strong>REVISION SUMMARY</strong><div><p>I'm currently writing an application where the user is expected to type some code in, but it isn't then saved to a file, but it is just passed back to the application in memory.</p>

<p>It's misleading to the user for them to press Ctrl+S and then a save dialog comes up--they shouldn't be saving it!</p>

<p>Here's my fix. Any suggestions are welcome.</p></div></div><br /><div><strong>TEST PLAN</strong><div><p>I added a basic test to the test suite, it's not very good though. I wanted to make sure that the <tt style="background: #ebebeb; font-size: 13px;">documentSaveAs</tt> function was failing _before_ I called <tt style="background: #ebebeb; font-size: 13px;">setSaveEnabled</tt>, but that would require somehow pressing "cancel" on the file dialog which I do not know how to do, if it's possible at all.</p></div></div><br /><div><strong>REPOSITORY</strong><div><div>R39 KTextEditor</div></div></div><br /><div><strong>REVISION DETAIL</strong><div><a href="https://phabricator.kde.org/D4628" rel="noreferrer">https://phabricator.kde.org/D4628</a></div></div><br /><div><strong>AFFECTED FILES</strong><div><div>autotests/src/katedocument_test.cpp<br />
autotests/src/katedocument_test.h<br />
src/document/katedocument.cpp<br />
src/document/katedocument.h<br />
src/include/ktexteditor/document.h</div></div></div><br /><div><strong>EMAIL PREFERENCES</strong><div><a href="https://phabricator.kde.org/settings/panel/emailpreferences/" rel="noreferrer">https://phabricator.kde.org/settings/panel/emailpreferences/</a></div></div><br /><div><strong>To: </strong>russellg<br /><strong>Cc: </strong>kwrite-devel, Frameworks<br /></div>