Closed Bug 819744 Opened 12 years ago Closed 10 years ago

Delay the light sensor response in screen_manager.js

Categories

(Firefox OS Graveyard :: Gaia::System, defect)

defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED
2.2 S5 (6feb)

People

(Reporter: timdream, Assigned: gpgreen)

Details

(Whiteboard: [perf-reviewed])

Attachments

(1 file, 1 obsolete file)

46 bytes, text/x-github-pull-request
timdream
: review+
timdream
: feedback+
Details | Review
External user feedback: currently the light sensor will brighten the screen and dim again simply with the finger accidentally move over the light sensor. It should come with a delay to prevent that kind of response but we shouldn't delay too much for the user to think it's ill-responsive.
Whiteboard: [perf-reviewed]
Attached file pull request for light sensor delay (obsolete) —
Added a delay for light sensor response. I don't have a device to test against v2.2. I have tested the patch on a device running the v2.1 branch.
Attachment #8547337 - Flags: review?(timdream)
Comment on attachment 8547337 [details] [review] pull request for light sensor delay Hi gpgreen, It's very nice of you to organize the flow into different states. However, screen_manager.js is getting to large and I would like to prevent it to become bigger first. Please split the code into another class usable by ScreenManager instead. Your patch does not come with any unit test either. Having a separate class created will help you to do that too. Thanks!
Attachment #8547337 - Flags: review?(timdream) → feedback+
So do you want to move the just the automatic display adjustment to the new class, or more than that?
Updated patch to refactor code and add unit test
Attachment #8547337 - Attachment is obsolete: true
Attachment #8554198 - Flags: review?(timdream)
Comment on attachment 8554198 [details] [review] pull request for light sensor delay Excellent clean up! Thanks for the patch. I've left a few comments on Github. There isn't a lot to fix except for the interface and the timer part. The ones marked with "nit" are really optional improvements so it's up to you if you want to fix them all.
Attachment #8554198 - Flags: review?(timdream) → feedback+
Comment on attachment 8554198 [details] [review] pull request for light sensor delay Updated the pull request after review.
Attachment #8554198 - Flags: review?(timdream)
Comment on attachment 8554198 [details] [review] pull request for light sensor delay Please squash the commits into one commit. nits are optional (since they are not flagged by jshint let's not spend time manually go and forth) After that, please set checkin-needed in the Bugzilla Keyword field and it will be merged. Thanks!
Attachment #8554198 - Flags: review?(timdream) → review+
I updated the pull request, cannot change the Keyword field. I assume that is because the bug hasn't been assigned to me.
Flags: needinfo?(timdream)
I've hit re-run on these intermittents, patch should land if we can sure of the errors are not related. https://treeherder.mozilla.org/#/jobs?repo=gaia-try&revision=fbf969956442
Assignee: nobody → gpgreen
Status: NEW → ASSIGNED
Flags: needinfo?(timdream)
Keywords: checkin-needed
Status: ASSIGNED → RESOLVED
Closed: 10 years ago
Keywords: checkin-needed
Resolution: --- → FIXED
Target Milestone: --- → 2.2 S5 (6feb)
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: