-
Notifications
You must be signed in to change notification settings - Fork 12
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
Change to allow running on its own #4
Change to allow running on its own #4
Conversation
I still don't think it's a good idea to toggle the touchpad independend of what the DE thinks the touchpad state is. I think it will confuse people, which then will lead to false bug reports. But, without having checked it for myself yet, since xfce is gnome based, doesn't it also use dconf? If yes, I don't think it should be too hard creating a setup-xfce by copying and altering the setup-gnome. Do you want to look into it? |
That can only happen when the program is run as a standalone (instead of daemon). As a standalone, the program needs to be executed by some other program. Most likely, that other program would also change the DE's touchpad state in the process.
In this example, the bash script keeps them in sync. Do note that if the program is already running as a daemon, it refuses to run again (ensured by the use of the pid file in Do you think otherwise?
Is it? I know some elements are shared but I wonder if it really is gnome based :)
I'll look into it. Maybe I'll figure out a way to detect if dconf exists instead of using a failure-prone environment variable. |
I checked with xfce. The status of the touchpad devices (1 for physical clicking and 1 for the pad) is stored in xfconf and not in dconf. I think they are similar in intention and xfconf has monitoring. I just have no idea about xfconf's API and I would need to study it... |
2 issues with this Script: It might get out of sync when you switch user from the lockscreen and gnome for example does not disable the events node (like xinput disable does) but only sets the touch events of the events node on ignore (can also be done with xinput). Also the setting menu might not update like this on every DE. As I read my last reply again I realised that It might be mssunderstood: I don't think a standalone toggle programm is a bad idea. I just don't think it should be the same programm as this daemon, as the goal of this deamon is passive driver only that the user does not need to think about. |
Oh! I see. May I make a 2nd executable in this project for the standalone program, then? |
79e586d
to
d851fc3
Compare
d851fc3
to
a324140
Compare
@Matombo , I finally got the time and finally updated the code with the split between the daemon and the cli. Check if it looks good please. |
@mhx Does the touchpad toggle button work for you? In my system, it's detected as |
Yes, works perfectly (albeit after a bit of head-scratching), both with the button area on the touchpad itself and Fn+F9. I've put this in my
I've enabled the touchpad toggle button with:
Last but not least, I've added this to openbox's
So the whole thing only works under X, but that's good enough for me. |
a324140
to
7e58243
Compare
In this last force-push I changed "By default, the executable has setuid permissions" because I decided not to have setuid, at least, yet. |
FWIW, the |
@Matombo Any updates? |
Sorry it took me some time to answer. Mostly because I don't want to reject your effords, but still it would change the KISS target of this repository. Even when there are 2 binaries now. Also I must optimize my long term maintanace tasks to not be distracted from new devices and features. So at the end of the day, while I really appreciate your effords, I will not accept the MR. I'm sorry. But feel free to fork the repository under the gpl and release your own version. |
@Matombo May I create a PR for other things I did that helped doing the
? |
TBH for the time being i consider the code "clean enough", so a heads-up: the code review for that patch will have a very low priority. Unless ofcourse you found an bug that needs fixing. When you create a new merge requests it will be helpfull when you split it up in functional units like:
|
For reference: I still hope that someone comes up with an idea for a proper upstream fix: https://gitlab.freedesktop.org/libinput/libinput/-/issues/558 |
Solves #2
I'm open for discussion but I really want this kind of features for myself as I use the xfce desktop.