Use correct mCursorActive flag initial value #3049
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Initially when Scrawl added a keyboard navigation, he decided to disable cursor by default, but such behaviour was later rolled back since it is not intuitive and a deviation from vanilla game.
Now an only case when cursor can be not active is when SDL_CONTROLLER_BUTTON_LEFTSTICK button is pressed on gamepad:
By default, mGamepadGuiCursorEnabled = true, so it is expected that mCursorActive should be also true by default (as mCursorVisible already does).
Current upstream behaviour works well on PC since SDL for some reason generates a couple of mouse events during game start and they enable in-game cursor (probably these events are supposed to init cursor position), but on platforms without mouse (e.g. Android) it may lead to issues due to lack of such emitted events.
According to testing, this PR allows to drop this custom patch.