Schneegans / Desktop-Cube

🧊 Indulge in nostalgia with useless 3D effects.
GNU General Public License v3.0
620 stars 21 forks source link

Using right-to-left interface, mouse dragging direction is inverse #171

Open WiseFerret opened 3 weeks ago

WiseFerret commented 3 weeks ago

When the interface is set to a right-to-left language, such as Arabic, Hebrew or Farsi, the user must move the mouse to the right in order to rotate the cube to the left, and vice versa.

Steps to reproduce the behavior:

  1. Set the Gnome interface to Arabic through settings.
  2. Log out and log in.
  3. Rotate the cube to the left using the mouse.
  4. See the cube rotating to the right.

You may also check the output of GNOME Shell for any error messages. This can be done with the following terminal command:

Expected Behavior

The cube should rotate to the left.

System

Schneegans commented 3 weeks ago

Hi there! Thanks for the report. Could you please open ~/.local/share/gnome-shell/extensions/desktop-cube@schneegans.github.com/src/DragGesture.js and remove the - from -deltaX in this line?

Then logout and login again and see if the issue is fixed.

Sometime GNOME Shell resets any changes you make to these file on login. If that happens, you can increase the "version" number in ~/.local/share/gnome-shell/extensions/desktop-cube@schneegans.github.com/metadata.json by one.

WiseFerret commented 2 weeks ago

This solves the original issue: the movement direction of the cube is now identical to the movement direction of the mouse while dragging. However, the directional relation between the workspaces on the cube is wrong. In an rtl environment, the first workspace should be the one to the most right, the one left of it - the next one, and so on. Right now it's the opposite.