-
Notifications
You must be signed in to change notification settings - Fork 40
Support 3.29.90 get neighbor workaround #81
Support 3.29.90 get neighbor workaround #81
Conversation
@@ -230,7 +232,7 @@ function indexToRowCol(index) { | |||
*/ | |||
function rowColToIndex(row, col) { | |||
// row-major. 0-based. | |||
let idx = row * global.screen.workspace_grid.columns + col; | |||
let idx = row * Utils.WS.getWS().workspace_grid.columns + col; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why not create a constant for the Utils.WS.getWS()
workspace manager?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This modification is inspired by what has been done in micheleg/dash-to-dock@8398d41
I suppose we cannot cache the workspace manager (even if I am not sure it can really change... maybe, I don't know :) )
751f0f5
to
fcd5e93
Compare
@matttbe thanks for your contributions, please have a look at my comments on how to potentially improve this PR |
@zakkak thank you for your review! Please tell me what you prefer:
|
In general I would go for simpler code and sacrifice compatibility, however since 3.28 is the latest version for ubuntu 18.04 which is an LTS release and people are starting to move to 3.30 on other distros I guess compatibility is something we need. On the other hand if we are going to share source code for different versions it would be better to have if statements that make clear which part of the if/else is for which version, that's why I prompted for checking the version instead of some method signature that changed in the latest release. |
You are right, I will keep the compatibility then!
You are right, I will try to find something clearer. |
Due to: https://gitlab.gnome.org/GNOME/gnome-shell/commit/47ea10b7 Inspired by micheleg/dash-to-dock@8398d41 - global.screen has been replaced by global.workspace_manager - Meta.ScreenCorner has been replaced by Meta.DisplayCorner - Main.wm._showWorkspaceSwitcher has less arguments (no more screen) Signed-off-by: Matthieu Baerts <matttbe@gmail.com>
global.get_overrides_settings() is no longer available. See: https://bugzilla.gnome.org/show_bug.cgi?id=786496 Signed-off-by: Matthieu Baerts <matttbe@gmail.com>
Bug report: https://gitlab.gnome.org/GNOME/mutter/issues/270 Signed-off-by: Matthieu Baerts <matttbe@gmail.com>
fcd5e93
to
ef23483
Compare
@matttbe please reopen the PR with edits that don't break 3.28 support or just make a totally incompatible with 3.28 version and I will merge it in a new branch |
@zakkak thank you for having merge approved this. Do you have more details about the error? I don't understand how I can try to check that on Gnome v3.28 but I am not sure I will have time before the week-end. |
I checked and the |
@zakkak by chance, do you have a line number? I suspect more a typo due to an option I don't use. I am not sure why the same function would not be defined in 3.28 :) |
Nope, just saw the error through Alt+F2 lg, do you know how I could get
a more verbose log, possibly with line numbers? I can't recall how to do
it right now.
…On 04/09/2018 11:58 πμ, Matthieu Baerts wrote:
@zakkak <https://github.com/zakkak> by chance, do you have a line
number? I suspect more a typo due to an option I don't use. I am not
sure why the same function would not be defined in 3.28 :)
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#81 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/ABXnA8V6tt5EUvyUMZnGIR6JSiHr0aKDks5uXkC1gaJpZM4WCpVa>.
|
@zakkak I think you can use:
(note that the |
|
The issue appears to be related to how you calculate the Please try something like the following instead:
|
Hi @zakkak, |
Hi,
This PR is based on the #80 with one more commit.
This is a workaround for GNOME 3.29.30 for this bug: https://gitlab.gnome.org/GNOME/mutter/issues/270
Without it, going left/right does nothing and down/up goes to the next/previous workspace. When you use to do that, it is disturbing :-)
Maybe other people also wants this workaround.
Even if it is a workaround, it should do exactly the same as before with older versions. It could then be merged as well and reverted later when the bug is fixed.