Last Comment Bug 698436 - Switch to custom spinner
: Switch to custom spinner
Status: VERIFIED FIXED
:
Product: Firefox for Android
Classification: Client Software
Component: General (show other bugs)
: unspecified
: ARM Android
: P3 normal (vote)
: ---
Assigned To: Sriram Ramasubramanian [:sriram]
:
Mentors:
Depends on:
Blocks: 698042 699137
  Show dependency treegraph
 
Reported: 2011-10-31 08:00 PDT by Kevin Brosnan [:kbrosnan]
Modified: 2012-01-09 15:25 PST (History)
3 users (show)
See Also:
Crash Signature:
(edit)
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---
fixed
11+


Attachments
Firefox activity spinner assets (5.08 KB, application/zip)
2011-11-02 11:44 PDT, Ian Barlow (:ibarlow)
no flags Details
Firefox activity spinner assets (83.45 KB, application/zip)
2011-11-02 13:20 PDT, Ian Barlow (:ibarlow)
no flags Details
Patch (65.04 KB, patch)
2011-11-02 15:33 PDT, Sriram Ramasubramanian [:sriram]
no flags Details | Diff | Review
Patch 2: Using one view for favicon/progress (64.92 KB, patch)
2011-11-02 15:53 PDT, Sriram Ramasubramanian [:sriram]
mark.finkle: review+
Details | Diff | Review
progress_spinner.xml (1.62 KB, text/xml)
2011-11-02 18:11 PDT, Sriram Ramasubramanian [:sriram]
no flags Details

Description Kevin Brosnan [:kbrosnan] 2011-10-31 08:00:01 PDT
The spinner is white making it very hard to notice.

HTC Desire S
Android 2.3.5
HTC Sense 3.0

HTC G2 (Desire Z)
Android 2.2
Comment 1 Kevin Brosnan [:kbrosnan] 2011-10-31 08:07:45 PDT
Video @ http://people.mozilla.org/~kbrosnan/tmp/698436.webm
Comment 2 Aaron Train [:aaronmt] 2011-10-31 08:10:02 PDT
This may be fixed via comment #3 in bug 698042
Comment 3 Mark Finkle (:mfinkle) (use needinfo?) 2011-10-31 08:21:46 PDT
(In reply to Aaron Train [:aaronmt] from comment #2)
> This may be fixed via comment #3 in bug 698042

Yes it will, so I am morphing this bug
Comment 4 Ian Barlow (:ibarlow) 2011-11-02 11:44:43 PDT
Created attachment 571395 [details]
Firefox activity spinner assets
Comment 5 Ian Barlow (:ibarlow) 2011-11-02 13:20:23 PDT
Created attachment 571433 [details]
Firefox activity spinner assets

New assets, with a frame for each stage of the spinner animation
Comment 6 Sriram Ramasubramanian [:sriram] 2011-11-02 15:33:47 PDT
Created attachment 571480 [details] [diff] [review]
Patch

This patch adds a frame animation based spinner to indicate the progress.
The old ProgressBar is replaced with an ImageButton as the ProgressBar didn't provide image scaling options.
This uses two ImageButton's and switches between them based on whether a progress has to be showed or not.

Only one set of images are added as of now. The MDPI versions will be added when the folders for drawables are decided for menus and tabs-list.

One catch with the animation:
The animation cannot start initially when start() is called from onCreate. [http://stackoverflow.com/questions/2785336/starting-frame-by-frame-animation/2790930#2790930] This needs to be called from onWindowFocusChanged().
However, https://bugzilla.mozilla.org/show_bug.cgi?id=699137 requires not to show the ProgressBar initially. This solves the issue with the animation not starting initially.
Comment 7 Sriram Ramasubramanian [:sriram] 2011-11-02 15:53:27 PDT
Created attachment 571489 [details] [diff] [review]
Patch 2: Using one view for favicon/progress

This patch uses one ImageButton to show both the favicon and the progress. This is good in terms of number of views that needs to be drawn by android.
Comment 8 Mark Finkle (:mfinkle) (use needinfo?) 2011-11-02 16:48:50 PDT
Comment on attachment 571489 [details] [diff] [review]
Patch 2: Using one view for favicon/progress

Let's try this approach
Comment 9 Sriram Ramasubramanian [:sriram] 2011-11-02 18:11:30 PDT
Created attachment 571529 [details]
progress_spinner.xml

This had been left out of Patch accidentally.
Comment 10 Mark Finkle (:mfinkle) (use needinfo?) 2011-11-02 18:32:41 PDT
added the missing file and pushed
https://hg.mozilla.org/projects/birch/rev/0571e6fb4b44
Comment 11 Aaron Train [:aaronmt] 2011-11-03 06:08:18 PDT
20111103040334
http://hg.mozilla.org/projects/birch/rev/c09a52af4cd8
Samsung Nexus S (Android 2.3.6)

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