Skip to content
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

[FIX][CORE] Fix handling of empty selection in text selection activity #981

Merged
merged 2 commits into from
May 18, 2020

Conversation

tobous
Copy link
Member

@tobous tobous commented May 15, 2020

Adjusts TextSelectionActivity.getSelection() to correctly return
TextSelection.EMPTY_SELECTION if all selection values are -1.

Adds an exception if only some values are -1. This should in theory not
be possible as a valid handling of all >=0 or all ==-1 is enforced by
the TextSelection constructor.

Adjusts TextSelectionActivity.getSelection() to correctly return
TextSelection.EMPTY_SELECTION if all selection values are -1.

Adds an exception if only some values are -1. This should in theory not
be possible as a valid handling of all >=0 or all ==-1 is enforced by
the TextSelection constructor.
@tobous tobous added Type: Bug Issue that describes an unintended behavior of Saros Area: Core Issue affecting the Saros Core labels May 15, 2020
@tobous tobous requested a review from m273d15 May 15, 2020 15:14
@tobous tobous self-assigned this May 15, 2020
@tobous
Copy link
Member Author

tobous commented May 15, 2020

This patch applies cleanly to rc-16.0.0, so cherry-picking it should not be an issue.

@saros-infrastructure
Copy link

Codacy Here is an overview of what got changed by this pull request:

Complexity increasing per file
==============================
- core/src/saros/activities/TextSelectionActivity.java  6
         

See the complete overview on Codacy

@tobous tobous merged commit 24a655e into master May 18, 2020
@tobous tobous deleted the pr/core/fix-empty-selection-handling branch May 18, 2020 10:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area: Core Issue affecting the Saros Core Type: Bug Issue that describes an unintended behavior of Saros
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants