Closed Bug 871978 Opened 8 years ago Closed 8 years ago

Incorrect usage of SwitchPreference in pre-v14 Android

Categories

(Firefox for Android :: General, defect)

23 Branch
ARM
Android
defect
Not set
normal

Tracking

()

VERIFIED FIXED
Firefox 23
Tracking Status
firefox23 + verified
firefox24 --- unaffected

People

(Reporter: TeoVermesan, Assigned: liuche)

References

Details

Attachments

(3 files)

Tested with:
Build: Firefox for Android 23.0a1(2013-05-14)
Device: Acer Iconia A500 
OS: Android 3.2.1

Steps to reproduce:
1. Open Firefox
2. Go to Settings > Privacy&Security > Data Choices

Actual results:
- A blank page is displayed

Expected results:
- The following settings should appear
*Telemetry
*Nightly Health Report
*Nightly Crash Reporter

Note: Going to home screen, a pop-up appears "Activity Nightly(in application Nightly) is not responding"
Assignee: nobody → liuche
Can you attach a screenshot?
Flags: needinfo?(teodora.vermesan)
Blocks: 833625
Flags: needinfo?(teodora.vermesan)
Can you attach a log-cat when you try and access data options?
Attached file ddms logs
Attaching ddms logs
Looks like http://developer.android.com/reference/android/preference/SwitchPreference.html was introduced in API Level 14; we need some compatibility with lower API levels.
We do have a fallback. It just only applies if we aren't using fragments. Honeycomb is the red headed stepchild here.
Ah, I see what's happening. There's an xml file with SwitchPreference that should be in xml-14, but is actually in xml-11.

24 is actually not affected, because after talking with ibarlow yesterday morning, we decided to remove the SwitchPreference, so bug 862116 fixes that.

I prepare a patch for Aurora that removes xml-v11 as well.
Summary: Page displayed blank when going to Settings > Privacy&Security > Data Choices on Honeycomb → Incorrect usage of SwitchPreference in pre-v14 Android
Running an aurora build currently, will request review when tested.
Hi Teodora, can you try this build on your device, to see if the problem still exists in this build? It will install as a Nightly app, not an Aurora one.

http://people.mozilla.com/~liuche/bug-871978/no-switch-nightly.apk

Alternatively, can QA check that this fixes the bug on an Android device of the same version as the reporters? This should be any device between v11 and v13, inclusive.
Flags: needinfo?(teodora.vermesan)
Sorry, I meant this will install as an Aurora app instead of a Nightly one.
(In reply to Chenxia Liu [:liuche] from comment #9)
> Hi Teodora, can you try this build on your device, to see if the problem
> still exists in this build? It will install as a Nightly app, not an Aurora
> one.
> 
> http://people.mozilla.com/~liuche/bug-871978/no-switch-nightly.apk

I cannot reproduce the issue on the given build. Please let me know if I can help furthermore.
Flags: needinfo?(teodora.vermesan)
Comment on attachment 749414 [details] [diff] [review]
Part 1: Remove SwitchPreference xml preference screen v1

This patch removes the SwitchPreference usage from the preferences xml, as discussed with ibarlow. I will flag for uplift to Aurora after review.
Attachment #749414 - Flags: review?(sriram)
Comment on attachment 749414 [details] [diff] [review]
Part 1: Remove SwitchPreference xml preference screen v1

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

Looks good to me.
Attachment #749414 - Flags: review?(sriram) → review+
Comment on attachment 749414 [details] [diff] [review]
Part 1: Remove SwitchPreference xml preference screen v1

[Approval Request Comment]
Bug caused by (feature/regressing bug #): Bug 833625
User impact if declined: Users of Android v11-v13 will see an "activity not responding" when navigating to control telemetry/FHR/crashreporter upload settings.
Testing completed (on m-c, etc.): softvisio testing of attached Aurora patch; patch is currently live in Nightly 24 (bug 862116).
Risk to taking this patch (and alternatives if risky): Low, only code removal, no new behavior.
String or IDL/UUID changes made by this patch: none
Attachment #749414 - Flags: approval-mozilla-aurora?
Attachment #749414 - Flags: approval-mozilla-aurora? → approval-mozilla-aurora+
Status: NEW → ASSIGNED
Landing on trunk?
This only affected Fx23 - bug 862116 independently landed on trunk earlier and resolved this on Fx24 (see comment 7).
Status: ASSIGNED → RESOLVED
Closed: 8 years ago
Resolution: --- → FIXED
Teodora, can you verify this on Aurora with your Honeycomb tablet?
Flags: needinfo?(teodora.vermesan)
Keywords: verifyme
Target Milestone: --- → Firefox 23
The Data Choices setting page is not blank anymore. It is displayed correctly on Firefox for Android 23.0a2(2013-05-28) on Acer Iconia A500 (Android 3.2.1)
Flags: needinfo?(teodora.vermesan)
Marking bug as verified based on comment 19.
Status: RESOLVED → VERIFIED
Keywords: verifyme
You need to log in before you can comment on or make changes to this bug.