Review Request 124537: RFC: Add autocfg property magic for applet config dialogs

Kai Uwe Broulik kde at privat.broulik.de
Fri Jul 31 19:21:20 UTC 2015



> On Juli 31, 2015, 12:55 nachm., Marco Martin wrote:
> > I like the idea, not sure about the autocfg_ prefix.
> > was it discussed in a bof? are there notes about it?

Yeah, maybe cfgitem or something like that?
Well, they mentioned they need good Kiosk support so I wanted to make the Plasma stuff follow that as magically as possible, UI-wise, that is.


- Kai Uwe


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://git.reviewboard.kde.org/r/124537/#review83231
-----------------------------------------------------------


On Juli 30, 2015, 8:38 nachm., Kai Uwe Broulik wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://git.reviewboard.kde.org/r/124537/
> -----------------------------------------------------------
> 
> (Updated Juli 30, 2015, 8:38 nachm.)
> 
> 
> Review request for Plasma.
> 
> 
> Repository: plasma-desktop
> 
> 
> Description
> -------
> 
> Now you can use autocfg properties to applet config dialogs which are smarter than the cfg stuff we currently have. Instead of binding it directly to a property you bind it to an item and it tries to figure out what to do based on the properties the item has and the type of the config.
> 
> This allows us to automatically reflect immutables (cf. LiMux) in the UI without further ado by the plasmoid programmer. It can:
> 
> Boolean config:
>   - If it's bound to sth with a "checked" property (eg. checkbox), it sets checked to the config
> 
> Int config:
>   - If it's bound to sth with a "currentIndex" property (eg. combobox), it sets currentIndex to the config
>   - If it's bound to sth with value, minimumValue and maximumValue property (eg. slider or spinbox) it sets value to the config
> 
> String config:
>   - If it's bound to sth with a "text" property (eg. textfield) it sets text to the config
> 
> Maybe there's even more? We don't really have introspection so I just rely on properties being there and the programmer not doing rubbish. We could also use the label from the config xml and/or auto-populate min/maxvalue
> 
> 
> Diffs
> -----
> 
>   desktoppackage/contents/configuration/AppletConfiguration.qml 0302c7a 
> 
> Diff: https://git.reviewboard.kde.org/r/124537/diff/
> 
> 
> Testing
> -------
> 
> Working pretty nicely
> 
> 
> Thanks,
> 
> Kai Uwe Broulik
> 
>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/plasma-devel/attachments/20150731/62236b49/attachment-0001.html>


More information about the Plasma-devel mailing list