Re: [gdm-list] Session identification and postlogin



Hello,

pidfile="/tmp/onboard-at-gdmlogin-display-${DISPLAY}.pid"

gives
/tmp/onboard-at-gdmlogin-display-127.0.0.1:1178.0.pid
during gdmlogin

but gives
/tmp/onboard-at-gdmlogin-display-127.0.0.1:1178.pid
during PostLogin

I suppose :1178 is the display and .0 is the screen. (a display can be composed from multiple screens; for example a user with 2 monitors; correct?)

So I am thinking of stripping the .0 from $pidfile during gdmlogin. Would this not make it screen independent?

Now I have to find a way to cut the screen indication from the value of $DISPLAY.
sed?

Many thanks in advance for any confirmation or help.

Francesco


At 2:11 PM +0200 8/27/07, Francesco Fumanti wrote:
Hello,




I am trying to do a configuration to be able to start and quit an
simple onscreen keyboard (not gok; another one called onboard to be
precise) during gdmlogin. (I will also start another utility, but
that is not relevant here.)

A dwell gesture will not start onboard directly; it will start a
script that starts and quits onboard. To check whether onboard is
already running, the script creates a pidfile with the pid of the
started onboard instance; if onboard is already running, the script
gets the pid from the pidfile, kills onboard and removes the pidfile.
This is working properly on my single user setup.




In order to make it also work with simultaneous multiple user, I
added the value of $DISPLAY to the name of the pidfile:

pidfile="/tmp/onboard-at-gdmlogin-display-${DISPLAY}.pid"

Now I wonder whether this will also work in the case of users with
multiple screens. Can anybody please confirm it?




Moreover, when gdmlogin quits, the pidfile will remain present on the
system if the user did not quit onboard. So I will create a "cleanup"
script to remove the pidfile, and call it from PostLogin.

Could anybody please confirm that it is the correct way to do it?

Moreover, could anybody please confirm that during PostLogin, the
variable $DISPLAY will still have the same value that it had during
the gdmlogin session? Otherwise, the cleanup script will not be able
to reconstruct the name of the pidfile.

If $DISPLAY has changed, could anybody please tell me how I should proceed?


Thanks in advance.

Francesco


PS: Once I have it all running, I will put everything online and send
a link to it to this mailing list.
_______________________________________________
gdm-list mailing list
gdm-list gnome org
http://mail.gnome.org/mailman/listinfo/gdm-list




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]