Closed
Bug 1042937
Opened 10 years ago
Closed 10 years ago
Provide visual feedback while search results are loading
Categories
(Firefox for Android Graveyard :: Search Activity, defect, P1)
Tracking
(firefox34 verified)
VERIFIED
FIXED
Firefox 34
Tracking | Status | |
---|---|---|
firefox34 | --- | verified |
People
(Reporter: Margaret, Assigned: eedens)
References
Details
Attachments
(3 files, 4 obsolete files)
160.63 KB,
image/png
|
Details | |
195.08 KB,
image/png
|
Details | |
6.63 KB,
patch
|
Details | Diff | Splinter Review |
This issue came up at our check-in meeting this morning, but I'm unclear on what exactly we want to implement as a solution.
ibarlow or antlam, could you elaborate?
Flags: needinfo?(ibarlow)
Flags: needinfo?(alam)
Comment 1•10 years ago
|
||
We just want to display some kind of preloader animation while the results page is coming in. Anthony is playing around with some designs, but even the 'orange laser show' animation under the title bar could be a good placeholder to start with.
Flags: needinfo?(ibarlow)
Comment 2•10 years ago
|
||
I've been working on this today, hopefully I'll have something to post soon. But like Ian said, standard Android loading bar could be a good place holder for the time being (right above the white content area).
Leaving NI on..
Reporter | ||
Updated•10 years ago
|
Priority: -- → P1
Assignee | ||
Updated•10 years ago
|
Assignee: margaret.leibovic → eric.edens
Assignee | ||
Comment 3•10 years ago
|
||
I tried the horizontal progress bar, but it was floating in the middle of nowhere (since the background / toolbar are all the same color)
So, as a placeholder, this adds a spinner to the top right of the screen.
Attachment #8462029 -
Flags: feedback?(margaret.leibovic)
Comment 4•10 years ago
|
||
Hey Eric,
Maybe this mock will help you out with the position. I have it 68dp from the bottom of the top notification bar and it's 2 dp in height.
Flags: needinfo?(alam)
Comment 5•10 years ago
|
||
I'm also experimenting with a centered loading animation since that area that expands from the suggestion stage before this step will direct user attention to that area anyways (plus they can't really do anything until it's loaded anyways)
Comment 6•10 years ago
|
||
attaching current status from the build Eric sent as reference.
Assignee | ||
Comment 7•10 years ago
|
||
Changes:
- Spinner is now orange bar
Attachment #8462029 -
Attachment is obsolete: true
Attachment #8462029 -
Flags: feedback?(margaret.leibovic)
Attachment #8462231 -
Flags: feedback?(margaret.leibovic)
Assignee | ||
Comment 8•10 years ago
|
||
Updated screenshot after talking with antlam on irc.
Attachment #8462223 -
Attachment is obsolete: true
Reporter | ||
Comment 9•10 years ago
|
||
Comment on attachment 8462231 [details] [diff] [review]
bug-1042937-wip.v2.patch
Review of attachment 8462231 [details] [diff] [review]:
-----------------------------------------------------------------
Looking good!
::: mobile/android/search/res/layout/search_fragment_post_search.xml
@@ +1,5 @@
> <!-- This Source Code Form is subject to the terms of the Mozilla Public
> - License, v. 2.0. If a copy of the MPL was not distributed with this
> - file, You can obtain one at http://mozilla.org/MPL/2.0/. -->
>
> +<FrameLayout
If you're using a FrameLayout here, that means that the progress bar is actually getting drawn on top of the web view. It may look good for now, but we'll need to watch out for this if we switch to another search engine that doesn't have as much padding at the top of its result view.
A safer bet would probably be to use a LinearLayout, but that would push the WebView content down 3dp.
@@ +17,5 @@
> + style="@android:style/Widget.ProgressBar.Horizontal"
> + android:layout_width="match_parent"
> + android:layout_height="wrap_content"
> + android:maxHeight="@dimen/progress_bar_height"
> + android:minHeight="@dimen/progress_bar_height"
Why not just set android:layout_height directly to progress_bar_height?
Attachment #8462231 -
Flags: feedback?(margaret.leibovic) → feedback+
Assignee | ||
Comment 10•10 years ago
|
||
(In reply to :Margaret Leibovic from comment #9)
> Comment on attachment 8462231 [details] [diff] [review]
> bug-1042937-wip.v2.patch
>
> Review of attachment 8462231 [details] [diff] [review]:
> -----------------------------------------------------------------
>
> Looking good!
>
> ::: mobile/android/search/res/layout/search_fragment_post_search.xml
> @@ +1,5 @@
> > <!-- This Source Code Form is subject to the terms of the Mozilla Public
> > - License, v. 2.0. If a copy of the MPL was not distributed with this
> > - file, You can obtain one at http://mozilla.org/MPL/2.0/. -->
> >
> > +<FrameLayout
>
> If you're using a FrameLayout here, that means that the progress bar is
> actually getting drawn on top of the web view. It may look good for now, but
> we'll need to watch out for this if we switch to another search engine that
> doesn't have as much padding at the top of its result view.
>
> A safer bet would probably be to use a LinearLayout, but that would push the
> WebView content down 3dp.
Sounds good
>
> @@ +17,5 @@
> > + style="@android:style/Widget.ProgressBar.Horizontal"
> > + android:layout_width="match_parent"
> > + android:layout_height="wrap_content"
> > + android:maxHeight="@dimen/progress_bar_height"
> > + android:minHeight="@dimen/progress_bar_height"
>
> Why not just set android:layout_height directly to progress_bar_height?
From what I read, I thought I had to use the min/max height, but you're totally right. Using layout_height works (and is a lot cleaner).
Attachment #8462231 -
Attachment is obsolete: true
Attachment #8462243 -
Flags: review?(margaret.leibovic)
Reporter | ||
Comment 11•10 years ago
|
||
Comment on attachment 8462243 [details] [diff] [review]
bug-1042937-fix.patch
Review of attachment 8462243 [details] [diff] [review]:
-----------------------------------------------------------------
Nice, looks good.
::: mobile/android/search/res/values/search_dimens.xml
@@ +14,5 @@
> <!-- To create the padding we see around the content of each
> card, we need to account for the padding of the background -->
> <dimen name="card_padding_x">38dp</dimen>
> <dimen name="card_padding_y">23dp</dimen>
> + <dimen name="progress_bar_height">3dp</dimen>
Nit: I would put a blank line above this. Maybe also move it up higher below the search_bar_height declaration (organizing the dimen declarations by parts of the UI where they're used).
Attachment #8462243 -
Flags: review?(margaret.leibovic) → review+
Reporter | ||
Comment 12•10 years ago
|
||
(Before we land this, make sure you share a build with antlam to get his approval.)
Comment 13•10 years ago
|
||
(In reply to Eric Edens [:eedens] from comment #8)
> Created attachment 8462234 [details]
> Screenshot_2014-07-24-17-03-47.png
>
> Updated screenshot after talking with antlam on irc.
This is better! I'm still working on the final one but I think this will do for now
Assignee | ||
Comment 14•10 years ago
|
||
Re-arranged order of dimensions.
Attachment #8462243 -
Attachment is obsolete: true
Comment 15•10 years ago
|
||
Just wanted to check and make sure we're using the indeterminate 'laser show' progress bar, and not the linear one?
Assignee | ||
Comment 16•10 years ago
|
||
Hey Ian --
It's determinate -- when you said "'orange laser show' animation under the title bar", I thought you were referring to the orange loader that we use in fennec under the title bar, which is determinate is well.
I'll swap this out and post a new patch.
Assignee | ||
Comment 17•10 years ago
|
||
Alright, to bring the bug up to speed:
- 'Laser show' refers to the home panel's GeckoSwipeRefreshLayout, which is a forked from compat v4 library's SwipeProgressBar.
- SwipeProgressBar does not extend the Android view -- it does its own drawing on a canvas
- Drawing / layout / state updates are driven by (Gecko)SwipeRefreshLayout.
- In order to use SwipeProgressBar here, we'd need to write our own ViewGroup to drive its layout and drawing.
Since we're waiting on the final designs, and this would be a placeholder anyway, we should land this patch and revisit when the final designs are finished.
Reporter | ||
Comment 18•10 years ago
|
||
Given eedens's latest comment, I landed this patch as-is for now:
https://hg.mozilla.org/integration/fx-team/rev/b5ae1c999f27
eedens, please file another bug to iterate on the design here. I applied this patch locally to test, and while I appreciated getting some feedback that the WebView was loading, the progress bar feels pretty clunky, so this needs some more design love.
Assignee | ||
Comment 19•10 years ago
|
||
Merged into GH: https://github.com/ericedens/FirefoxSearch/pull/33
I created a followup, bug 1044262, to make things less clunky :) . It's assigned to alam for the designs -- alam, you can pass it back when it's ready!
Comment 20•10 years ago
|
||
Status: NEW → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 34
Comment 21•10 years ago
|
||
Verified as fixed in build 34.0a1 (2014-08-04);
Device: Samsung Galaxy Nexus (Android 4.2.1).
Status: RESOLVED → VERIFIED
status-firefox34:
--- → verified
Updated•7 years ago
|
Product: Firefox for Android → Firefox for Android Graveyard
You need to log in
before you can comment on or make changes to this bug.
Description
•