Closed star-buck closed 9 years ago
Something along these lines in applet's main file:
...
import org.kde.kquickcontrolsaddons 2.0
function action_soundkcm() {
KCMShell.open("name_of_the_kcm");
}
Component.onCompleted: {
plasmoid.setAction("soundkcm", i18n("Sound Volume Settings..."));
}
Actually watch out for calling it "Sound Volume Settings" because then you'll have two same entries in the context menu - this one and the default plasmoid one. I don't think you can embed the kcm in the default config dialog unless that kcm is done using QtQuickControls.
@mck182 the kcm is qtquick
yes, that's a problem of plasma5. in the past you could just embed kcms in the config dialogs, but now that config dialogs are done in QML, you can't put kcms there anymore.
so you can either replace the configure action or having 2 entries. If you replace it tough, you lose the config for the keyboard shortcut that would open the popup.
@apachelogger uh, really? if it's done with the KDeclararative::ConfigModule api, we can try to make some machinery to embed the kcm in the confg dialog as it used to be. (would require Plasma 5.4 tough, so if it's planned to be shipped on 5.3 would either need a patched one or the double actions kept until then)
@notmart import org.kde.kcm 1.0 ;)
where is the code for that? all in scratch/sitter/plasma-volume-control ?
but yeah, i think we can do something with that then ;)
Whats this? ^^ Can it be packaged to make it work in netrunner-.16-ci-fixes?
for now it would have to either have 2 context menu entries or replace the config action losing the shortcut config, in the way @mck182 shown.
For 5.4 i would like to have it done the proper way, since the kcm is already in qml it can be loaded inside the plasmoid config window. if i manage to do it completely in plasma-framework it could be integrated even before, with new frameworks, we'll see.
so for netrunner-16, which would be due next week, I need someone to decide for one of the solutions then: a patch, link to code, note to harald to make a package, package put in netrunner-16-ci-fixes, leszek ships package in ISO.
this is a patch that replaces the action: http://paste.opensuse.org/4665433 wether is better as a netrunner patch or upstream for a while (maybe in a release branch?) leaving @apachelogger to say :)
@star-buck I'll need to know where we get the package from for netrunner 16, or at least which version the current one has so I can prepare an update.
@apachelogger : the currently used package is from here: https://launchpad.net/~netrunner-os/+archive/ubuntu/netrunner-16-extras I guess its copied over from blueshellnext ppa...
ok, new snapshot: https://launchpad.net/~netrunner-os/+archive/ubuntu/netrunner-16-ci-fixes/+sourcepub/5043133/+listing-archive-extra
this version should make the settings of the applet open the KCM and restore the ability to show application streams
awesome, just somehow hasn't build yet...
great, will test now thanks!
tested and works!
it would be nice to open the new kcm_pulseaudio mixer settings dialog in that popup (similar to kde4). Maybe someone can get Harald a tip how to achieve this?