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

List:       kde-utils-devel
Subject:    Re: Review Request 111315: Improved: Sort email addresses in main list by TLD first, then domain, an
From:       "Rolf Eike Beer" <kde () opensource ! sf-tec ! de>
Date:       2013-06-29 22:04:19
Message-ID: 20130629220419.32116.34395 () vidsolbach ! de
[Download RAW message or body]

[Attachment #2 (multipart/alternative)]


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
http://git.reviewboard.kde.org/r/111315/#review35293
-----------------------------------------------------------



model/keylistproxymodel.cpp
<http://git.reviewboard.kde.org/r/111315/#comment25851>

    Put these static vars before the switch so they will get created once and can be used in all \
branches.



model/keylistproxymodel.cpp
<http://git.reviewboard.kde.org/r/111315/#comment25852>

    Where does the www come from? That doesn't make sense. I think you should just remove the www from \
all following comments and everything is fine.



model/keylistproxymodel.cpp
<http://git.reviewboard.kde.org/r/111315/#comment25853>

    I was just thinking about this:
    
    const int cnt = fqdncomponents.count();
    for (i = 0; i < cnt / 2; i++)
      fqdncomponents.swap(i, cnt - 1 - i);
    result = fqdncomponents.join(domainSplitDot).toLower();
    
    No hard preference in any directotion, take whatever algorithm you like better.



model/keylistproxymodel.cpp
<http://git.reviewboard.kde.org/r/111315/#comment25854>

    What about putting those "reverse some list and join with dots" into a file-static helper function \
instead of open-coding it three times?


- Rolf Eike Beer


On June 29, 2013, 7:26 p.m., Thomas Fischer wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> http://git.reviewboard.kde.org/r/111315/
> -----------------------------------------------------------
> 
> (Updated June 29, 2013, 7:26 p.m.)
> 
> 
> Review request for KDE Utils.
> 
> 
> Description
> -------
> 
> Further improvements continuing the work started in review request 109847.
> 
> Addressing comments by Rolf Eike Beer (dakon):
> 
> > I wonder what happens to emails like foo.bar@example.com with TLDfirst, the
> > regex will split them into foo, bar, example, com AFAICT, which would screw
> > up sorting, no?
> I rewrote this case, should work better now, too.
> The patch contains some minor rewrites for the other cases as well plus some unifications in the white \
> spaces. 
> > For an unknown reason the items added in the ui file are ignored, they only 
> > appear when added again in C++.
> No idea either.
> 
> > When the setting is changed and Accept or OK is clicked keysmanager will not
> > refresh it's display. You should probably call something like invalidateFilter
> > on the filter model used for the main view.
> Observed as well. How do I trigger such a refresh/invalidation? The settings/options class do no see \
> the model (or the view) directly as far as I can see... 
> 
> Diffs
> -----
> 
> model/keylistproxymodel.cpp cecb836 
> 
> Diff: http://git.reviewboard.kde.org/r/111315/diff/
> 
> 
> Testing
> -------
> 
> 
> Thanks,
> 
> Thomas Fischer
> 
> 


[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="http://git.reviewboard.kde.org/r/111315/">http://git.reviewboard.kde.org/r/111315/</a>
     </td>
    </tr>
   </table>
   <br />











<div>




<table width="100%" border="0" bgcolor="white" style="border: 1px solid #C0C0C0; border-collapse: \
collapse; margin: 2px padding: 2px;">  <thead>
  <tr>
   <th colspan="4" bgcolor="#F0F0F0" style="border-bottom: 1px solid #C0C0C0; font-size: 9pt; padding: \
4px 8px; text-align: left;">  <a \
href="http://git.reviewboard.kde.org/r/111315/diff/1/?file=166786#file166786line72" style="color: black; \
font-weight: bold; text-decoration: underline;">model/keylistproxymodel.cpp</a>  <span \
style="font-weight: normal;">

     (Diff revision 1)

    </span>
   </th>
  </tr>
 </thead>

 <tbody style="background-color: #e4d9cb; padding: 4px 8px; text-align: center;">
  <tr>

   <td colspan="4"><pre style="font-size: 8pt; line-height: 140%; margin: 0; \
">KeyListProxyModelPrivate::reorderEmailComponents(const QString &amp;emailAddress) const</pre></td>

  </tr>
 </tbody>



 
 

 <tbody>

  <tr>
    <th bgcolor="#e9eaa8" style="border-right: 1px solid #C0C0C0;" align="right"><font \
size="2">72</font></th>  <td bgcolor="#fdfebc" width="50%"><pre style="font-size: 8pt; line-height: 140%; \
margin: 0; "><span class="tb">	</span><span class="tb">	</span><span class="k">static</span> <span \
class="k">const</span> <span class="n">Q<span class="hl">RegExp</span></span> <span \
class="n">emailSplit<span class="hl">RegExp</span></span><span class="p"><span \
class="hl">(</span></span><span class="n">QLatin1<span class="hl">String</span></span><span \
class="p"><span class="hl">(</span></span><span class="s"><span \
class="hl">&quot;[@.]&quot;</span></span><span class="p"><span class="hl">)</span>);</span></pre></td>  \
<th bgcolor="#e9eaa8" style="border-left: 1px solid #C0C0C0; border-right: 1px solid #C0C0C0;" \
align="right"><font size="2">72</font></th>  <td bgcolor="#fdfebc" width="50%"><pre style="font-size: \
8pt; line-height: 140%; margin: 0; "><span class="tb">	</span><span class="tb">	</span><span \
class="k">static</span> <span class="k">const</span> <span class="n">Q<span class="hl">Char</span></span> \
<span class="n">emailSplit<span class="hl">At</span></span><span class="hl"> </span><span class="o"><span \
class="hl">=</span></span><span class="hl"> </span><span class="n">QLatin1<span \
class="hl">Char</span></span><span class="p"><span class="hl">(</span></span><span class="sc"><span \
class="hl">&#39;@&#39;</span></span><span class="p">);</span></pre></td>  </tr>

 </tbody>


 
 

 <tbody>

  <tr>
    <th bgcolor="#b1ebb0" style="border-right: 1px solid #C0C0C0;" align="right"><font \
size="2"></font></th>  <td bgcolor="#c5ffc4" width="50%"><pre style="font-size: 8pt; line-height: 140%; \
margin: 0; "></pre></td>  <th bgcolor="#b1ebb0" style="border-left: 1px solid #C0C0C0; border-right: 1px \
solid #C0C0C0;" align="right"><font size="2">73</font></th>  <td bgcolor="#c5ffc4" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; "><span class="tb">	</span><span \
class="tb">	</span><span class="c1">/// split domain at .</span></pre></td>  </tr>

  <tr>
    <th bgcolor="#b1ebb0" style="border-right: 1px solid #C0C0C0;" align="right"><font \
size="2"></font></th>  <td bgcolor="#c5ffc4" width="50%"><pre style="font-size: 8pt; line-height: 140%; \
margin: 0; "></pre></td>  <th bgcolor="#b1ebb0" style="border-left: 1px solid #C0C0C0; border-right: 1px \
solid #C0C0C0;" align="right"><font size="2">74</font></th>  <td bgcolor="#c5ffc4" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; "><span class="tb">	</span><span \
class="tb">	</span><span class="k">static</span> <span class="k">const</span> <span \
class="n">QChar</span> <span class="n">domainSplitDot</span> <span class="o">=</span> <span \
class="n">QLatin1Char</span><span class="p">(</span><span class="sc">&#39;.&#39;</span><span \
class="p">);</span></pre></td>  </tr>

 </tbody>

</table>

<pre style="margin-left: 2em; white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; \
white-space: -o-pre-wrap; word-wrap: break-word;">Put these static vars before the switch so they will \
get created once and can be used in all branches.</pre> </div>
<br />

<div>




<table width="100%" border="0" bgcolor="white" style="border: 1px solid #C0C0C0; border-collapse: \
collapse; margin: 2px padding: 2px;">  <thead>
  <tr>
   <th colspan="4" bgcolor="#F0F0F0" style="border-bottom: 1px solid #C0C0C0; font-size: 9pt; padding: \
4px 8px; text-align: left;">  <a \
href="http://git.reviewboard.kde.org/r/111315/diff/1/?file=166786#file166786line76" style="color: black; \
font-weight: bold; text-decoration: underline;">model/keylistproxymodel.cpp</a>  <span \
style="font-weight: normal;">

     (Diff revision 1)

    </span>
   </th>
  </tr>
 </thead>

 <tbody style="background-color: #e4d9cb; padding: 4px 8px; text-align: center;">
  <tr>

   <td colspan="4"><pre style="font-size: 8pt; line-height: 140%; margin: 0; \
">KeyListProxyModelPrivate::reorderEmailComponents(const QString &amp;emailAddress) const</pre></td>

  </tr>
 </tbody>



 
 

 <tbody>

  <tr>
    <th bgcolor="#e9eaa8" style="border-right: 1px solid #C0C0C0;" align="right"><font \
size="2">74</font></th>  <td bgcolor="#fdfebc" width="50%"><pre style="font-size: 8pt; line-height: 140%; \
margin: 0; "><span class="tb">	</span><span class="tb">	</span><span class="c1">/// <span \
class="hl">exampl</span>e@kde.org becomes [<span class="hl">exampl</span>e, kde<span class="hl">, \
</span>org]</span></pre></td>  <th bgcolor="#e9eaa8" style="border-left: 1px solid #C0C0C0; border-right: \
1px solid #C0C0C0;" align="right"><font size="2">76</font></th>  <td bgcolor="#fdfebc" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; "><span class="tb">	</span><span \
class="tb">	</span><span class="c1">/// <span class="hl">john.do</span>e@kde.org becomes [<span \
class="hl">john.do</span>e, <span class="hl">www.</span>kde<span \
class="hl">.</span>org]</span></pre></td>  </tr>

 </tbody>

</table>

<pre style="margin-left: 2em; white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; \
white-space: -o-pre-wrap; word-wrap: break-word;">Where does the www come from? That doesn&#39;t make \
sense. I think you should just remove the www from all following comments and everything is fine.</pre> \
</div> <br />

<div>




<table width="100%" border="0" bgcolor="white" style="border: 1px solid #C0C0C0; border-collapse: \
collapse; margin: 2px padding: 2px;">  <thead>
  <tr>
   <th colspan="4" bgcolor="#F0F0F0" style="border-bottom: 1px solid #C0C0C0; font-size: 9pt; padding: \
4px 8px; text-align: left;">  <a \
href="http://git.reviewboard.kde.org/r/111315/diff/1/?file=166786#file166786line87" style="color: black; \
font-weight: bold; text-decoration: underline;">model/keylistproxymodel.cpp</a>  <span \
style="font-weight: normal;">

     (Diff revision 1)

    </span>
   </th>
  </tr>
 </thead>

 <tbody style="background-color: #e4d9cb; padding: 4px 8px; text-align: center;">
  <tr>

   <td colspan="4"><pre style="font-size: 8pt; line-height: 140%; margin: 0; \
">KeyListProxyModelPrivate::reorderEmailComponents(const QString &amp;emailAddress) const</pre></td>

  </tr>
 </tbody>



 
 

 <tbody>

  <tr>
    <th bgcolor="#b1ebb0" style="border-right: 1px solid #C0C0C0;" align="right"><font \
size="2"></font></th>  <td bgcolor="#c5ffc4" width="50%"><pre style="font-size: 8pt; line-height: 140%; \
margin: 0; "></pre></td>  <th bgcolor="#b1ebb0" style="border-left: 1px solid #C0C0C0; border-right: 1px \
solid #C0C0C0;" align="right"><font size="2">87</font></th>  <td bgcolor="#c5ffc4" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; "><span class="tb">	</span><span \
class="tb">	</span><span class="n">QString</span> <span class="n">result</span> <span class="o">=</span> \
<span class="n">fqdnComponents</span><span class="p">[</span><span class="n">fqdnComponents</span><span \
class="p">.</span><span class="n">count</span><span class="p">()</span> <span class="o">-</span> <span \
class="mi">1</span><span class="p">];</span></pre></td>  </tr>

  <tr>
    <th bgcolor="#b1ebb0" style="border-right: 1px solid #C0C0C0;" align="right"><font \
size="2"></font></th>  <td bgcolor="#c5ffc4" width="50%"><pre style="font-size: 8pt; line-height: 140%; \
margin: 0; "></pre></td>  <th bgcolor="#b1ebb0" style="border-left: 1px solid #C0C0C0; border-right: 1px \
solid #C0C0C0;" align="right"><font size="2">88</font></th>  <td bgcolor="#c5ffc4" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; "><span class="tb">	</span><span \
class="tb">	</span><span class="k">for</span> <span class="p">(</span><span class="kt">int</span> <span \
class="n">i</span> <span class="o">=</span> <span class="n">fqdnComponents</span><span \
class="p">.</span><span class="n">count</span><span class="p">()</span> <span class="o">-</span> <span \
class="mi">2</span><span class="p">;</span> <span class="n">i</span> <span class="o">&gt;=</span> <span \
class="mi">0</span><span class="p">;</span> <span class="o">--</span><span class="n">i</span><span \
class="p">)</span></pre></td>  </tr>

  <tr>
    <th bgcolor="#b1ebb0" style="border-right: 1px solid #C0C0C0;" align="right"><font \
size="2"></font></th>  <td bgcolor="#c5ffc4" width="50%"><pre style="font-size: 8pt; line-height: 140%; \
margin: 0; "></pre></td>  <th bgcolor="#b1ebb0" style="border-left: 1px solid #C0C0C0; border-right: 1px \
solid #C0C0C0;" align="right"><font size="2">89</font></th>  <td bgcolor="#c5ffc4" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; "><span class="tb">	</span><span \
class="tb">	</span><span class="tb">	</span><span class="n">result</span> <span class="o">=</span> <span \
class="n">result</span><span class="p">.</span><span class="n">append</span><span class="p">(</span><span \
class="n">domainSplitDot</span> <span class="o">+</span> <span class="n">fqdnComponents</span><span \
class="p">[</span><span class="n">i</span><span class="p">]);</span></pre></td>  </tr>

  <tr>
    <th bgcolor="#b1ebb0" style="border-right: 1px solid #C0C0C0;" align="right"><font \
size="2"></font></th>  <td bgcolor="#c5ffc4" width="50%"><pre style="font-size: 8pt; line-height: 140%; \
margin: 0; "></pre></td>  <th bgcolor="#b1ebb0" style="border-left: 1px solid #C0C0C0; border-right: 1px \
solid #C0C0C0;" align="right"><font size="2">90</font></th>  <td bgcolor="#c5ffc4" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; "><span class="tb">	</span><span \
class="tb">	</span><span class="c1">/// append user name component of email address, becomes e.g. \
org.kde.www.john.doe</span></pre></td>  </tr>

  <tr>
    <th bgcolor="#b1ebb0" style="border-right: 1px solid #C0C0C0;" align="right"><font \
size="2"></font></th>  <td bgcolor="#c5ffc4" width="50%"><pre style="font-size: 8pt; line-height: 140%; \
margin: 0; "></pre></td>  <th bgcolor="#b1ebb0" style="border-left: 1px solid #C0C0C0; border-right: 1px \
solid #C0C0C0;" align="right"><font size="2">91</font></th>  <td bgcolor="#c5ffc4" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; "><span class="tb">	</span><span \
class="tb">	</span><span class="n">result</span> <span class="o">=</span> <span \
class="n">result</span><span class="p">.</span><span class="n">append</span><span class="p">(</span><span \
class="n">domainSplitDot</span> <span class="o">+</span> <span class="n">emailComponents</span><span \
class="p">.</span><span class="n">first</span><span class="p">());</span></pre></td>  </tr>

 </tbody>


 
 

 <tbody>

  <tr>
    <th bgcolor="#f0f0f0" style="border-right: 1px solid #C0C0C0;" align="right"><font \
size="2">81</font></th>  <td bgcolor="#ffffff" width="50%"><pre style="font-size: 8pt; line-height: 140%; \
margin: 0; "><span class="tb">	</span><span class="tb">	</span><span class="c1">/// convert result to \
lower case to make sorting case-insensitive</span></pre></td>  <th bgcolor="#f0f0f0" style="border-left: \
1px solid #C0C0C0; border-right: 1px solid #C0C0C0;" align="right"><font size="2">92</font></th>  <td \
bgcolor="#ffffff" width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; "><span \
class="tb">	</span><span class="tb">	</span><span class="c1">/// convert result to lower case to make \
sorting case-insensitive</span></pre></td>  </tr>

  <tr>
    <th bgcolor="#f0f0f0" style="border-right: 1px solid #C0C0C0;" align="right"><font \
size="2">82</font></th>  <td bgcolor="#ffffff" width="50%"><pre style="font-size: 8pt; line-height: 140%; \
margin: 0; "><span class="tb">	</span><span class="tb">	</span><span class="k">return</span> <span \
class="n">result</span><span class="p">.</span><span class="n">toLower</span><span \
class="p">();</span></pre></td>  <th bgcolor="#f0f0f0" style="border-left: 1px solid #C0C0C0; \
border-right: 1px solid #C0C0C0;" align="right"><font size="2">93</font></th>  <td bgcolor="#ffffff" \
width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; "><span class="tb">	</span><span \
class="tb">	</span><span class="k">return</span> <span class="n">result</span><span \
class="p">.</span><span class="n">toLower</span><span class="p">();</span></pre></td>  </tr>

 </tbody>

</table>

<pre style="margin-left: 2em; white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; \
white-space: -o-pre-wrap; word-wrap: break-word;">I was just thinking about this:

const int cnt = fqdncomponents.count();
for (i = 0; i &lt; cnt / 2; i++)
  fqdncomponents.swap(i, cnt - 1 - i);
result = fqdncomponents.join(domainSplitDot).toLower();

No hard preference in any directotion, take whatever algorithm you like better.</pre>
</div>
<br />

<div>




<table width="100%" border="0" bgcolor="white" style="border: 1px solid #C0C0C0; border-collapse: \
collapse; margin: 2px padding: 2px;">  <thead>
  <tr>
   <th colspan="4" bgcolor="#F0F0F0" style="border-bottom: 1px solid #C0C0C0; font-size: 9pt; padding: \
4px 8px; text-align: left;">  <a \
href="http://git.reviewboard.kde.org/r/111315/diff/1/?file=166786#file166786line116" style="color: black; \
font-weight: bold; text-decoration: underline;">model/keylistproxymodel.cpp</a>  <span \
style="font-weight: normal;">

     (Diff revision 1)

    </span>
   </th>
  </tr>
 </thead>

 <tbody style="background-color: #e4d9cb; padding: 4px 8px; text-align: center;">
  <tr>

   <td colspan="4"><pre style="font-size: 8pt; line-height: 140%; margin: 0; \
">KeyListProxyModelPrivate::reorderEmailComponents(const QString &amp;emailAddress) const</pre></td>

  </tr>
 </tbody>



 
 

 <tbody>

  <tr>
    <th bgcolor="#f0f0f0" style="border-right: 1px solid #C0C0C0;" align="right"><font \
size="2">104</font></th>  <td bgcolor="#ffffff" width="50%"><pre style="font-size: 8pt; line-height: \
140%; margin: 0; "><span class="tb">	</span><span class="tb">	</span><span class="k">for</span> <span \
class="p">(</span><span class="kt">int</span> <span class="n">i</span> <span class="o">=</span> <span \
class="mi">0</span><span class="p">;</span> <span class="n">i</span> <span class="o">&lt;</span> <span \
class="n">fqdnComponents</span><span class="p">.</span><span class="n">count</span><span \
class="p">()</span> <span class="o">-</span> <span class="mi">2</span><span class="p">;</span> <span \
class="o">++</span><span class="n">i</span><span class="p">)</span></pre></td>  <th bgcolor="#f0f0f0" \
style="border-left: 1px solid #C0C0C0; border-right: 1px solid #C0C0C0;" align="right"><font \
size="2">116</font></th>  <td bgcolor="#ffffff" width="50%"><pre style="font-size: 8pt; line-height: \
140%; margin: 0; "><span class="tb">	</span><span class="tb">	</span><span class="k">for</span> <span \
class="p">(</span><span class="kt">int</span> <span class="n">i</span> <span class="o">=</span> <span \
class="mi">0</span><span class="p">;</span> <span class="n">i</span> <span class="o">&lt;</span> <span \
class="n">fqdnComponents</span><span class="p">.</span><span class="n">count</span><span \
class="p">()</span> <span class="o">-</span> <span class="mi">2</span><span class="p">;</span> <span \
class="o">++</span><span class="n">i</span><span class="p">)</span></pre></td>  </tr>

 </tbody>


 
 

 <tbody>

  <tr>
    <th bgcolor="#e9eaa8" style="border-right: 1px solid #C0C0C0;" align="right"><font \
size="2">105</font></th>  <td bgcolor="#fdfebc" width="50%"><pre style="font-size: 8pt; line-height: \
140%; margin: 0; "><span class="tb">	</span><span class="tb">	</span><span class="tb">	</span><span \
class="n">result</span> <span class="o">=</span> <span class="n">result</span><span \
class="p">.</span><span class="n">append</span><span class="p">(</span><span \
class="n">domainSplitDot</span><span class="hl"> </span><span class="o"><span \
class="hl">+</span></span><span class="hl"> </span><span class="n">fqdnComponents</span><span \
class="p">[</span><span class="n">i</span><span class="p">]);</span></pre></td>  <th bgcolor="#e9eaa8" \
style="border-left: 1px solid #C0C0C0; border-right: 1px solid #C0C0C0;" align="right"><font \
size="2">117</font></th>  <td bgcolor="#fdfebc" width="50%"><pre style="font-size: 8pt; line-height: \
140%; margin: 0; "><span class="tb">	</span><span class="tb">	</span><span class="tb">	</span><span \
class="n">result</span> <span class="o">=</span> <span class="n">result</span><span \
class="p">.</span><span class="n">append</span><span class="p">(</span><span \
class="n">domainSplitDot</span><span class="p"><span class="hl">).</span></span><span class="n"><span \
class="hl">append</span></span><span class="p"><span class="hl">(</span></span><span \
class="n">fqdnComponents</span><span class="p">[</span><span class="n">i</span><span \
class="p">]);</span></pre></td>  </tr>

  <tr>
    <th bgcolor="#e9eaa8" style="border-right: 1px solid #C0C0C0;" align="right"><font \
size="2">106</font></th>  <td bgcolor="#fdfebc" width="50%"><pre style="font-size: 8pt; line-height: \
140%; margin: 0; "><span class="tb">	</span><span class="tb">	</span><span class="c1">/// append user \
name component of email address, becomes e.g. kde.org.www.<span \
class="hl">example</span></span></pre></td>  <th bgcolor="#e9eaa8" style="border-left: 1px solid #C0C0C0; \
border-right: 1px solid #C0C0C0;" align="right"><font size="2">118</font></th>  <td bgcolor="#fdfebc" \
width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; "><span class="tb">	</span><span \
class="tb">	</span><span class="c1">/// append user name component of email address, becomes e.g. \
kde.org.www.<span class="hl">john.doe</span></span></pre></td>  </tr>

 </tbody>


 
 

 <tbody>

  <tr>
    <th bgcolor="#f0f0f0" style="border-right: 1px solid #C0C0C0;" align="right"><font \
size="2">107</font></th>  <td bgcolor="#ffffff" width="50%"><pre style="font-size: 8pt; line-height: \
140%; margin: 0; "><span class="tb">	</span><span class="tb">	</span><span class="n">result</span> <span \
class="o">=</span> <span class="n">result</span><span class="p">.</span><span \
class="n">append</span><span class="p">(</span><span class="n">domainSplitDot</span> <span \
class="o">+</span> <span class="n">emailComponents</span><span class="p">.</span><span \
class="n">first</span><span class="p">());</span></pre></td>  <th bgcolor="#f0f0f0" style="border-left: \
1px solid #C0C0C0; border-right: 1px solid #C0C0C0;" align="right"><font size="2">119</font></th>  <td \
bgcolor="#ffffff" width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; "><span \
class="tb">	</span><span class="tb">	</span><span class="n">result</span> <span class="o">=</span> <span \
class="n">result</span><span class="p">.</span><span class="n">append</span><span class="p">(</span><span \
class="n">domainSplitDot</span> <span class="o">+</span> <span class="n">emailComponents</span><span \
class="p">.</span><span class="n">first</span><span class="p">());</span></pre></td>  </tr>

 </tbody>

</table>

<pre style="margin-left: 2em; white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; \
white-space: -o-pre-wrap; word-wrap: break-word;">What about putting those &quot;reverse some list and \
join with dots&quot; into a file-static helper function instead of open-coding it three times?</pre> \
</div> <br />



<p>- Rolf Eike</p>


<br />
<p>On June 29th, 2013, 7:26 p.m. UTC, Thomas Fischer wrote:</p>








<table bgcolor="#fefadf" width="100%" cellspacing="0" cellpadding="8" style="background-image: \
url('http://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 Utils.</div>
<div>By Thomas Fischer.</div>


<p style="color: grey;"><i>Updated June 29, 2013, 7:26 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;">Further improvements continuing the work \
started in review request 109847.

Addressing comments by Rolf Eike Beer (dakon):

&gt; I wonder what happens to emails like foo.bar@example.com with TLDfirst, the
&gt; regex will split them into foo, bar, example, com AFAICT, which would screw
&gt; up sorting, no?
I rewrote this case, should work better now, too.
The patch contains some minor rewrites for the other cases as well plus some unifications in the white \
spaces.

&gt; For an unknown reason the items added in the ui file are ignored, they only 
&gt; appear when added again in C++.
No idea either.

&gt; When the setting is changed and Accept or OK is clicked keysmanager will not
&gt; refresh it&#39;s display. You should probably call something like invalidateFilter
&gt; on the filter model used for the main view.
Observed as well. How do I trigger such a refresh/invalidation? The settings/options class do no see the \
model (or the view) directly as far as I can see...</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>model/keylistproxymodel.cpp <span style="color: grey">(cecb836)</span></li>

</ul>

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







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








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



_______________________________________________
Kde-utils-devel mailing list
Kde-utils-devel@kde.org
https://mail.kde.org/mailman/listinfo/kde-utils-devel


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

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