From kde-devel Tue Sep 21 11:31:30 2010 From: Matthias Fuchs Date: Tue, 21 Sep 2010 11:31:30 +0000 To: kde-devel Subject: Re: How to define QVariantList of KCModule via .desktop-files? Message-Id: <201009211331.31035.mat69 () gmx ! net> X-MARC-Message: https://marc.info/?l=kde-devel&m=128506872310703 Am Dienstag 21 September 2010, 09:48:02 schrieb Kevin Krammer: > On Tuesday, 2010-09-21, Andriy Rysin wrote: > > 2010/9/20 Matthias Fuchs > > > > > Hi, > > > > > > I have exported a KCModule and now want add an argument to its > > > constructor via > > > a desktop file. > > > > > > The idea is that at compilation time it is not clear what the ui of the > > > KCModule looks like or what KConfigSkeleton should be used. > > > > > > Now if I can define at least one argument -- e.g. a file path, or just > > > a name > > > -- via the desktop file the module could look up what to do and how to > > > do this > > > at runtime. > > > > > > The reason I want to make this is that I create kross plugins that > > > should be > > > configureable comfortable via KPluginSelector. > > > > > > > > > Cheers, > > > matthias > > > > I was actually asking the same question couple of months ago, seems to be > > currently there's no way to pass arguments, though as KCModule takes > > arguments it'd make sense to be able to pass them in kcmshell4 and > > desktop files. > > What about reading your KCM's .desktop file using KDesktopFile and checking > a custom entry? > > Cheers, > Kevin Though that would only work in Andriy's case, unfortunately not in mine. Unless there is a way to get the path of the desktop file that was responsible for "creating" the KCM, then my whole problem would be solved. >> Visit http://mail.kde.org/mailman/listinfo/kde-devel#unsub to unsubscribe <<