Implement unified HyperTextAccessibleBase for TextSubstring, TextAtOffset and CharacterCount
Categories
(Core :: Disability Access APIs, task)
Tracking
()
Tracking | Status | |
---|---|---|
firefox95 | --- | fixed |
People
(Reporter: Jamie, Assigned: Jamie)
References
Details
Attachments
(11 files)
48 bytes,
text/x-phabricator-request
|
Details | Review | |
48 bytes,
text/x-phabricator-request
|
Details | Review | |
48 bytes,
text/x-phabricator-request
|
Details | Review | |
48 bytes,
text/x-phabricator-request
|
Details | Review | |
48 bytes,
text/x-phabricator-request
|
Details | Review | |
48 bytes,
text/x-phabricator-request
|
Details | Review | |
48 bytes,
text/x-phabricator-request
|
Details | Review | |
48 bytes,
text/x-phabricator-request
|
Details | Review | |
48 bytes,
text/x-phabricator-request
|
Details | Review | |
48 bytes,
text/x-phabricator-request
|
Details | Review | |
48 bytes,
text/x-phabricator-request
|
Details | Review |
In order for Windows and ATK to support cached text, we need to support HyperTextAccessible for RemoteAccessible. To do that, we need to add a HyperTextAccessibleBase class which is used by both local and remote. This should not inherit from Accessible. HyperTextAccessible (the existing class for LocalAccessibles) will inherit from this new base as well as LocalAccessible. RemoteAccessible will also inherit from this new base.
Assignee | ||
Updated•3 years ago
|
Assignee | ||
Updated•3 years ago
|
Assignee | ||
Updated•3 years ago
|
Assignee | ||
Comment 1•3 years ago
|
||
We're going to need the caching first, rather than the other way around.
Assignee | ||
Comment 2•3 years ago
|
||
Let's start with the methods we need to get a range of text, as well as word and line offsets.
Assignee | ||
Comment 3•3 years ago
|
||
This will contain methods that can be used for both local and remote Accessibles.
It is inherited into both HyperTextAccessible (local) and RemoteAccessibleBase.
Assignee | ||
Comment 4•3 years ago
|
||
Although HyperTextAccessibleBase implements these, we leave the HyperTextAccessible implementations (overriding the base) because they do caching.
Depending on performance, we may eventually want to move the caching into the base implementation.
I decided not to do this initially because it will use extra memory in the parent process and it may be a premature optimisation.
Assignee | ||
Comment 5•3 years ago
|
||
Assignee | ||
Comment 6•3 years ago
|
||
The implementation for RemoteAccessibleBase is just a stub; we don't cache the caret yet.
However, this needs to be in HyperTextAccessibleBase because it is used by ConvertMagicOffset, which will be moved in an upcoming patch.
Assignee | ||
Comment 7•3 years ago
|
||
Assignee | ||
Comment 8•3 years ago
|
||
Assignee | ||
Comment 9•3 years ago
|
||
Assignee | ||
Comment 10•3 years ago
|
||
Assignee | ||
Comment 11•3 years ago
|
||
This is pretty similar to HyperTextAccessible::TransformOffset.
However, the local implementation has to compensate for list bullet errors propagating from FindOffset/PeekOffset, which isn't relevant for TextLeafPoint.
Therefore, we leave the HyperTextAccessible implementation alone so it will still be used by HyperTextAccessible code (FindOffset, etc.).
Assignee | ||
Comment 12•3 years ago
|
||
The TextLeafPoint implementation works for both local and remote.
HyperTextAccessible calls the base implementation for supported boundaries when the cache is enabled.
Assignee | ||
Comment 13•3 years ago
|
||
Comment 14•3 years ago
|
||
Pushed by jteh@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/52c6c1d60659 part 1: Add hyperTextAccessibleBase class. r=eeejay https://hg.mozilla.org/integration/autoland/rev/89f855907787 part 2: HyperTextAccessibleBase: Add methods for child index/text offset conversion. r=eeejay https://hg.mozilla.org/integration/autoland/rev/b96051622689 part 3: Move CharacterCount to HyperTextAccessibleBase. r=eeejay https://hg.mozilla.org/integration/autoland/rev/be69e17a817a part 4: Move CaretOffset to HyperTextAccessibleBase. r=eeejay https://hg.mozilla.org/integration/autoland/rev/1910e46ed82c part 5: Move ConvertMagicOffset to HyperTextAccessibleBase. r=eeejay https://hg.mozilla.org/integration/autoland/rev/3d5b2d949109 part 6: Move TextSubstring to HyperTextAccessibleBase. r=eeejay https://hg.mozilla.org/integration/autoland/rev/b91cb9d7de75 part 7: Move CharAt to HyperTextAccessibleBase. r=eeejay https://hg.mozilla.org/integration/autoland/rev/0f6d7bf87aeb part 8: Move ToTextLeafPoint to HyperTextAccessibleBase. r=eeejay https://hg.mozilla.org/integration/autoland/rev/18f24e8c925c part 9: Add HyperTextAccessibleBase::TransformOffset. r=eeejay https://hg.mozilla.org/integration/autoland/rev/4138ff98e3c6 part 10: Move TextAtOffset's TextLeafPoint implementation to HyperTextAccessibleBase. r=eeejay https://hg.mozilla.org/integration/autoland/rev/f2ccbd5e0640 part 11: Move IsValidOffset/Range to HyperTextAccessibleBase. r=eeejay
Comment 15•3 years ago
|
||
Backed out for causing build bustages on DocAccessibleWrap.cpp.
Comment 16•3 years ago
|
||
Pushed by jteh@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/be33f25455cf part 1: Add hyperTextAccessibleBase class. r=eeejay https://hg.mozilla.org/integration/autoland/rev/ac706aab074a part 2: HyperTextAccessibleBase: Add methods for child index/text offset conversion. r=eeejay https://hg.mozilla.org/integration/autoland/rev/dff1962d50b9 part 3: Move CharacterCount to HyperTextAccessibleBase. r=eeejay https://hg.mozilla.org/integration/autoland/rev/2606771b0e56 part 4: Move CaretOffset to HyperTextAccessibleBase. r=eeejay https://hg.mozilla.org/integration/autoland/rev/992ae5fa0463 part 5: Move ConvertMagicOffset to HyperTextAccessibleBase. r=eeejay https://hg.mozilla.org/integration/autoland/rev/bd2fafcb66e5 part 6: Move TextSubstring to HyperTextAccessibleBase. r=eeejay https://hg.mozilla.org/integration/autoland/rev/e051c5fc35f1 part 7: Move CharAt to HyperTextAccessibleBase. r=eeejay https://hg.mozilla.org/integration/autoland/rev/0c38c5bf8468 part 8: Move ToTextLeafPoint to HyperTextAccessibleBase. r=eeejay https://hg.mozilla.org/integration/autoland/rev/6418e2c43224 part 9: Add HyperTextAccessibleBase::TransformOffset. r=eeejay https://hg.mozilla.org/integration/autoland/rev/3f79077627cc part 10: Move TextAtOffset's TextLeafPoint implementation to HyperTextAccessibleBase. r=eeejay https://hg.mozilla.org/integration/autoland/rev/888aa56bebb3 part 11: Move IsValidOffset/Range to HyperTextAccessibleBase. r=eeejay
Assignee | ||
Updated•3 years ago
|
Comment 17•3 years ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/be33f25455cf
https://hg.mozilla.org/mozilla-central/rev/ac706aab074a
https://hg.mozilla.org/mozilla-central/rev/dff1962d50b9
https://hg.mozilla.org/mozilla-central/rev/2606771b0e56
https://hg.mozilla.org/mozilla-central/rev/992ae5fa0463
https://hg.mozilla.org/mozilla-central/rev/bd2fafcb66e5
https://hg.mozilla.org/mozilla-central/rev/e051c5fc35f1
https://hg.mozilla.org/mozilla-central/rev/0c38c5bf8468
https://hg.mozilla.org/mozilla-central/rev/6418e2c43224
https://hg.mozilla.org/mozilla-central/rev/3f79077627cc
https://hg.mozilla.org/mozilla-central/rev/888aa56bebb3
Description
•