-
-
Notifications
You must be signed in to change notification settings - Fork 30
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Document actions handling for launchers #180
Comments
This sounds super interesting! I put together a demo app to verify the proposed solution: Actions Launcher Demo. I had to install a service file for D-Bus launching to work, but that's it as far as the application side goes. The demo app's launch actions can be triggered from the applications menu, and the app handles them as expected. (The Lock action presents a closed lock icon in the app window, and the Unlock action presents an open lock.) However, I encountered problems with triggering actions from the Dock. It lists actions fine, in fact it includes the icons, which are not present in applications menu. However, I think it does not use the D-Bus launch mechanism and so it does not activate the actions. I tried to track down the issue, and I think this is the difference:
I'm not really familiar with Dock's source code, so I may be reading it wrong. There might also be something wrong with the demo app I made. I would appreciate it if someone could double-check my assumptions. In case my hunch turns out to be correct I can open an issue on Dock's project and try to resolve it there. Once that is sorted out I can open a pull request for updating the developer documentation here. |
I also had problems with the dock. We're planning to do a rewrite of the dock for Wayland anyways, so depending on how much effort it is to fix in the current dock we may just want to wait to switch over docs until that time |
Tnx for the quick confirmation! Ok, I see you're already working on adding this for the new dock.🤘 I'll try to adjust the action handling in the current Plank-based implementation. If that proves to be too complicated we can wait for the new dock to fix it. And I can prepare an update to dev documentation here, in case we are ok with documentation being updated before the dock support (either version) lands. |
@Antolius that all sounds great, thank you for taking on this issue! |
I'm +1 on recommending DBusActivation, but i believe this should be part of an full rework over how to use the I would keep the |
I was thinking about updating examples in the Actions page as well. I see this issue as related to #179, so one pull request should probably address both. I could go a step further and update other examples through the docs to use the
I took this to mean that creating widgets and presenting the main window is still best handled in the
Yeah, it has to stay in the |
Yes, i mean, Things like, calling |
Problem
At the moment we tell developers that their app has to handle command line arguments for actions and we recommend using the
exec
line for actions, but it appears this isn't necessary with dbus activationProposal
Document:
DBusActivatable=true
to the main section of your desktop entryThis appears to "just work™" without having to add manual action handling
Prior Art (Optional)
No response
The text was updated successfully, but these errors were encountered: