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

List:       kde-panel-devel
Subject:    Re: Review Request: load the images for the themes correctly
From:       "Giorgos Tsiapaliokas" <terietor () gmail ! com>
Date:       2012-12-07 17:56:49
Message-ID: 20121207175649.2128.22816 () vidsolbach ! de
[Download RAW message or body]

[Attachment #2 (multipart/alternative)]


> On Nov. 29, 2012, 1:53 p.m., Aaron J. Seigo wrote:
> > plasmate/packagemodel.cpp, lines 196-205
> > <http://git.reviewboard.kde.org/r/106680/diff/5/?file=93807#file93807line196>
> > 
> > why not add "images", "config" and "animations" to m_themeImageDialogOptions and \
> > rename it to m_dialogOptions

I have put  "images" and "config" into the hash, but how can it be done for \
"animations" too?

> else if(!qstrcmp(key, "animations") && packageType() != "Plasma/Theme")
we check the key and the packageType, so we can't use the hash here. No?


> On Nov. 29, 2012, 1:53 p.m., Aaron J. Seigo wrote:
> > plasmate/packagemodel.cpp, line 544
> > <http://git.reviewboard.kde.org/r/106680/diff/5/?file=93807#file93807line544>
> > 
> > "Plasma/Theme" should not appear in this file.

the "colors" file isn't a requiredDirectory nor a requiredFile, so If I don't add it \
by hand in the m_topEntries it won't be visible and also we want the "colors" file in \
the m_topEntries only when the package is a theme. No? What am I missing?


- Giorgos


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


On Nov. 5, 2012, 5:51 p.m., Giorgos Tsiapaliokas wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> http://git.reviewboard.kde.org/r/106680/
> -----------------------------------------------------------
> 
> (Updated Nov. 5, 2012, 5:51 p.m.)
> 
> 
> Review request for Plasma.
> 
> 
> Description
> -------
> 
> create a new theme package->click on the new
> 
> a file dialog should appear but instead a simple edit box appears requesting a new \
> filename. 
> This patch solves the issue
> 
> 
> Diffs
> -----
> 
> plasmate/editors/editpage.h 5cb3ea6 
> plasmate/editors/editpage.cpp 7e82ff2 
> plasmate/packagemodel.h efa3001 
> plasmate/packagemodel.cpp 9eb0914 
> 
> Diff: http://git.reviewboard.kde.org/r/106680/diff/
> 
> 
> Testing
> -------
> 
> 
> Thanks,
> 
> Giorgos Tsiapaliokas
> 
> 


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








<blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: \
10px;">  <p style="margin-top: 0;">On November 29th, 2012, 1:53 p.m., <b>Aaron J. \
Seigo</b> wrote:</p>  <blockquote style="margin-left: 1em; border-left: 2px solid \
#d0d0d0; padding-left: 10px;">  



<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/106680/diff/5/?file=93807#file93807line196" \
style="color: black; font-weight: bold; text-decoration: \
underline;">plasmate/packagemodel.cpp</a>  <span style="font-weight: normal;">

     (Diff revision 5)

    </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; \
">QVariant PackageModel::data(const QModelIndex &amp;index, int role) \
const</pre></td>

  </tr>
 </tbody>






 
 

 <tbody>

  <tr>
    <th bgcolor="#f0f0f0" style="border-right: 1px solid #C0C0C0;" \
align="right"><font size="2">184</font></th>  <td bgcolor="#ffffff" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; ">                <span \
class="k">if</span> <span class="p">(</span><span class="o">!</span><span \
class="n">qstrcmp</span><span class="p">(</span><span class="n">key</span><span \
class="p">,</span> <span class="s">&quot;images&quot;</span><span class="p">))</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">196</font></th>  <td bgcolor="#ffffff" width="50%"><pre style="font-size: \
8pt; line-height: 140%; margin: 0; ">                <span class="k">if</span> <span \
class="p">(</span><span class="o">!</span><span class="n">qstrcmp</span><span \
class="p">(</span><span class="n">key</span><span class="p">,</span> <span \
class="s">&quot;images&quot;</span><span class="p">))</span> <span \
class="p">{</span></pre></td>  </tr>

  <tr>
    <th bgcolor="#f0f0f0" style="border-right: 1px solid #C0C0C0;" \
align="right"><font size="2">185</font></th>  <td bgcolor="#ffffff" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; ">                    <span \
class="k">return</span> <span class="n">QStringList</span><span \
class="p">(</span><span class="s">&quot;[plasmate]/imageDialog&quot;</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">197</font></th>  <td bgcolor="#ffffff" width="50%"><pre style="font-size: \
8pt; line-height: 140%; margin: 0; ">                    <span \
class="k">return</span> <span class="n">QStringList</span><span \
class="p">(</span><span class="s">&quot;[plasmate]/imageDialog&quot;</span><span \
class="p">);</span></pre></td>  </tr>

  <tr>
    <th bgcolor="#f0f0f0" style="border-right: 1px solid #C0C0C0;" \
align="right"><font size="2">186</font></th>  <td bgcolor="#ffffff" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; ">                <span \
class="p">}</span> <span class="k">else</span> <span class="k">if</span> <span \
class="p">(</span><span class="o">!</span><span class="n">qstrcmp</span><span \
class="p">(</span><span class="n">key</span><span class="p">,</span> <span \
class="s">&quot;config&quot;</span><span class="p">))</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">198</font></th>  <td bgcolor="#ffffff" width="50%"><pre style="font-size: \
8pt; line-height: 140%; margin: 0; ">                <span class="p">}</span> <span \
class="k">else</span> <span class="k">if</span> <span class="p">(</span><span \
class="o">!</span><span class="n">qstrcmp</span><span class="p">(</span><span \
class="n">key</span><span class="p">,</span> <span \
class="s">&quot;config&quot;</span><span class="p">))</span> <span \
class="p">{</span></pre></td>  </tr>

  <tr>
    <th bgcolor="#f0f0f0" style="border-right: 1px solid #C0C0C0;" \
align="right"><font size="2">187</font></th>  <td bgcolor="#ffffff" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; ">                    <span \
class="k">return</span> <span class="n">QStringList</span><span \
class="p">(</span><span \
class="s">&quot;[plasmate]/mainconfigxml/new&quot;</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">199</font></th>  <td bgcolor="#ffffff" width="50%"><pre style="font-size: \
8pt; line-height: 140%; margin: 0; ">                    <span \
class="k">return</span> <span class="n">QStringList</span><span \
class="p">(</span><span \
class="s">&quot;[plasmate]/mainconfigxml/new&quot;</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">188</font></th>  <td bgcolor="#fdfebc" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; ">                <span \
class="p">}</span> <span class="k">else</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">200</font></th>  <td bgcolor="#fdfebc" \
width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; ">              \
<span class="p">}</span> <span class="k">else</span> <span class="k">if</span><span \
class="p">(</span><span class="o">!</span><span class="n">qstrcmp</span><span \
class="p">(</span><span class="n">key</span><span class="p">,</span> <span \
class="s">&quot;animations&quot;</span><span class="p">)</span> <span \
class="o">&amp;&amp;</span> <span class="n">packageType</span><span \
class="p">()</span> <span class="o">!=</span> <span \
class="s">&quot;Plasma/Theme&quot;</span><span class="p">)</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">201</font></th>  <td bgcolor="#c5ffc4" \
width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; ">              \
<span class="c1">//add an exception. the plasmoid package also contains the key \
animations,</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">202</font></th>  <td bgcolor="#c5ffc4" \
width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; ">              \
<span class="c1">//so if this isn&#39;t a theme package return the right \
mimetype</span></pre></td>  </tr>

 </tbody>





 
 

 <tbody>

  <tr>
    <th bgcolor="#f0f0f0" style="border-right: 1px solid #C0C0C0;" \
align="right"><font size="2">189</font></th>  <td bgcolor="#ffffff" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; ">                    <span \
class="k">return</span> <span class="n">QStringList</span><span \
class="p">(</span><span class="s">&quot;[plasmate]/new&quot;</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">203</font></th>  <td bgcolor="#ffffff" width="50%"><pre style="font-size: \
8pt; line-height: 140%; margin: 0; ">                    <span \
class="k">return</span> <span class="n">QStringList</span><span \
class="p">(</span><span class="s">&quot;[plasmate]/new&quot;</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">204</font></th>  <td bgcolor="#c5ffc4" \
width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; ">              \
<span class="p">}</span> <span class="k">else</span> <span class="k">if</span> <span \
class="p">(</span><span class="n">m_themeImageDialogOptions</span><span \
class="p">.</span><span class="n">contains</span><span class="p">(</span><span \
class="n">key</span><span class="p">))</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">205</font></th>  <td bgcolor="#c5ffc4" \
width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; ">              \
<span class="k">return</span> <span class="n">m_themeImageDialogOptions</span><span \
class="p">.</span><span class="n">value</span><span class="p">(</span><span \
class="n">key</span><span class="p">);</span></pre></td>  </tr>

 </tbody>

</table>

  <pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: \
-pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">why not add \
&quot;images&quot;, &quot;config&quot; and &quot;animations&quot; to \
m_themeImageDialogOptions and rename it to m_dialogOptions</pre>  </blockquote>





</blockquote>
<pre style="margin-left: 1em; white-space: pre-wrap; white-space: -moz-pre-wrap; \
white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">I have put  \
&quot;images&quot; and &quot;config&quot; into the hash, but how can it be done for \
&quot;animations&quot; too?

&gt; else if(!qstrcmp(key, &quot;animations&quot;) &amp;&amp; packageType() != \
&quot;Plasma/Theme&quot;) we check the key and the packageType, so we can&#39;t use \
the hash here. No?</pre> <br />

<blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: \
10px;">  <p style="margin-top: 0;">On November 29th, 2012, 1:53 p.m., <b>Aaron J. \
Seigo</b> wrote:</p>  <blockquote style="margin-left: 1em; border-left: 2px solid \
#d0d0d0; padding-left: 10px;">  



<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/106680/diff/5/?file=93807#file93807line544" \
style="color: black; font-weight: bold; text-decoration: \
underline;">plasmate/packagemodel.cpp</a>  <span style="font-weight: normal;">

     (Diff revision 5)

    </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; ">bool \
PackageModel::loadPackage()</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">539</font></th>  <td bgcolor="#c5ffc4" \
width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; ">    <span \
class="k">if</span> <span class="p">(</span><span class="n">packageType</span><span \
class="p">()</span> <span class="o">==</span> <span \
class="s">&quot;Plasma/Theme&quot;</span><span class="p">)</span> <span \
class="p">{</span></pre></td>  </tr>

 </tbody>

</table>

  <pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: \
-pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">&quot;Plasma/Theme&quot; \
should not appear in this file.</pre>  </blockquote>





</blockquote>
<pre style="margin-left: 1em; white-space: pre-wrap; white-space: -moz-pre-wrap; \
white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">the \
&quot;colors&quot; file isn&#39;t a requiredDirectory nor a requiredFile, so If I \
don&#39;t add it by hand in the m_topEntries it won&#39;t be visible and also we want \
the &quot;colors&quot; file in the m_topEntries only when the package is a theme. No? \
What am I missing?</pre> <br />




<p>- Giorgos</p>


<br />
<p>On November 5th, 2012, 5:51 p.m., Giorgos Tsiapaliokas 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 Plasma.</div>
<div>By Giorgos Tsiapaliokas.</div>


<p style="color: grey;"><i>Updated Nov. 5, 2012, 5: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;">create a new theme package-&gt;click on the new

a file dialog should appear but instead a simple edit box appears requesting a new \
filename.

This patch solves the issue</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>plasmate/editors/editpage.h <span style="color: grey">(5cb3ea6)</span></li>

 <li>plasmate/editors/editpage.cpp <span style="color: grey">(7e82ff2)</span></li>

 <li>plasmate/packagemodel.h <span style="color: grey">(efa3001)</span></li>

 <li>plasmate/packagemodel.cpp <span style="color: grey">(9eb0914)</span></li>

</ul>

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




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








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



_______________________________________________
Plasma-devel mailing list
Plasma-devel@kde.org
https://mail.kde.org/mailman/listinfo/plasma-devel


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

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