Closed
Bug 1469877
Opened 6 years ago
Closed 6 years ago
XUL accessible highlighter position is incorrect at different zoom levels
Categories
(DevTools :: Accessibility Tools, enhancement)
DevTools
Accessibility Tools
Tracking
(firefox63 fixed)
RESOLVED
FIXED
Firefox 63
Tracking | Status | |
---|---|---|
firefox63 | --- | fixed |
People
(Reporter: mtigley, Assigned: mtigley, Mentored)
References
Details
Attachments
(1 file)
Bounds positioning is incorrect when zoom level is manipulated while using the xul-accessible highlighter. The reason for this is the highlighter calculates zoom level in relation to the top-level window object. Instead, we should calculate the zoom based on the parent window of an accessible object.
Assignee | ||
Updated•6 years ago
|
Assignee: nobody → mtigley
Status: NEW → ASSIGNED
Comment hidden (mozreview-request) |
Comment 2•6 years ago
|
||
mozreview-review |
Comment on attachment 8986882 [details] Bug 1469877 - XUL accessible highlighter position is incorrect at different zoom levels. https://reviewboard.mozilla.org/r/252120/#review258820 Looks good! Just a couple of nits, see below: ::: devtools/server/actors/highlighters/utils/accessibility.js:32 (Diff revision 1) > * @return {Object|null} Returns, if available, positioning and bounds information for > * the accessible object. > */ > -function getBounds(win, { x, y, w, h }) { > - const { mozInnerScreenX, mozInnerScreenY, scrollX, scrollY } = win; > - const zoom = getCurrentZoom(win); > +function getBounds(win, { x, y, w, h, zoom }) { > + let { mozInnerScreenX, mozInnerScreenY, scrollX, scrollY } = win; > + const zoomFactor = zoom || getCurrentZoom(win); Perhaps in order to make it a more visible override of zoomFactor, lets just set zoomFactor here as before, e.g. ```let zoomFact = getCurrentZoom(win);``` and then inside the if statement just add ```zoomFactor = zoom;``` right before modifying inner and scroll values. ::: devtools/server/actors/highlighters/xul-accessible.js:83 (Diff revision 1) > * > * @return {Object|null} Returns, if available, positioning and bounds > * information for the accessible object. > */ > get _bounds() { > - return getBounds(this.win, this.options); > + const zoom = getCurrentZoom(this.currentNode); Lets add a comment here stating that zoom for top level browser window does not change and only inner frames do, thus our best shot is to get the zoom level of the parent window for currentNode. ::: devtools/server/actors/highlighters/xul-accessible.js:85 (Diff revision 1) > * information for the accessible object. > */ > get _bounds() { > - return getBounds(this.win, this.options); > + const zoom = getCurrentZoom(this.currentNode); > + > + return getBounds(this.win, {...this.options, zoom}); Niy: add a space after { and before } when using spread syntax.
Attachment #8986882 -
Flags: review?(yzenevich) → review+
Updated•6 years ago
|
Attachment #8986882 -
Flags: review?(pbrosset)
Comment hidden (mozreview-request) |
Comment 4•6 years ago
|
||
mozreview-review |
Comment on attachment 8986882 [details] Bug 1469877 - XUL accessible highlighter position is incorrect at different zoom levels. https://reviewboard.mozilla.org/r/252120/#review259180
Attachment #8986882 -
Flags: review?(pbrosset) → review+
Assignee | ||
Comment 5•6 years ago
|
||
Try results: https://treeherder.mozilla.org/#/jobs?repo=try&revision=e2ec2f830f6cea9681826514ab8f60fe88ac860b&selectedJob=184828540 Intermittent failures that are unrelated to the bug.
Assignee | ||
Updated•6 years ago
|
Keywords: checkin-needed
Comment 6•6 years ago
|
||
I couldn't land your patch. mtigley: Please set the issues opened by the reviewer as fixed by commit so review board allows to land them. Thank you.
Flags: needinfo?(mtigley)
Keywords: checkin-needed
Assignee | ||
Comment 7•6 years ago
|
||
mozreview-review |
Comment on attachment 8986882 [details] Bug 1469877 - XUL accessible highlighter position is incorrect at different zoom levels. https://reviewboard.mozilla.org/r/252120/#review260010 Fixed issues.
Attachment #8986882 -
Flags: review+
Assignee | ||
Comment 8•6 years ago
|
||
Set issues on reviewboard as fixed. Thank you!
Assignee | ||
Updated•6 years ago
|
Keywords: checkin-needed
Pushed by aciure@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/50c30489f378 XUL accessible highlighter position is incorrect at different zoom levels. r=pbro,yzen
Keywords: checkin-needed
Comment 10•6 years ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/50c30489f378
Status: ASSIGNED → RESOLVED
Closed: 6 years ago
status-firefox63:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → Firefox 63
Assignee | ||
Comment 11•6 years ago
|
||
Clearing needinfo because it is landed.
You need to log in
before you can comment on or make changes to this bug.
Description
•