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

List:       kde-panel-devel
Subject:    Re: Review Request: kickoff: save recent applications list on every change to it
From:       "Seif Lotfy" <seif () lotfy ! com>
Date:       2012-05-31 21:18:24
Message-ID: 20120531211824.24515.98403 () vidsolbach ! de
[Download RAW message or body]

[Attachment #2 (multipart/alternative)]


> On May 31, 2012, 10:09 a.m., Aaron J. Seigo wrote:
> > the real fubar here is that it stores this information internally in its own \
> > config file. this really ought to be stored/retrieved from nepomuk and/or \
> > zeitgeist. 
> > i've cc'd Trever on this because he may have something to say about that as well.
> 
> Trever Fischer wrote:
> I actually just recently patched Dragon to do so, and it took very few lines: \
> http://quickgit.kde.org/index.php?p=dragon.git&a=commitdiff&h=92fb6296e424dc829e0c5cc541aa3581856d2098
>  
> Since Kickoff uses QAbstractItemModels, switching things to use a \
> QZeitgeist::LogModel should be trivial. Alternatively, implementing the \
> RecentApplications class to use Zeitgeist can be trivial as well, and would seem \
> like the easiest way to do things. 
> Aaron J. Seigo wrote:
> if we could dump RecentApplications that'd be great. there's not much reason to go \
> through a local class just to get to another library (qzeitgeist) class. then the \
> LogModel can be used in the RecentlyUsedModel ..  
> in fact, if KRecentDocument in kdelibs/kio/kfile/ were made to use zeitgeist, i bet \
> we could just drop the RecentlyUsedModel altogether, or at worst have it as a thin \
> layer around LogModel (don't know what LogModel provides, so I can't really offer a \
> concrete suggestion there). that sounds like frameworks 5 work, though, so we'll \
> have to just hold off on that for kickoff .. but would seem to be the natural \
> progression and something that could implemented immediately in the frameworks \
> branch in any case... 
> Trever Fischer wrote:
> logmodel.h: http://quickgit.kde.org/index.php?p=libqzeitgeist.git&a=blob&h=2ef6bfac0 \
> ab917ed5508da64b3a9d1a9290e65e6&hb=a58d1caaa953b514b7bd1697c44aebf75b11829d&f=src%2Flogmodel.h
>  
> It provides a bunch of shortcuts for access to the underlying event object data, or \
> you can access the event in its entirety. 
> What it doesn't provide that the recentlyusedmodel provides is the immediate \
> ability to remove events. You'd need to grab the event and then ask a Log object to \
> delete it from the database. I am considering adding that API to the 0.10 release. 
> Ivan Čukić wrote:
> Another thing for these types of models that we *need* to start adding is the \
> support for different results based on the activity. 
> Has Zeitgeist moved in that direction as promised before (in Randa)?

This is supported. Just attach the id of the activity to the event.origin. You can \
then query Zeitgeist with event.origin set to the activity id and it will return only \
results based on events that happened in that activity


- Seif


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


On May 31, 2012, 10:08 a.m., Andriy Gapon wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> http://git.reviewboard.kde.org/r/105112/
> -----------------------------------------------------------
> 
> (Updated May 31, 2012, 10:08 a.m.)
> 
> 
> Review request for Plasma and Trever Fischer.
> 
> 
> Description
> -------
> 
> Currently recent applications list in kickoff is saved only when kickoff gracefully \
> exits.  This could be a minor annoyance when X/KDE/plasma crashes.  I think that \
> saving the list on every update to it should be a good idea.  It should be a low \
> overhead too, because the list changes only when a user launches an application via \
> KDE. 
> 
> This addresses bug 206511.
> http://bugs.kde.org/show_bug.cgi?id=206511
> 
> 
> Diffs
> -----
> 
> plasma/desktop/applets/kickoff/core/recentapplications.cpp 3e05389 
> 
> Diff: http://git.reviewboard.kde.org/r/105112/diff/
> 
> 
> Testing
> -------
> 
> 
> Thanks,
> 
> Andriy Gapon
> 
> 


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





<blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: \
10px;">  <p style="margin-top: 0;">On May 31st, 2012, 10:09 a.m., <b>Aaron J. \
Seigo</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;">the real fubar here is that it stores this information internally in its \
own config file. this really ought to be stored/retrieved from nepomuk and/or \
zeitgeist.

i&#39;ve cc&#39;d Trever on this because he may have something to say about that as \
well.</pre>  </blockquote>




 <p>On May 31st, 2012, 1:37 p.m., <b>Trever Fischer</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;">I actually just recently \
patched Dragon to do so, and it took very few lines: \
http://quickgit.kde.org/index.php?p=dragon.git&amp;a=commitdiff&amp;h=92fb6296e424dc829e0c5cc541aa3581856d2098


Since Kickoff uses QAbstractItemModels, switching things to use a \
QZeitgeist::LogModel should be trivial. Alternatively, implementing the \
RecentApplications class to use Zeitgeist can be trivial as well, and would seem like \
the easiest way to do things.</pre>  </blockquote>





 <p>On May 31st, 2012, 2:43 p.m., <b>Aaron J. Seigo</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;">if we could dump \
RecentApplications that&#39;d be great. there&#39;s not much reason to go through a \
local class just to get to another library (qzeitgeist) class. then the LogModel can \
be used in the RecentlyUsedModel .. 

in fact, if KRecentDocument in kdelibs/kio/kfile/ were made to use zeitgeist, i bet \
we could just drop the RecentlyUsedModel altogether, or at worst have it as a thin \
layer around LogModel (don&#39;t know what LogModel provides, so I can&#39;t really \
offer a concrete suggestion there). that sounds like frameworks 5 work, though, so \
we&#39;ll have to just hold off on that for kickoff .. but would seem to be the \
natural progression and something that could implemented immediately in the \
frameworks branch in any case...</pre>  </blockquote>





 <p>On May 31st, 2012, 4:36 p.m., <b>Trever Fischer</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;">logmodel.h: \
http://quickgit.kde.org/index.php?p=libqzeitgeist.git&amp;a=blob&amp;h=2ef6bfac0ab917e \
d5508da64b3a9d1a9290e65e6&amp;hb=a58d1caaa953b514b7bd1697c44aebf75b11829d&amp;f=src%2Flogmodel.h


It provides a bunch of shortcuts for access to the underlying event object data, or \
you can access the event in its entirety.

What it doesn&#39;t provide that the recentlyusedmodel provides is the immediate \
ability to remove events. You&#39;d need to grab the event and then ask a Log object \
to delete it from the database. I am considering adding that API to the 0.10 \
release.</pre>  </blockquote>





 <p>On May 31st, 2012, 4:45 p.m., <b>Ivan Čukić</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;">Another thing for these \
types of models that we *need* to start adding is the support for different results \
based on the activity.

Has Zeitgeist moved in that direction as promised before (in Randa)?</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;">This is supported. Just \
attach the id of the activity to the event.origin. You can then query Zeitgeist with \
event.origin set to the activity id and it will return only results based on events \
that happened in that activity</pre> <br />








<p>- Seif</p>


<br />
<p>On May 31st, 2012, 10:08 a.m., Andriy Gapon 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 and Trever Fischer.</div>
<div>By Andriy Gapon.</div>


<p style="color: grey;"><i>Updated May 31, 2012, 10:08 a.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;">Currently recent applications list in kickoff is saved only when kickoff \
gracefully exits.  This could be a minor annoyance when X/KDE/plasma crashes.  I \
think that saving the list on every update to it should be a good idea.  It should be \
a low overhead too, because the list changes only when a user launches an application \
via KDE.</pre>  </td>
 </tr>
</table>




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


</div>


<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Diffs</b> </h1>
<ul style="margin-left: 3em; padding-left: 0;">

 <li>plasma/desktop/applets/kickoff/core/recentapplications.cpp <span style="color: \
grey">(3e05389)</span></li>

</ul>

<p><a href="http://git.reviewboard.kde.org/r/105112/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