<html>
 <body>
  <div style="font-family: Verdana, Arial, Helvetica, Sans-Serif;">
   <table bgcolor="#f9f3c9" width="100%" cellpadding="8" style="border: 1px #c9c399 solid;">
    <tr>
     <td>
      This is an automatically generated e-mail. To reply, visit:
      <a href="https://git.reviewboard.kde.org/r/118894/">https://git.reviewboard.kde.org/r/118894/</a>
     </td>
    </tr>
   </table>
   <br />




<table bgcolor="#fefadf" width="100%" cellspacing="0" cellpadding="8" style="background-image: url('https://git.reviewboard.kde.org/static/rb/images/review_request_box_top_bg.ab6f3b1072c9.png'); background-position: left top; background-repeat: repeat-x; border: 1px black solid;">
 <tr>
  <td>

<div>Review request for KDE Edu.</div>
<div>By Andreas Xavier.</div>


<p style="color: grey;"><i>Updated June 23, 2014, 8 a.m.</i></p>



<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Changes</h1>
<table width="100%" bgcolor="#ffffff" cellspacing="0" cellpadding="10" style="border: 1px solid #b8b5a0">
 <tr>
  <td>
   <pre style="margin: 0; padding: 0; white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">This fixes the bug mentioned under New bug.  
m_backupTimer was deallocated before it was used.

This refactors the switch statements into easier to read ifs with a trailing success/failure block.

This adds a comment to explain that defaultDocument() preserves the parleydocument object's promise to provide a good document().  i.e. when the user chose not to steal the lock several widgets were assuming that the open was successful and using the non-existent document.</pre>
  </td>
 </tr>
</table>





<div style="margin-top: 1.5em;">
 <b style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Bugs: </b>


 <a href="http://bugs.kde.org/show_bug.cgi?id=240552">240552</a>


</div>



<div style="margin-top: 1.5em;">
 <b style="color: #575012; font-size: 10pt;">Repository: </b>
parley
</div>


<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Description </h1>
 <table width="100%" bgcolor="#ffffff" cellspacing="0" cellpadding="10" style="border: 1px solid #b8b5a0">
 <tr>
  <td>
   <pre style="margin: 0; padding: 0; white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">This fixes the parley portions of the bug and is intended to work with https://git.reviewboard.kde.org/r/118686/

This patch introduces new strings before the string freeze and new functionality. The libkdeedu portion of the patch implements file locking, to prevent the data lose mentioned in the bug.  The new functionality in this patch is to allow the user to steal the lock.

The functionality is simple.  When the user tries to open a locked file a dialog pops up to explain the file lock, warn about data loss and ask the user if they wish to steal the lock.  If the user steals the lock, then the behavior is similar to before and the user will lose data if there are actually two processes running simultaneously.


New Bug:  There is a new bug.  On exit there is an intermittent crash.  I will fix this bug after the string freeze.  I think that it is caused by a change in the order of the teardown introduced by the new code.  

 </pre>
  </td>
 </tr>
</table>


<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Testing </h1>
<table width="100%" bgcolor="#ffffff" cellspacing="0" cellpadding="10" style="border: 1px solid #b8b5a0">
 <tr>
  <td>
   <pre style="margin: 0; padding: 0; white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">It was difficult to create unittests as the gui functionality is split between parleydocument and mainwindow, so it is difficult to instrument.

I ran by hand 2 to 3 parley practice sessions.  I checked the xml file to determine if there was data loss.

There was never data loss if I didn't steal the lock.

Stealing the lock results in data loss when:
 - autosave is enabled
 - save on exit is enabled
 - the user saves the 2nd process after the 1st parley have closed the vocabulary.

All of these cases are better than the current version, as the user is notified that you will lose data if you steal the lock.</pre>
  </td>
 </tr>
</table>


<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Diffs</b> (updated)</h1>
<ul style="margin-left: 3em; padding-left: 0;">

 <li>src/parleydocument.h <span style="color: grey">(e3c099f)</span></li>

 <li>src/parleydocument.cpp <span style="color: grey">(1681a93)</span></li>

 <li>src/parleymainwindow.cpp <span style="color: grey">(db8b5a8)</span></li>

</ul>

<p><a href="https://git.reviewboard.kde.org/r/118894/diff/" style="margin-left: 3em;">View Diff</a></p>







  </td>
 </tr>
</table>




  </div>
 </body>
</html>