<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
  <meta content="text/html; charset=ISO-8859-1"
 http-equiv="Content-Type">
  <title></title>
</head>
<body bgcolor="#ffffff" text="#000000">
On 2010-08-05 20:43, Ralf Engels wrote:
<blockquote cite="mid:1281033802.12249.4.camel@pc02" type="cite">
  <pre wrap="">It seems like I found the reason for at least some of the effects in
<a class="moz-txt-link-freetext" href="https://bugs.kde.org/show_bug.cgi?id=172542">https://bugs.kde.org/show_bug.cgi?id=172542</a>

After handling the row moved signal in GroupingProxy everything seems to
work.

Here is the diff. It would be nice if somebody would integrate it.
  </pre>
</blockquote>
<br>
----<br>
A) +1 for this patch, it seems OK.<br>
<br>
<br>
----<br>
B) Mystery #1:<br>
<br>
That 'rowsMoved' QAbstractItemModel signal is new in Qt 4.6. <br>
<br>
It's a somewhat-non-backward-compatible API change by Qt. By itself, it
would break Qt 4.5-and-earlier QAbstractItemModel-based code.<br>
<br>
To work around that API breakage, Qt decided to also emit a
'layoutChanged' with every 'rowsMoved' signal. From Qt's documentation:<br>
<blockquote>
  <h3 class="fn">void QAbstractItemModel::endMoveRows ()<tt></tt></h3>
[...]<br>
layoutChanged is emitted by this method for compatibility reasons.
  <p>This function was introduced in Qt 4.6.</p>
</blockquote>
<br>
GroupingProxy already properly handles the 'layoutChanged' signal.<br>
<br>
So, riddle: why didn't that fallback mechanism work the way Qt planned
it?<br>
<br>
<br>
----<br>
C) Mystery #2: The linked bug report is about the Collection Browser.
This patch is for the Playlist.<br>
<br>
To the best of my knowledge these two parts of Amarok have almost
nothing to do with each other.<br>
<br>
??<br>
<br>
<br>
----<br>
D) I won't commit the patch; lost my access in the recent git rehosting.<br>
<br>
(I'm semi-retired from Amarok due to differences over the bugfixing
culture, but that's a different discussion)<br>
<br>
<br>
&nbsp;&nbsp;&nbsp; Regards,<br>
&nbsp;&nbsp;&nbsp; Nanno<br>
<br>
</body>
</html>