[PATCH] Lock/Logout plasmoid: configure shown buttons

Aaron J. Seigo aseigo at kde.org
Sun Feb 8 16:21:13 CET 2009


On Sunday 08 February 2009, Konstantinos Smanis wrote:
> I have followed the coding styles and all these things, but there were some
> things that I wasn't sure for. For example, under Windows the logout button
> is not shown so the configuration UI should not apply there. Thus I have

you can get away with a lot less ifdef'd code; just return immediately from 
createConfigurationInterface if on windows, for instance. i wouldn't bother 
with the rest of the ifdef's.

also, instead of "Both Buttons" as an option, just make them all checkboxes. 
this way if/when someone adds "suspend to ram" then we don't need all the 
permutations for the three ;)

if the user turns off all the buttons, then what? well .. in that case i'd 
suggest calling setConfigurationRequired(true) :)

-- 
Aaron J. Seigo
humru othro a kohnu se
GPG Fingerprint: 8B8B 2209 0C6F 7C47 B1EA  EE75 D6B7 2EB1 A7F1 DB43

KDE core developer sponsored by Qt Software

-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 197 bytes
Desc: This is a digitally signed message part.
Url : http://mail.kde.org/pipermail/plasma-devel/attachments/20090208/703df7d8/attachment.sig 


More information about the Plasma-devel mailing list