two patches for tasks data engine

Gallien Matthieu matthieu_gallien at yahoo.fr
Mon May 12 18:19:27 CEST 2008


Le Wednesday 07 May 2008 01:35:16 Sebastian Kuegler, vous avez écrit :
> Hi Matthieu,
>
> On Tuesday 06 May 2008 23:24:24 Matthieu Gallien wrote:
> > Le mardi 6 mai 2008, GALLIEN Matthieu a écrit :
> > > Hi, everybody
> > > First thank you for all your hard work on plasma.
> > > This is my first patches ever send, but plasma seems a good start for
> > > that activity ;)
>
> Congrats, welcome to Plasma and happy hacking :)

Thanks

>
> > > I plan to work on an tasks applet to replace the kasbar of kde3. I mean
> > > that I want a taskbar without the name of tasks, just icons and the
> > > desktop number. I believe that it could be a good idea to try to use
> > > the tasks datengine. This is why I send those patches.
> > > It seems that the engine does not add sources for startup tasks.
> > > This the goal of the patch-startup.diff.
>
> I've had a quick look at the patch (didn't compile it, but spotted the
> omitted var name, and then saw it's fixed in your updated patch :)
>
> > > I am really novice, but it seems also that the coding style could
> > > benefit from my second patch (maybe not). In all case it may not be
> > > correct but may help me to better understand the coding style anyway.
>
> Coding style cleanup is good. Bonus points for it as a separate patch :)
>
> > again
> > updated the patch for adding startup task as sources, because it was not
> > compiling and not possible to apply the two patches simultaneously.
> > Now you may apply first the patch for coding style and then the patch to
> > add startup task sources.
> >
> > Sorry for the noise
>
> No problem. A bit of comment on your patch:
> > +    removeSource(QString(startup->id().id()));
>
> Remove QString()

Corrected

>
> > +    setData(name, "TaskOrStartup", QString("startup"));

Corrected

>
> Instead of QString("startup"), you can just write "startup", conversion
> happens automatically, IIRC.
>
> > +    setData(name, "TaskOrStartup", QString("task"));
>
> "task"

Corrected

Sorry I do not put std::string when coding with std lib but put it for Qt (Qt 
is something really new for me.).

>
> It looks good, and I don't see any issues with it (which doesn't mean there
> are none ;)). Moreover, it's a nice addition.
>
> By the way, did you look at the tasks applet? It doesn't seem to use the
> tasks engine, but the taskmanager/taskmanager.h lib directly.

If the patches looks good may someone commit them please. I have no svn 
account. Thanks in advance.

I had a look at the tasks applet before the plasma marathon. I tried to make 
it display squares with only the icon inside it. My goal was to try to create 
a copy of the kasbar of kde3. I failed to do it in a correct manner. It seems 
some bits where missing in the plasma layout or I am stupid.
I also saw that it is not using the data engine. I then thought wait for WoC 
and then try again to modify the tasks applet to not display the tasks name. 
Finally I decided to write a new applet from scratch and designed to use the 
data engine.

Best regards

-- 
Gallien Matthieu
-------------- next part --------------
A non-text attachment was scrubbed...
Name: patch-startup.diff
Type: text/x-diff
Size: 1878 bytes
Desc: not available
Url : http://mail.kde.org/pipermail/panel-devel/attachments/20080512/aace5ffc/attachment.bin 


More information about the Panel-devel mailing list