Annotation tools do not display correct state in some sitations
Closed, ResolvedPublic8 Estimated Story Points

Description

Create a document:

<b>Foo</b> bar

select from within foo to within bar: [B] is active in the toolbar
select from within bar to within foo: [B] is not active

expected: annotation tool state should be based on covered selections. selection direction shouldn't make a difference.

Event Timeline

Esanders raised the priority of this task from to Needs Triage.
Esanders updated the task description. (Show Details)
Esanders added a project: VisualEditor.
Esanders added subscribers: Esanders, dchan.
Jdforrester-WMF renamed this task from Annotation tools not display correct state to Annotation tools do not display correct state in some sitations.Feb 9 2016, 8:09 PM
Jdforrester-WMF triaged this task as Medium priority.
Jdforrester-WMF set Security to None.
Jdforrester-WMF moved this task from To Triage to TR3: Language support on the VisualEditor board.

Change 320729 had a related patch set uploaded (by DLynch):
dm.Surface: contextChange if non-collapsed selection moves in/out of annotations

https://gerrit.wikimedia.org/r/320729

Wasn't strictly a selection-direction issue -- rather, it was that contextChange doesn't emit after the selection start/end leaves the annotated region, so the toolbar didn't know to update. Patch adds in a check in setSelection to catch that case.

Change 320729 merged by jenkins-bot:
dm.Surface: contextChange if non-collapsed selection moves in/out of annotations

https://gerrit.wikimedia.org/r/320729

Change 321686 had a related patch set uploaded (by Jforrester):
Update VE core submodule to master (c8389bd)

https://gerrit.wikimedia.org/r/321686

Change 321686 merged by jenkins-bot:
Update VE core submodule to master (c8389bd)

https://gerrit.wikimedia.org/r/321686