GNOME Bugzilla – Bug 659498
Add option to reverse mouse scrolling (Natural scrolling)
Last modified: 2012-08-17 17:04:10 UTC
Created attachment 196982 [details] [review] Implement Natural scrolling Hi, I've done the implementation of a checbox in the "Mouse" section that reverse scroll wheel in order to have the Natural scrolling feature. This is my first patch, so do not hesitate to tell me all bad and good things, tips, etc.. I have tested it on my Ubuntu 11.10 using the HEAD version of the gnome-control-center repo. Regards,
Created attachment 197069 [details] [review] org.gnome.settings-daemon.peripherals.gschema.xml patch
IMO, this doesn't make sense for mice, just for trackpads/touchpads, which resemble touch devices in their way of working. The gnome-settings-daemon patch doesn't actually implement the feature. As for the gnome-control-center panel patch, the panel itself will be redesigned during GNOME 3.4 (and your patch comes too late for GNOME 3.2). See https://live.gnome.org/Design/SystemSettings/Mouse I would start by making the necessary changes to gnome-settings-daemon to support the feature. The functionality needs to be only applied to touchpads. Please make sure you use git formatted patches too.
Comment on attachment 196982 [details] [review] Implement Natural scrolling The implementation needs to go in gnome-settings-daemon's mouse plugin, otherwise people would need to open the mouse panel to have the setting applied.
Comment on attachment 197069 [details] [review] org.gnome.settings-daemon.peripherals.gschema.xml patch Please use git to create your patches.
I'm using it with my mouse. It's not ONLY touchpads. About the gnome-settings-daemon, the request has already been sent. I've attached the patch in order to allow people to test my feature. At work, I'm using Apple OS X. When Natural scrolling come, I started to like it directly. Now I'm a fan. So, it's a feature mouse as I have implemented it. I know it's a long there are pros and cons. So let user decide ;-)
Ha, and I followed the guide http://live.gnome.org/GnomeLove/SubmittingPatches. So I did a `git format-patch HEAD^`.
(In reply to comment #5) > I'm using it with my mouse. It's not ONLY touchpads. Ok. > About the gnome-settings-daemon, the request has already been sent. I've > attached the patch in order to allow people to test my feature. No it hasn't. (In reply to comment #6) > Ha, and I followed the guide http://live.gnome.org/GnomeLove/SubmittingPatches. > So I did a `git format-patch HEAD^`. git commit -a git format-patch -1 That was the patch has commit information (such as your real name, your e-mail address, etc.).
> > About the gnome-settings-daemon, the request has already been sent. I've > > attached the patch in order to allow people to test my feature. > > No it hasn't. I've submitted request to ubuntu-desktop@lists.ubuntu.com. > (In reply to comment #6) > > Ha, and I followed the guide http://live.gnome.org/GnomeLove/SubmittingPatches. > > So I did a `git format-patch HEAD^`. > > git commit -a > git format-patch -1 > > That was the patch has commit information (such as your real name, your e-mail > address, etc.). Ha, alright. Do you want that I upload again my patch ?
(In reply to comment #8) > > > About the gnome-settings-daemon, the request has already been sent. I've > > > attached the patch in order to allow people to test my feature. > > > > No it hasn't. > > I've submitted request to ubuntu-desktop@lists.ubuntu.com. The request to do what? I already explained that the gnome-settings-daemon patch only adds a setting. It also needs to have code to _apply_ the setting. The only thing the gnome-control-center code should do is change the setting in GSettings. > > (In reply to comment #6) > > > Ha, and I followed the guide http://live.gnome.org/GnomeLove/SubmittingPatches. > > > So I did a `git format-patch HEAD^`. > > > > git commit -a > > git format-patch -1 > > > > That was the patch has commit information (such as your real name, your e-mail > > address, etc.). > > Ha, alright. Do you want that I upload again my patch ? Sure, as soon as you've fixed the bugs I mentioned in my review.
(In reply to comment #9) > (In reply to comment #8) > > > > About the gnome-settings-daemon, the request has already been sent. I've > > > > attached the patch in order to allow people to test my feature. > > > > > > No it hasn't. > > > > I've submitted request to ubuntu-desktop@lists.ubuntu.com. > > The request to do what? I already explained that the gnome-settings-daemon > patch only adds a setting. It also needs to have code to _apply_ the setting. > > The only thing the gnome-control-center code should do is change the setting in > GSettings. Alright. So tell me how to submit the patch that add my feature key please? The thing I've sent is a patch of org.gnome.settings-daemon.peripherals.mouse that add the key.
(In reply to comment #2) > the gnome-control-center panel patch, the panel itself will be redesigned > during GNOME 3.4 (and your patch comes too late for GNOME 3.2). See > https://live.gnome.org/Design/SystemSettings/Mouse I've looked up your link. How do you feel the feature I want to implement ? Is it in the touchpad tab that make sense I agree as you said, or in the pointer tab that make sense in my case ? Or do you want I implement like it is and you mouse the option where you think is the best place when your redesign is finished ?
(In reply to comment #10) > (In reply to comment #9) > > (In reply to comment #8) > > > > > About the gnome-settings-daemon, the request has already been sent. I've > > > > > attached the patch in order to allow people to test my feature. > > > > > > > > No it hasn't. > > > > > > I've submitted request to ubuntu-desktop@lists.ubuntu.com. > > > > The request to do what? I already explained that the gnome-settings-daemon > > patch only adds a setting. It also needs to have code to _apply_ the setting. > > > > The only thing the gnome-control-center code should do is change the setting in > > GSettings. > > Alright. So tell me how to submit the patch that add my feature key please? > The thing I've sent is a patch of org.gnome.settings-daemon.peripherals.mouse > that add the key. You need code to apply that setting in gnome-settings-daemon. To generate patches, using "git commit" to commit your changes, and "git format-patch" to generate a patch with authorship information and a changelog. (In reply to comment #11) > (In reply to comment #2) > > the gnome-control-center panel patch, the panel itself will be redesigned > > during GNOME 3.4 (and your patch comes too late for GNOME 3.2). See > > https://live.gnome.org/Design/SystemSettings/Mouse > > I've looked up your link. How do you feel the feature I want to implement ? > Is it in the touchpad tab that make sense I agree as you said, > or in the pointer tab that make sense in my case ? > > Or do you want I implement like it is and you mouse the option where you think > is the best place when your redesign is finished ? Let's implement the gnome-settings-daemon code first, then we can think of the UI for it.
Where is the git repository where I can do my modification for gnome-settings-daemon please ?
(In reply to comment #14) > Where is the git repository where I can do my modification for > gnome-settings-daemon please ? Same location as the rest of GNOME, including gnome-control-center. See: http://git.gnome.org/browse/gnome-settings-daemon for the various ways to access the repository
See bug 674716 for what changes we need for natural scrolling with xi 2.2
Created attachment 220802 [details] [review] add touchpad natural scroll implementation (In reply to comment #16) > See bug 674716 for what changes we need for natural scrolling with xi 2.2 Hi! There is a new natural scroll implementation with xi. It is a part of mouse panel redesign https://bugzilla.gnome.org/show_bug.cgi?id=677206 . Please review attached patch.
Review of attachment 220802 [details] [review]: ::: plugins/mouse/gsd-mouse-manager.c @@ +964,3 @@ +set_natural_scroll (GsdMouseManager *manager, + GdkDevice *device, + gboolean natural_scroll_enabled) Just "natural_scroll" should be fine. @@ +982,3 @@ + } + + g_debug ("Trying to set device natural scroll for \"%s\"", gdk_device_get_name (device)); You need to print the state you want to set it to (eg. the value of natural_scroll_enabled). @@ +1000,3 @@ + ptr[1] = -abs(ptr[1]); + } + else { Same line, it should read: } else {
Pushed with the fixes to master.