Where to put an AbstractIconApplet class.

Marco Martin notmart at gmail.com
Tue Feb 19 18:57:17 CET 2008


On Tuesday 19 February 2008, Aaron J. Seigo wrote:
> On Tuesday 19 February 2008, Christopher Blauvelt wrote:
> > I've started on adding device icons to the desktop
>
> do we really want to go down that road? or should we just given people the
> defvice notifier applet and make them start to make the transition to the
> brave new world? my concern is that this will end up duplicating a lot of
> code from the device notifier; it's really not very plasma in its approach
> and may well result in the device notifier not becoming what it
> could/should be on Planar/MediaCenter form factors.

the main problem with it would be that probably it would need some specialized 
code somewhere to actually create the applets when a device is plugged
for the device notifier (and in what containment they should be added?)
i kinda like the way the devicenotifier works even if incomplete, maybe it 
would be nice to make it not so tied to devices and display also the other 
locations (what KFilePlacesModel sees)

> > and it seems that there
> > is going to be a lot of code duplicated between device icons and the file
> > icons.  Since Trach Applet will likely share a lot of code as well I'd
> > like to make an AbstractIconApplet class which will sub-class Applet in
> > order to reduce the amount of code duplicated and ease maintenance of the
> > code.
>
> what are the commonalities that need to be shared? i'm aware of the focus
> issues (dragging the icon drags the applet; this ends up imperfect as we
> have it unfortunately, btw, as it currently by passes any code we have in
> applet handle..) but what else?

the big thing is the mousemoveevent, also constraintsupdated are more or less 
the same, they could be the same function but maybe it would kill 
flexibility?
as for mousemoveevent,  is there a meaningful place to put it? a common 
abstract applet could be a way that at the moment better than nothing..
or better, is there a way to get rid of that thing (and still being able to 
manage clicks)?

Cheers,
Marco Martin


More information about the Panel-devel mailing list