Last Comment Bug 783084 - [AccessFu] Enable accessfu when toggled in Gaia
: [AccessFu] Enable accessfu when toggled in Gaia
Status: RESOLVED FIXED
:
Product: Core
Classification: Components
Component: Disability Access APIs (show other bugs)
: Trunk
: All All
: -- normal (vote)
: mozilla17
Assigned To: Eitan Isaacson [:eeejay]
:
Mentors:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2012-08-15 13:53 PDT by Eitan Isaacson [:eeejay]
Modified: 2012-08-18 04:26 PDT (History)
1 user (show)
See Also:
Crash Signature:
(edit)
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---


Attachments
Activate AccessFu when screen reader is enabled in B2G. (1.90 KB, patch)
2012-08-15 13:57 PDT, Eitan Isaacson [:eeejay]
dbolter: review+
Details | Diff | Review

Description Eitan Isaacson [:eeejay] 2012-08-15 13:53:11 PDT

    
Comment 1 Eitan Isaacson [:eeejay] 2012-08-15 13:57:41 PDT
Created attachment 652219 [details] [diff] [review]
Activate AccessFu when screen reader is enabled in B2G.

Have not made a pull request for this in Gaia yet, but here is what happens on that end:
https://github.com/eeejay/gaia/tree/screenreader-option
Comment 2 David Bolter [:davidb] 2012-08-16 07:18:50 PDT
Comment on attachment 652219 [details] [diff] [review]
Activate AccessFu when screen reader is enabled in B2G.

Review of attachment 652219 [details] [diff] [review]:
-----------------------------------------------------------------

::: accessible/src/jsat/AccessFu.jsm
@@ +48,5 @@
>        Services.obs.addObserver(this, 'Accessibility:Settings', false);
>  
> +    if (Utils.MozBuildApp == 'b2g')
> +      aWindow.addEventListener(
> +        'ContentStart',

I was all "wuh?" then I saw this sent from b2g's shell.js :)

@@ +202,5 @@
>        }
> +      case 'mozContentEvent':
> +      {
> +        if (aEvent.detail.type == 'accessibility-screenreader') {
> +

nit: extraneous spacer line.

@@ +204,5 @@
> +      {
> +        if (aEvent.detail.type == 'accessibility-screenreader') {
> +
> +          let pref = aEvent.detail.enabled + 0;
> +          this._processPreferences(pref, pref);

I don't understand what + 0 does.
Comment 3 David Bolter [:davidb] 2012-08-17 13:21:22 PDT
Comment on attachment 652219 [details] [diff] [review]
Activate AccessFu when screen reader is enabled in B2G.

Sort of a funny r=me here since I already reviewed a patch that obsoletes this one but fine.
Comment 4 Eitan Isaacson [:eeejay] 2012-08-17 15:27:31 PDT
(In reply to David Bolter [:davidb] from comment #2)
> Comment on attachment 652219 [details] [diff] [review]
> Activate AccessFu when screen reader is enabled in B2G.
> 
> Review of attachment 652219 [details] [diff] [review]:
> -----------------------------------------------------------------
> 
> ::: accessible/src/jsat/AccessFu.jsm
> @@ +48,5 @@
> >        Services.obs.addObserver(this, 'Accessibility:Settings', false);
> >  
> > +    if (Utils.MozBuildApp == 'b2g')
> > +      aWindow.addEventListener(
> > +        'ContentStart',
> 
> I was all "wuh?" then I saw this sent from b2g's shell.js :)
> 

From Gaia, actually, see the github link above.

> @@ +202,5 @@
> >        }
> > +      case 'mozContentEvent':
> > +      {
> > +        if (aEvent.detail.type == 'accessibility-screenreader') {
> > +
> 
> nit: extraneous spacer line.
> 

Yupyup

> @@ +204,5 @@
> > +      {
> > +        if (aEvent.detail.type == 'accessibility-screenreader') {
> > +
> > +          let pref = aEvent.detail.enabled + 0;
> > +          this._processPreferences(pref, pref);
> 
> I don't understand what + 0 does.

Turns a boolean into an integer. Javascript!
Comment 6 Ryan VanderMeulen [:RyanVM] 2012-08-18 04:26:50 PDT
https://hg.mozilla.org/mozilla-central/rev/3131d6765a0e

Note You need to log in before you can comment on or make changes to this bug.