You are not logged in.
Pages: 1
Hi,
OpenBSD 6.5 xfce 4.12.1
I try to manage the ability of users to logout, shutdown or restart.
I use org.xfce.session.policy
Shutdown and Restart are handle by xfsm-shutdown-helper and I create a rule file to handle that.
I can't find a way to logout.
If I rename xfce4-session-logout only the menu application is affected and I get a dialog box Error:
Failed to execute command "xfce4-session-logout"
Failed to execute child process "xfce4-session-logout" (No such file or directory)
The Logout button in the action menu is not affected and show the dialog box with logout, shutdown and restart.
If shutdown and restart are not allowed, they are greyed.
The shutdown and restart buttons in the action menu are not updated (bug ?)
Another place where I find the Logout button is when I click right on a panel and I choose Panel on the context Menu.
I don't understand why it is there, I think nobody try to quit this way !!!
This button is not affected too and show the dialog box.
Perhaps there is anothers places where we can find this button.
So :
Is it a program responsible of the logout?
If no, it's certainly a message sent via dbus to xfce4-session.
If this is the case, how can I catch it?
Thanks.
Offline
What menu application?
Whisker-menu or the "Application menu" panel plugin?
Try using some menu editor like Alacarte if it's the second.
Menus read from the *.desktop files ussualy.
If the menu plugin can't find the command xfce4-session-logout it will probably display the error message.
To monitor for dbus messages run
dbus-monitor --session
Then you could send a dbus message via dbus-send to logout in the second terminal
Values are boolean, the first is "show_dialog" the secondis "allow_save".
dbus-send --session --type=method_call --print-reply --dest=org.xfce.SessionManager /org/xfce/SessionManager org.xfce.Session.Manager.Logout boolean:true boolean:false
Do you want to exit the Circus?
https://www.youtube.com/watch?v=ZJwQicZHp_c
Offline
Hi, thanks for reply.
Perhaps my question is not quite clear so ...
I try to catch user logout from xfce session.
I think before that the message box 'Logout, Shutdown, Restart ...) is part of xfce4-session-logout.
But this not the case because if I rename xfce4-session-logout, the message box continue anyway to pop up.
I try to know what is the program responsible of this message box.
Thanks.
Offline
xfce4-session-logout just sends signals via dbus
https://github.com/xfce-mirror/xfce4-se … out/main.c
Open the terminal and type
sleep 10; xprop
Now quickly open the Logout dialog and wait until the mouse cursor changes into a cross.
Then click anywhere on the dialog and close it to see the terminal.
It will tell you that the window class is xfce4-session.
The dialog is part of xfce4-session the very session manager that starts the xfce.
--- Oh, here it is.
https://github.com/xfce-mirror/xfce4-se … t-dialog.c
Last edited by Misko_2083 (2019-06-01 10:06:35)
Do you want to exit the Circus?
https://www.youtube.com/watch?v=ZJwQicZHp_c
Offline
Thanks to reply.
What i saw in you link ?
The message box xfce_session_logout send message via dbus so :
I can catch easily the signals reboot.
I can catch the signal shutdown with login1 (in debian) , perhaps with consolekit but i don't use it, and i can't catch it in openbsd with org.xfce.session .policy.
There is no way i know to catch the signal logout.
If you know a way ?
Another thing i saw is the switch user is part of the message box xfce_session_logout.
So i can have a button in this message box with switch user but i never saw it.
Only in the action button menu.
/**
* Switch User
*
* Hide the button if system cannot switch user, requires the display
* manager to provide the org.freedesktop.DisplayManager dbus API
**/
What is missing here with org.freedesktop.DisplayManager dbus API
Thanks.
Offline
Have a look here about user switching
https://forum.xfce.org/viewtopic.php?pid=47326#p47326
xfce4-power-manager --dump
pkaction --action-id org.xfce.session.xfsm-shutdown-helper --verbose
What policy file do you have?
Don't know about logout.
Do you want to exit the Circus?
https://www.youtube.com/watch?v=ZJwQicZHp_c
Offline
Pages: 1
[ Generated in 0.009 seconds, 7 queries executed - Memory usage: 545.38 KiB (Peak: 546.23 KiB) ]