[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kwrite-devel
Subject:    Re: Review Request 118312: Do not reset the model without need
From:       "Dominik Haumann" <dhaumann () kde ! org>
Date:       2014-06-04 11:20:57
Message-ID: 20140604112057.16449.27863 () probe ! kde ! org
[Download RAW message or body]

[Attachment #2 (multipart/alternative)]


> On June 2, 2014, 7:42 a.m., Dominik Haumann wrote:
> > These changes were introduced by review request \
> > https://git.reviewboard.kde.org/r/114770/ 
> > In short: Yes, this is about reducing model updates in the view. However, I think \
> > it's obvious that you don't want a model reset if you just open a single file. So \
> > there are several solutions: 
> > 1. Just drop the calls of beginResetModel() and endResetModel(). Then, we're \
> > pretty much back to where we were before. That would be ok, as it works. 2. Only \
> > call beginResetModel() and endResetModel() if docs.size() > 10 (or 50, or...) 
> > Michal, since you initially optimized this, what do you think about 2. ?

Can we get a review here again and add this for 4.13.2, which is tagged tomorrow?


- Dominik


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://git.reviewboard.kde.org/r/118312/#review58921
-----------------------------------------------------------


On May 25, 2014, 9:57 a.m., Albert Astals Cid wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://git.reviewboard.kde.org/r/118312/
> -----------------------------------------------------------
> 
> (Updated May 25, 2014, 9:57 a.m.)
> 
> 
> Review request for Kate and Michal Humpula.
> 
> 
> Bugs: 332990
> http://bugs.kde.org/show_bug.cgi?id=332990
> 
> 
> Repository: kate
> 
> 
> Description
> -------
> 
> From reading the code i see no need to reset the model, the only think that i see \
> the reset do is cause the view to "reset" too and the state of open/closed roots in \
> the tree gets broken. 
> 
> Diffs
> -----
> 
> kate/filetree/katefiletreemodel.cpp 62e39e5 
> 
> Diff: https://git.reviewboard.kde.org/r/118312/diff/
> 
> 
> Testing
> -------
> 
> Used it for a few minutes and everything worked fine. Reading the code don't see \
> why it shouldn't. I'll it use it a bit more for a few more days. 
> 
> Thanks,
> 
> Albert Astals Cid
> 
> 


[Attachment #5 (text/html)]

<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/118312/">https://git.reviewboard.kde.org/r/118312/</a>
  </td>
    </tr>
   </table>
   <br />





<blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: \
10px;">  <p style="margin-top: 0;">On June 2nd, 2014, 7:42 a.m. UTC, <b>Dominik \
Haumann</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;">These changes were introduced by review request \
https://git.reviewboard.kde.org/r/114770/

In short: Yes, this is about reducing model updates in the view. However, I think \
it&#39;s obvious that you don&#39;t want a model reset if you just open a single \
file. So there are several solutions:

1. Just drop the calls of beginResetModel() and endResetModel(). Then, we&#39;re \
pretty much back to where we were before. That would be ok, as it works. 2. Only call \
beginResetModel() and endResetModel() if docs.size() &gt; 10 (or 50, or...)

Michal, since you initially optimized this, what do you think about 2. ?</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;">Can we get a review here \
again and add this for 4.13.2, which is tagged tomorrow?</pre> <br />










<p>- Dominik</p>


<br />
<p>On May 25th, 2014, 9:57 a.m. UTC, Albert Astals Cid wrote:</p>








<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 Kate and Michal Humpula.</div>
<div>By Albert Astals Cid.</div>


<p style="color: grey;"><i>Updated May 25, 2014, 9:57 a.m.</i></p>







<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=332990">332990</a>


</div>



<div style="margin-top: 1.5em;">
 <b style="color: #575012; font-size: 10pt;">Repository: </b>
kate
</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;">From reading the code i see no need to reset the model, the only think \
that i see the reset do is cause the view to &quot;reset&quot; too and the state of \
open/closed roots in the tree gets broken.</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;">Used it for a few minutes and everything worked fine. Reading the code \
don&#39;t see why it shouldn&#39;t. I&#39;ll it use it a bit more for a few more \
days.</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>kate/filetree/katefiletreemodel.cpp <span style="color: \
grey">(62e39e5)</span></li>

</ul>

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







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








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



_______________________________________________
KWrite-Devel mailing list
KWrite-Devel@kde.org
https://mail.kde.org/mailman/listinfo/kwrite-devel


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic