<table><tr><td style="">mlaurent requested changes to this revision.<br />mlaurent added inline comments.<br />This revision now requires changes to proceed.
</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/D8642" rel="noreferrer">View Revision</a></tr></table><br /><div><strong>INLINE COMMENTS</strong><div><div style="margin: 6px 0 12px 0;"><div style="border: 1px solid #C7CCD9; border-radius: 3px;"><div style="padding: 0; background: #F7F7F7; border-color: #e3e4e8; border-style: solid; border-width: 0 0 1px 0; margin: 0;"><div style="color: #74777d; background: #eff2f4; padding: 6px 8px; overflow: hidden;"><a style="float: right; text-decoration: none;" href="https://phabricator.kde.org/D8642#inline-37873" rel="noreferrer">View Inline</a><span style="color: #4b4d51; font-weight: bold;">documenttest.cpp:112</span></div>
<div style="font: 11px/15px "Menlo", "Consolas", "Monaco", monospace; white-space: pre-wrap; clear: both; padding: 4px 0; margin: 0;"><div style="padding: 0 8px; margin: 0 4px; background: rgba(151, 234, 151, .6);"> <span class="n">QCOMPARE</span><span class="p">(</span> <span class="n">m_document</span><span style="color: #aa2211">-></span><span class="n">isDocdataMigrationNeeded</span><span class="p">(),</span> <span style="color: #304a96">false</span> <span class="p">);</span>
</div><div style="padding: 0 8px; margin: 0 4px; background: rgba(151, 234, 151, .6);"> <span class="n">m_document</span><span style="color: #aa2211">-></span><span class="n">closeDocument</span><span class="p">();</span>
</div><div style="padding: 0 8px; margin: 0 4px; background: rgba(151, 234, 151, .6);"><span class="p">}</span>
</div></div></div>
<div style="margin: 8px 0; padding: 0 12px;"><p style="padding: 0; margin: 8px;">closeDocument delete m_document with a deleteLater or we need to delete it before finish method ?</p></div></div><br /><div style="border: 1px solid #C7CCD9; border-radius: 3px;"><div style="padding: 0; background: #F7F7F7; border-color: #e3e4e8; border-style: solid; border-width: 0 0 1px 0; margin: 0;"><div style="color: #74777d; background: #eff2f4; padding: 6px 8px; overflow: hidden;"><a style="float: right; text-decoration: none;" href="https://phabricator.kde.org/D8642#inline-37874" rel="noreferrer">View Inline</a><span style="color: #4b4d51; font-weight: bold;">parttest.cpp:785</span></div>
<div style="font: 11px/15px "Menlo", "Consolas", "Monaco", monospace; white-space: pre-wrap; clear: both; padding: 4px 0; margin: 0;"><div style="padding: 0 8px; margin: 0 4px; background: rgba(151, 234, 151, .6);"> <span class="n">QTemporaryFile</span> <span style="color: #004012">nativeFromArchiveFile</span><span class="p">(</span> <span class="n">QString</span><span class="p">(</span> <span style="color: #766510">"%1/okrXXXXXX.%2"</span> <span class="p">).</span><span class="n">arg</span><span class="p">(</span> <span class="n">QDir</span><span style="color: #aa2211">::</span><span class="n">tempPath</span><span class="p">()</span> <span class="p">).</span><span class="n">arg</span> <span class="p">(</span> <span class="n">extension</span> <span class="p">)</span> <span class="p">);</span>
</div><div style="padding: 0 8px; margin: 0 4px; background: rgba(151, 234, 151, .6);"> <span class="n">QVERIFY</span><span class="p">(</span> <span class="n">archiveSave</span><span class="p">.</span><span class="n">open</span><span class="p">()</span> <span class="p">);</span> <span class="n">archiveSave</span><span class="p">.</span><span class="n">close</span><span class="p">();</span>
</div><div style="padding: 0 8px; margin: 0 4px; background: rgba(151, 234, 151, .6);"> <span class="n">QVERIFY</span><span class="p">(</span> <span class="n">nativeDirectSave</span><span class="p">.</span><span class="n">open</span><span class="p">()</span> <span class="p">);</span> <span class="n">nativeDirectSave</span><span class="p">.</span><span class="n">close</span><span class="p">();</span>
</div></div></div>
<div style="margin: 8px 0; padding: 0 12px;"><p style="padding: 0; margin: 8px;">new line before archiveSave.close() more readable</p></div></div><br /><div style="border: 1px solid #C7CCD9; border-radius: 3px;"><div style="padding: 0; background: #F7F7F7; border-color: #e3e4e8; border-style: solid; border-width: 0 0 1px 0; margin: 0;"><div style="color: #74777d; background: #eff2f4; padding: 6px 8px; overflow: hidden;"><a style="float: right; text-decoration: none;" href="https://phabricator.kde.org/D8642#inline-37881" rel="noreferrer">View Inline</a><span style="color: #4b4d51; font-weight: bold;">document.cpp:4388</span></div>
<div style="font: 11px/15px "Menlo", "Consolas", "Monaco", monospace; white-space: pre-wrap; clear: both; padding: 4px 0; margin: 0;"><div style="padding: 0 8px; margin: 0 4px; background: rgba(151, 234, 151, .6);"> <span class="p">{</span>
</div><div style="padding: 0 8px; margin: 0 4px; background: rgba(151, 234, 151, .6);"> <span class="n">qWarning</span><span class="p">()</span> <span style="color: #aa2211"><<</span> <span style="color: #766510">"Unhandled undo command"</span> <span style="color: #aa2211"><<</span> <span class="n">uc</span><span class="p">;</span>
</div><div style="padding: 0 8px; margin: 0 4px; background: rgba(151, 234, 151, .6);"> <span class="p">}</span>
</div></div></div>
<div style="margin: 8px 0; padding: 0 12px;"><p style="padding: 0; margin: 8px;">qCWarning(...)</p></div></div><br /><div style="border: 1px solid #C7CCD9; border-radius: 3px;"><div style="padding: 0; background: #F7F7F7; border-color: #e3e4e8; border-style: solid; border-width: 0 0 1px 0; margin: 0;"><div style="color: #74777d; background: #eff2f4; padding: 6px 8px; overflow: hidden;"><a style="float: right; text-decoration: none;" href="https://phabricator.kde.org/D8642#inline-37882" rel="noreferrer">View Inline</a><span style="color: #4b4d51; font-weight: bold;">document.cpp:4444</span></div>
<div style="font: 11px/15px "Menlo", "Consolas", "Monaco", monospace; white-space: pre-wrap; clear: both; padding: 4px 0; margin: 0;"><div style="padding: 0 8px; margin: 0 4px; background: rgba(151, 234, 151, .6);"><span style="color: #aa4000">bool</span> <span class="n">Document</span><span style="color: #aa2211">::</span><span class="n">swapBackingFileArchive</span><span class="p">(</span> <span style="color: #aa4000">const</span> <span class="n">QString</span> <span style="color: #aa2211">&</span><span class="n">newFileName</span><span class="p">,</span> <span style="color: #aa4000">const</span> <span class="n">QUrl</span> <span style="color: #aa2211">&</span> <span class="n">url</span> <span class="p">)</span>
</div><div style="padding: 0 8px; margin: 0 4px; background: rgba(151, 234, 151, .6);"><span class="p">{</span>
</div></div></div>
<div style="margin: 8px 0; padding: 0 12px;"><p style="padding: 0; margin: 8px;">Remove space before url</p></div></div><br /><div style="border: 1px solid #C7CCD9; border-radius: 3px;"><div style="padding: 0; background: #F7F7F7; border-color: #e3e4e8; border-style: solid; border-width: 0 0 1px 0; margin: 0;"><div style="color: #74777d; background: #eff2f4; padding: 6px 8px; overflow: hidden;"><a style="float: right; text-decoration: none;" href="https://phabricator.kde.org/D8642#inline-37884" rel="noreferrer">View Inline</a><span style="color: #4b4d51; font-weight: bold;">document.cpp:4494</span></div>
<div style="font: 11px/15px "Menlo", "Consolas", "Monaco", monospace; white-space: pre-wrap; clear: both; padding: 4px 0; margin: 0;"><div style="padding: 0 8px; margin: 0 4px; background: rgba(151, 234, 151, .6);"> <span class="p">{</span>
</div><div style="padding: 0 8px; margin: 0 4px; background: rgba(151, 234, 151, .6);"> <span class="n">qWarning</span><span class="p">()</span> <span style="color: #aa2211"><<</span> <span style="color: #766510">"Unhandled undo command"</span> <span style="color: #aa2211"><<</span> <span class="n">uc</span><span class="p">;</span>
</div><div style="padding: 0 8px; margin: 0 4px; background: rgba(151, 234, 151, .6);"> <span class="p">}</span>
</div></div></div>
<div style="margin: 8px 0; padding: 0 12px;"><p style="padding: 0; margin: 8px;">qCWarnign(...)</p></div></div><br /><div style="border: 1px solid #C7CCD9; border-radius: 3px;"><div style="padding: 0; background: #F7F7F7; border-color: #e3e4e8; border-style: solid; border-width: 0 0 1px 0; margin: 0;"><div style="color: #74777d; background: #eff2f4; padding: 6px 8px; overflow: hidden;"><a style="float: right; text-decoration: none;" href="https://phabricator.kde.org/D8642#inline-37890" rel="noreferrer">View Inline</a><span style="color: #4b4d51; font-weight: bold;">document.cpp:4729</span></div>
<div style="font: 11px/15px "Menlo", "Consolas", "Monaco", monospace; white-space: pre-wrap; clear: both; padding: 4px 0; margin: 0;"><div style="padding: 0 8px; margin: 0 4px; background: rgba(151, 234, 151, .6);"><span class="n">Document</span><span style="color: #aa2211">::</span><span class="n">OpenResult</span> <span class="n">Document</span><span style="color: #aa2211">::</span><span class="n">openDocumentArchive</span><span class="p">(</span> <span style="color: #aa4000">const</span> <span class="n">QString</span> <span style="color: #aa2211">&</span> <span class="n">docFile</span><span class="p">,</span> <span style="color: #aa4000">const</span> <span class="n">QUrl</span> <span style="color: #aa2211">&</span> <span class="n">url</span><span class="p">,</span> <span style="color: #aa4000">const</span> <span class="n">QString</span> <span style="color: #aa2211">&</span> <span class="n">password</span> <span class="p">)</span>
</div><div style="padding: 0 8px; margin: 0 4px; background: rgba(151, 234, 151, .6);"><span class="p">{</span>
</div></div></div>
<div style="margin: 8px 0; padding: 0 12px;"><p style="padding: 0; margin: 8px;">coding style : remove space after &</p></div></div><br /><div style="border: 1px solid #C7CCD9; border-radius: 3px;"><div style="padding: 0; background: #F7F7F7; border-color: #e3e4e8; border-style: solid; border-width: 0 0 1px 0; margin: 0;"><div style="color: #74777d; background: #eff2f4; padding: 6px 8px; overflow: hidden;"><a style="float: right; text-decoration: none;" href="https://phabricator.kde.org/D8642#inline-37875" rel="noreferrer">View Inline</a><span style="color: #4b4d51; font-weight: bold;">document.h:744</span></div>
<div style="font: 11px/15px "Menlo", "Consolas", "Monaco", monospace; white-space: pre-wrap; clear: both; padding: 4px 0; margin: 0;"><div style="padding: 0 8px; margin: 0 4px; background: rgba(151, 234, 151, .6);"><span style="color: #74777d"> *</span>
</div><div style="padding: 0 8px; margin: 0 4px; background: rgba(151, 234, 151, .6);"><span style="color: #74777d"> * @since 0.20 (KDE 4.14)</span>
</div><div style="padding: 0 8px; margin: 0 4px; background: rgba(151, 234, 151, .6);"><span style="color: #74777d"> */</span>
</div></div></div>
<div style="margin: 8px 0; padding: 0 12px;"><p style="padding: 0; margin: 8px;">4.14?</p></div></div><br /><div style="border: 1px solid #C7CCD9; border-radius: 3px;"><div style="padding: 0; background: #F7F7F7; border-color: #e3e4e8; border-style: solid; border-width: 0 0 1px 0; margin: 0;"><div style="color: #74777d; background: #eff2f4; padding: 6px 8px; overflow: hidden;"><a style="float: right; text-decoration: none;" href="https://phabricator.kde.org/D8642#inline-37876" rel="noreferrer">View Inline</a><span style="color: #4b4d51; font-weight: bold;">document.h:758</span></div>
<div style="font: 11px/15px "Menlo", "Consolas", "Monaco", monospace; white-space: pre-wrap; clear: both; padding: 4px 0; margin: 0;"><div style="padding: 0 8px; margin: 0 4px; background: rgba(151, 234, 151, .6);"><span style="color: #74777d"> *</span>
</div><div style="padding: 0 8px; margin: 0 4px; background: rgba(151, 234, 151, .6);"><span style="color: #74777d"> * @since 0.20 (KDE 4.14)</span>
</div><div style="padding: 0 8px; margin: 0 4px; background: rgba(151, 234, 151, .6);"><span style="color: #74777d"> */</span>
</div></div></div>
<div style="margin: 8px 0; padding: 0 12px;"><p style="padding: 0; margin: 8px;">4.14?</p></div></div><br /><div style="border: 1px solid #C7CCD9; border-radius: 3px;"><div style="padding: 0; background: #F7F7F7; border-color: #e3e4e8; border-style: solid; border-width: 0 0 1px 0; margin: 0;"><div style="color: #74777d; background: #eff2f4; padding: 6px 8px; overflow: hidden;"><a style="float: right; text-decoration: none;" href="https://phabricator.kde.org/D8642#inline-37877" rel="noreferrer">View Inline</a><span style="color: #4b4d51; font-weight: bold;">document.h:771</span></div>
<div style="font: 11px/15px "Menlo", "Consolas", "Monaco", monospace; white-space: pre-wrap; clear: both; padding: 4px 0; margin: 0;"><div style="padding: 0 8px; margin: 0 4px; background: rgba(151, 234, 151, .6);"><span style="color: #74777d"> *</span>
</div><div style="padding: 0 8px; margin: 0 4px; background: rgba(151, 234, 151, .6);"><span style="color: #74777d"> * @since 0.20 (KDE 4.14)</span>
</div><div style="padding: 0 8px; margin: 0 4px; background: rgba(151, 234, 151, .6);"><span style="color: #74777d"> */</span>
</div></div></div>
<div style="margin: 8px 0; padding: 0 12px;"><p style="padding: 0; margin: 8px;">same</p></div></div><br /><div style="border: 1px solid #C7CCD9; border-radius: 3px;"><div style="padding: 0; background: #F7F7F7; border-color: #e3e4e8; border-style: solid; border-width: 0 0 1px 0; margin: 0;"><div style="color: #74777d; background: #eff2f4; padding: 6px 8px; overflow: hidden;"><a style="float: right; text-decoration: none;" href="https://phabricator.kde.org/D8642#inline-37878" rel="noreferrer">View Inline</a><span style="color: #4b4d51; font-weight: bold;">document.h:773</span></div>
<div style="font: 11px/15px "Menlo", "Consolas", "Monaco", monospace; white-space: pre-wrap; clear: both; padding: 4px 0; margin: 0;"><div style="padding: 0 8px; margin: 0 4px; background: rgba(151, 234, 151, .6);"><span style="color: #74777d"> */</span>
</div><div style="padding: 0 8px; margin: 0 4px; background: rgba(151, 234, 151, .6);"> <span style="color: #aa4000">bool</span> <span style="color: #004012">swapBackingFileArchive</span><span class="p">(</span> <span style="color: #aa4000">const</span> <span class="n">QString</span> <span style="color: #aa2211">&</span><span class="n">newFileName</span><span class="p">,</span> <span style="color: #aa4000">const</span> <span class="n">QUrl</span> <span style="color: #aa2211">&</span> <span class="n">url</span> <span class="p">);</span>
</div></div></div>
<div style="margin: 8px 0; padding: 0 12px;"><p style="padding: 0; margin: 8px;">coding style: Remove space before url</p></div></div><br /><div style="border: 1px solid #C7CCD9; border-radius: 3px;"><div style="padding: 0; background: #F7F7F7; border-color: #e3e4e8; border-style: solid; border-width: 0 0 1px 0; margin: 0;"><div style="color: #74777d; background: #eff2f4; padding: 6px 8px; overflow: hidden;"><a style="float: right; text-decoration: none;" href="https://phabricator.kde.org/D8642#inline-37879" rel="noreferrer">View Inline</a><span style="color: #4b4d51; font-weight: bold;">document.h:865</span></div>
<div style="font: 11px/15px "Menlo", "Consolas", "Monaco", monospace; white-space: pre-wrap; clear: both; padding: 4px 0; margin: 0;"><div style="padding: 0 8px; margin: 0 4px; background: rgba(151, 234, 151, .6);"><span style="color: #74777d"> *</span>
</div><div style="padding: 0 8px; margin: 0 4px; background: rgba(151, 234, 151, .6);"><span style="color: #74777d"> * @since 0.14 (KDE 4.20)</span>
</div><div style="padding: 0 8px; margin: 0 4px; background: rgba(151, 234, 151, .6);"><span style="color: #74777d"> */</span>
</div></div></div>
<div style="margin: 8px 0; padding: 0 12px;"><p style="padding: 0; margin: 8px;">kde 4.20 ?</p></div></div><br /><div style="border: 1px solid #C7CCD9; border-radius: 3px;"><div style="padding: 0; background: #F7F7F7; border-color: #e3e4e8; border-style: solid; border-width: 0 0 1px 0; margin: 0;"><div style="color: #74777d; background: #eff2f4; padding: 6px 8px; overflow: hidden;"><a style="float: right; text-decoration: none;" href="https://phabricator.kde.org/D8642#inline-37891" rel="noreferrer">View Inline</a><span style="color: #4b4d51; font-weight: bold;">documentcommands.cpp:714</span></div>
<div style="font: 11px/15px "Menlo", "Consolas", "Monaco", monospace; white-space: pre-wrap; clear: both; padding: 4px 0; margin: 0;"><div style="padding: 0 8px; margin: 0 4px; background: rgba(151, 234, 151, .6);"> <span class="p">{</span>
</div><div style="padding: 0 8px; margin: 0 4px; background: rgba(151, 234, 151, .6);"> <span class="n">FormFieldButton</span> <span style="color: #aa2211">*</span><span class="n">button</span> <span style="color: #aa2211">=</span> <span style="color: #aa4000">dynamic_cast</span><span style="color: #aa2211"><</span><span class="n">FormFieldButton</span> <span style="color: #aa2211">*></span><span class="p">(</span><span class="n">Okular</span><span style="color: #aa2211">::</span><span class="n">PagePrivate</span><span style="color: #aa2211">::</span><span class="n">findEquivalentForm</span><span class="p">(</span> <span class="n">newPagesVector</span><span class="p">[</span><span class="n">m_pageNumber</span><span class="p">],</span> <span class="n">oldFormButton</span> <span class="p">));</span>
</div><div style="padding: 0 8px; margin: 0 4px; background: rgba(151, 234, 151, .6);"> <span class="n">m_formButtons</span> <span style="color: #aa2211"><<</span> <span class="n">button</span><span class="p">;</span>
</div></div></div>
<div style="margin: 8px 0; padding: 0 12px;"><p style="padding: 0; margin: 8px;">if button is null do you think that we need to add to QList ?</p></div></div><br /><div style="border: 1px solid #C7CCD9; border-radius: 3px;"><div style="padding: 0; background: #F7F7F7; border-color: #e3e4e8; border-style: solid; border-width: 0 0 1px 0; margin: 0;"><div style="color: #74777d; background: #eff2f4; padding: 6px 8px; overflow: hidden;"><a style="float: right; text-decoration: none;" href="https://phabricator.kde.org/D8642#inline-37892" rel="noreferrer">View Inline</a><span style="color: #4b4d51; font-weight: bold;">part.cpp:566</span></div>
<div style="font: 11px/15px "Menlo", "Consolas", "Monaco", monospace; white-space: pre-wrap; clear: both; padding: 4px 0; margin: 0;"><div style="padding: 0 8px; margin: 0 4px; "> <span class="n">m_dirtyHandler</span><span style="color: #aa2211">-></span><span class="n">setSingleShot</span><span class="p">(</span> <span style="color: #304a96">true</span> <span class="p">);</span>
</div><div style="padding: 0 8px; margin: 0 4px; background: rgba(251, 175, 175, .7);"> <span class="n">connect</span><span class="p">(</span> <span class="n">m_dirtyHandler</span><span class="p">,</span> <span class="bright"></span><span style="color: #aa2211"><span class="bright">&</span></span><span class="bright"></span><span class="n"><span class="bright">QTimer</span></span><span class="bright"></span><span style="color: #aa2211"><span class="bright">::</span></span><span class="n">timeout</span><span class="p">,</span><span style="color: #aa4000">this</span><span class="p">,</span> <span class="bright"></span><span style="color: #aa2211"><span class="bright">&</span></span><span class="bright"></span><span class="n"><span class="bright">Part</span></span><span class="bright"></span><span style="color: #aa2211"><span class="bright">::</span></span><span class="n">slot<span class="bright">DoFileDirty</span></span> <span class="p">);</span>
</div><div style="padding: 0 8px; margin: 0 4px; background: rgba(151, 234, 151, .6);"> <span class="n">connect</span><span class="p">(</span> <span class="n">m_dirtyHandler</span><span class="p">,</span> <span class="bright"></span><span class="n"><span class="bright">SIGNAL</span></span><span class="bright"></span><span class="p"><span class="bright">(</span></span><span class="n">timeout<span class="bright"></span></span><span class="bright"></span><span class="p"><span class="bright">())</span>,</span><span style="color: #aa4000">this</span><span class="p">,</span> <span class="bright"></span><span class="n"><span class="bright">SLOT</span></span><span class="bright"></span><span class="p"><span class="bright">(</span></span><span class="n">slot<span class="bright">AttemptReload</span></span><span class="bright"></span><span class="p"><span class="bright">())</span></span> <span class="p">);</span>
</div></div></div>
<div style="margin: 8px 0; padding: 0 12px;"><p style="padding: 0; margin: 8px;">You can still use<br />
connect(m_dirtyHandler, &QTimer::timeout, this, [this]() {slotAttemptReload();})</p></div></div><br /><div style="border: 1px solid #C7CCD9; border-radius: 3px;"><div style="padding: 0; background: #F7F7F7; border-color: #e3e4e8; border-style: solid; border-width: 0 0 1px 0; margin: 0;"><div style="color: #74777d; background: #eff2f4; padding: 6px 8px; overflow: hidden;"><a style="float: right; text-decoration: none;" href="https://phabricator.kde.org/D8642#inline-37893" rel="noreferrer">View Inline</a><span style="color: #4b4d51; font-weight: bold;">part.cpp:817</span></div>
<div style="font: 11px/15px "Menlo", "Consolas", "Monaco", monospace; white-space: pre-wrap; clear: both; padding: 4px 0; margin: 0;"><div style="padding: 0 8px; margin: 0 4px; background: rgba(251, 175, 175, .7);"> <span class="n">m_save<span class="bright">CopyAs</span></span> <span style="color: #aa2211">=</span> <span class="n">KStandardAction</span><span style="color: #aa2211">::</span><span class="n">save<span class="bright">As</span></span><span class="p">(</span> <span style="color: #aa4000">this</span><span class="p">,</span> <span class="n">SLOT</span><span class="p">(</span><span class="n">s<span class="bright">lotSaveCopyAs</span></span><span class="p">()),</span> <span class="n">ac</span> <span class="p">);</span>
</div><div style="padding: 0 8px; margin: 0 4px; background: rgba(251, 175, 175, .7);"> <span class="n">m_save<span class="bright">CopyAs</span></span><span style="color: #aa2211">-></span><span class="n">set<span class="bright">Text</span></span><span class="bright"></span><span class="p"><span class="bright">(</span></span><span class="bright"> </span><span class="n"><span class="bright">i18n</span></span><span class="bright"></span><span class="p"><span class="bright">(</span></span><span class="bright"> </span><span style="color: #766510"><span class="bright">"Save &Copy As..."</span></span><span class="bright"> </span><span class="p"><span class="bright">)</span></span> <span class="p">);</span>
</div><div style="padding: 0 8px; margin: 0 4px; background: rgba(251, 175, 175, .7);"> <span class="n">ac</span><span style="color: #aa2211">-></span><span class="n">addAction</span><span class="p">(</span> <span class="n">QStringLiteral</span><span class="p">(</span><span style="color: #766510">"file_save_copy"</span><span class="p">),</span> <span class="n">m_saveCopyAs</span> <span class="p">);</span>
</div><div style="padding: 0 8px; margin: 0 4px; background: rgba(251, 175, 175, .7);"> <span class="n">ac</span><span style="color: #aa2211">-></span><span class="n">setDefaultShortcuts</span><span class="p">(</span><span class="n">m_saveCopyAs</span><span class="p">,</span> <span class="n">KStandardShortcut</span><span style="color: #aa2211">::</span><span class="n">shortcut</span><span class="p">(</span><span class="n">KStandardShortcut</span><span style="color: #aa2211">::</span><span class="n">SaveAs</span><span class="p">));</span>
</div><div style="padding: 0 8px; margin: 0 4px; background: rgba(251, 175, 175, .7);"> <span class="n">m_saveCopyAs</span><span style="color: #aa2211">-></span><span class="n">setEnabled</span><span class="p">(</span> <span style="color: #304a96">false</span> <span class="p">);</span>
</div><div style="padding: 0 8px; margin: 0 4px; background: rgba(151, 234, 151, .6);"> <span class="n">m_save</span> <span style="color: #aa2211">=</span> <span class="n">KStandardAction</span><span style="color: #aa2211">::</span><span class="n">save</span><span class="p">(</span> <span style="color: #aa4000">this</span><span class="p">,</span> <span class="n">SLOT</span><span class="p">(</span><span class="n">s<span class="bright">aveFile</span></span><span class="p">()),</span> <span class="n">ac</span> <span class="p">);</span>
</div><div style="padding: 0 8px; margin: 0 4px; background: rgba(151, 234, 151, .6);"> <span class="n">m_save</span><span style="color: #aa2211">-></span><span class="n">set<span class="bright">Enabled</span></span><span class="bright"></span><span class="p"><span class="bright">(</span></span><span class="bright"> </span><span style="color: #304a96"><span class="bright">false</span></span> <span class="p">);</span>
</div></div></div>
<div style="margin: 8px 0; padding: 0 12px;"><p style="padding: 0; margin: 8px;">You can use new connect api too</p></div></div><br /><div style="border: 1px solid #C7CCD9; border-radius: 3px;"><div style="padding: 0; background: #F7F7F7; border-color: #e3e4e8; border-style: solid; border-width: 0 0 1px 0; margin: 0;"><div style="color: #74777d; background: #eff2f4; padding: 6px 8px; overflow: hidden;"><a style="float: right; text-decoration: none;" href="https://phabricator.kde.org/D8642#inline-37894" rel="noreferrer">View Inline</a><span style="color: #4b4d51; font-weight: bold;">part.cpp:2476</span></div>
<div style="font: 11px/15px "Menlo", "Consolas", "Monaco", monospace; white-space: pre-wrap; clear: both; padding: 4px 0; margin: 0;"><div style="padding: 0 8px; margin: 0 4px; background: rgba(251, 175, 175, .7);"> <span class="n">QS<span class="bright">tring</span></span><span class="bright"> </span><span class="n"><span class="bright">errorText</span></span><span class="p">;</span>
</div><div style="padding: 0 8px; margin: 0 4px; background: rgba(251, 175, 175, .7);"> <span class="bright"></span><span style="color: #aa4000"><span class="bright">bool</span></span><span class="bright"> </span><span class="n">save<span class="bright">d</span></span><span class="bright"></span><span class="p"><span class="bright">;</span></span>
</div><div style="padding: 0 8px; margin: 0 4px; background: rgba(151, 234, 151, .6);"> <span class="n">QS<span class="bright">copedPointer</span></span><span class="bright"></span><span style="color: #aa2211"><span class="bright"><</span></span><span class="bright"></span><span class="n"><span class="bright">QTemporaryFile</span></span><span class="bright"></span><span style="color: #aa2211"><span class="bright">></span></span><span class="bright"> </span><span class="n"><span class="bright">tempFile</span></span><span class="p">;</span>
</div><div style="padding: 0 8px; margin: 0 4px; background: rgba(151, 234, 151, .6);"> <span class="bright"></span><span class="n"><span class="bright">KIO</span></span><span class="bright"></span><span style="color: #aa2211"><span class="bright">::</span></span><span class="bright"></span><span class="n"><span class="bright">Job</span></span><span class="bright"> </span><span style="color: #aa2211"><span class="bright">*</span></span><span class="bright"></span><span class="n"><span class="bright">copyJob</span></span><span class="bright"></span><span class="p"><span class="bright">;</span></span><span class="bright"> </span><span style="color: #74777d"><span class="bright">// this will be filled with the job that writes to </span>save<span class="bright">Url</span></span>
</div></div></div>
<div style="margin: 8px 0; padding: 0 12px;"><p style="padding: 0; margin: 8px;">*copyJob = nullptr; to be sure that it's initialized</p></div></div><br /><div style="border: 1px solid #C7CCD9; border-radius: 3px;"><div style="padding: 0; background: #F7F7F7; border-color: #e3e4e8; border-style: solid; border-width: 0 0 1px 0; margin: 0;"><div style="color: #74777d; background: #eff2f4; padding: 6px 8px; overflow: hidden;"><a style="float: right; text-decoration: none;" href="https://phabricator.kde.org/D8642#inline-37895" rel="noreferrer">View Inline</a><span style="color: #4b4d51; font-weight: bold;">annotationmodel.cpp:113</span></div>
<div style="font: 11px/15px "Menlo", "Consolas", "Monaco", monospace; white-space: pre-wrap; clear: both; padding: 4px 0; margin: 0;"><div style="padding: 0 8px; margin: 0 4px; background: rgba(151, 234, 151, .6);"> <span style="color: #aa4000">if</span> <span class="p">(</span> <span style="color: #aa2211">!</span><span class="n">item</span><span style="color: #aa2211">-></span><span class="n">annotation</span> <span class="p">)</span>
</div><div style="padding: 0 8px; margin: 0 4px; background: rgba(151, 234, 151, .6);"> <span class="n">qWarning</span><span class="p">()</span> <span style="color: #aa2211"><<</span> <span style="color: #766510">"Lost annotation on document save, something went wrong"</span><span class="p">;</span>
</div><div style="padding: 0 8px; margin: 0 4px; background: rgba(151, 234, 151, .6);"> <span class="p">}</span>
</div></div></div>
<div style="margin: 8px 0; padding: 0 12px;"><p style="padding: 0; margin: 8px;">qCWarning(...)</p></div></div><br /><div style="border: 1px solid #C7CCD9; border-radius: 3px;"><div style="padding: 0; background: #F7F7F7; border-color: #e3e4e8; border-style: solid; border-width: 0 0 1px 0; margin: 0;"><div style="color: #74777d; background: #eff2f4; padding: 6px 8px; overflow: hidden;"><a style="float: right; text-decoration: none;" href="https://phabricator.kde.org/D8642#inline-37896" rel="noreferrer">View Inline</a><span style="color: #4b4d51; font-weight: bold;">formwidgets.cpp:89</span></div>
<div style="font: 11px/15px "Menlo", "Consolas", "Monaco", monospace; white-space: pre-wrap; clear: both; padding: 4px 0; margin: 0;"><div style="padding: 0 8px; margin: 0 4px; background: rgba(251, 175, 175, .7);"> <span class="bright"> </span><span style="color: #aa4000"><span class="bright">return</span></span><span class="bright"> </span><span style="color: #aa4000"><span class="bright">nullptr</span></span><span class="bright"></span><span class="p"><span class="bright">;</span></span>
</div><div style="padding: 0 8px; margin: 0 4px; background: rgba(151, 234, 151, .6);"> <span class="bright"></span><span class="p"><span class="bright">{</span></span>
</div><div style="padding: 0 8px; margin: 0 4px; background: rgba(151, 234, 151, .6);"> <span class="n">qWarning</span><span class="p">()</span> <span style="color: #aa2211"><<</span> <span style="color: #766510">"fwButton is not a QAbstractButton"</span> <span style="color: #aa2211"><<</span> <span class="n">fwButton</span><span class="p">;</span>
</div><div style="padding: 0 8px; margin: 0 4px; background: rgba(151, 234, 151, .6);"> <span style="color: #aa4000">return</span><span class="p">;</span>
</div></div></div>
<div style="margin: 8px 0; padding: 0 12px;"><p style="padding: 0; margin: 8px;">qCWarning(...)</p></div></div></div></div></div><br /><div><strong>REPOSITORY</strong><div><div>R223 Okular</div></div></div><br /><div><strong>REVISION DETAIL</strong><div><a href="https://phabricator.kde.org/D8642" rel="noreferrer">https://phabricator.kde.org/D8642</a></div></div><br /><div><strong>To: </strong>aacid, mlaurent<br /><strong>Cc: </strong>mlaurent, michaelweghorn, ngraham, Okular, aacid<br /></div>