<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="http://git.reviewboard.kde.org/r/102149/">http://git.reviewboard.kde.org/r/102149/</a>
</td>
</tr>
</table>
<br />
<blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: 10px;">
<p style="margin-top: 0;">On August 9th, 2011, 9:40 a.m., <b>David Faure</b> wrote:</p>
<blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: 10px;">
<pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">What I don't like about a single button, is that it creates a race.
The calculation takes too long, you want to abort it. You click on the button, and half a second before, the calculation actually ended. So your click triggers a "Calculate" again, and the annoying calculation that you wanted to stop, is starting again. It can be stopped a second time of course, but this still makes for an annoying user experience.</pre>
</blockquote>
<p>On August 9th, 2011, 10:46 a.m., <b>Thomas Lübking</b> wrote:</p>
<blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: 10px;">
<pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">Simple solution: disarm (or just disable) the button for about a second after the calculation has ended, ie. clicking the button leads to no action (should be fine since recalculating after a second has no point?)
Ideally the mousebuttonpress event would be eaten but the button doesn't "look" disabled.
(click -> click failed -> click again)
Just disconnecting from the slot for that timeframe is suboptimal, since the function might appear to be broken (click -> push -> nothing happens?)
Setting it disabled serves that functionality but causes visual flicker and raises the question why the button was disabled.
You could install an eventfilter to return true on mousepress/release events on the button and remove it from a timerevent or singleshot timer (just QTimer::singleShot() should be fine as well if you can ensure that you won't run two of them at once)</pre>
</blockquote>
<p>On August 9th, 2011, 11:26 a.m., <b>Christoph Feck</b> wrote:</p>
<blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: 10px;">
<pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">"Calculating..."
(time goes on)
"Calculation Done"
(clicking has no effect, then about 2 seconds later)
"Refresh"</pre>
</blockquote>
</blockquote>
<pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">Kai, did you have time yet to address the comments?</pre>
<br />
<p>- Christoph</p>
<br />
<p>On July 30th, 2011, 2:51 p.m., Kai Uwe Broulik wrote:</p>
<table bgcolor="#fefadf" width="100%" cellspacing="0" cellpadding="8" style="background-image: url('http://git.reviewboard.kde.org/media/rb/images/review_request_box_top_bg.png'); background-position: left top; background-repeat: repeat-x; border: 1px black solid;">
<tr>
<td>
<div>Review request for kdelibs.</div>
<div>By Kai Uwe Broulik.</div>
<p style="color: grey;"><i>Updated July 30, 2011, 2:51 p.m.</i></p>
<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 patch improves the Calculate and Stop buttons in folder properties.
Instead of having two buttons that are enabled/disabled accordingly, we only have one that toggles (technically there are still two buttons but it looks as if there was one)
I removed that "Calculating..." label when there is already a size shown, instead the stop button says "Stop Calculating" and somehow serves as "indicator".
Also, I added a line-break after the "Calculating..." so the label doesn't change its size making the other elements moving around.
I don't know if the additional icons (view-refresh and process-cancel) add too much clutter to the visual interface since this features is not sooo important/frequently used(?) that the buttons need an icon.</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;">Compiles and the buttons toggle (and react) fine.</pre>
</td>
</tr>
</table>
<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Diffs</b> </h1>
<ul style="margin-left: 3em; padding-left: 0;">
<li>kio/kfile/kpropertiesdialog.cpp <span style="color: grey">(ba56f18)</span></li>
</ul>
<p><a href="http://git.reviewboard.kde.org/r/102149/diff/" style="margin-left: 3em;">View Diff</a></p>
<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Screenshots </h1>
<div>
<a href="http://git.reviewboard.kde.org/r/102149/s/213/"><img src="http://git.reviewboard.kde.org/media/uploaded/images/2011/07/30/48_PROPERTIESDIALOG_400x100.png" style="border: 1px black solid;" alt="Screenshot of the dialog while it is calculating" /></a>
</div>
</td>
</tr>
</table>
</div>
</body>
</html>