Forum Replies Created
-
AuthorPosts
-
Hello, here is the LUA code.
I needed a button to switch the CPU frequency between power saving and performance modes. So, the code first checks if the panel is running in Windows or in Linux/OS X, then calls the external script.
You can find the actual scripts in my panel distribution, at http://blog.magnolo.com/pianoteq-touch-panel/set_governor = function(--[[ CtrlrModulator --]] mod, --[[ number --]] value, --[[ number --]] source) if value==0 then governor="powersave" else governor="performance" end if package.config:sub(1,1) == '\\' then -- windows os.execute( "%UserProfile%\\set_governor.bat "..governor) else -- OSX and Linux os.execute( "~/set_governor.sh "..governor) end end
By the way, your guide was very useful to understand how to begin with Ctrlr, thank you very much!
- This reply was modified 8 years, 4 months ago by amagnolo.
Self-answer: Yes, it is possible, using LUA. It was not so obvoius to me. 🙂
I tried the 5.3.178 binary with the new option and it works all right; I noticed that the “add resource” dialog still uses zenity but it works even without the KDE_FULL_SESSION variable. Even the “open panel” dialog now works with zenity.
Anyway, I haven’t experienced any freeze with this build, so the problem seems solved, thank you very much!I still have occasional program freezes on file dialog open (also when trying to add a resource). I tried to set “Use OS native dialog windows” in preferences but nothing changes.
The only workaround is to reboot the computer until you get lucky and the dialog box finally opens…These might be useful for diagnosing:
http://www.juce.com/forum/topic/freeze-when-opening-filechooser
http://www.juce.com/forum/topic/fixes-native-zenity-linux-file-dialog-patch- This reply was modified 8 years, 4 months ago by amagnolo.
update: if I do
export KDE_FULL_SESSION=true
before the first launch of Ctrlr it works. Otherwise, after Ctrlr is launched without that variable set, subsequent launches won’t work, until the pc is rebooted.I have the same problem on Lubuntu 15.10 (LXDE/Openbox): Ctrlr freezes on panel open/save.
Is there any workaround? -
AuthorPosts