Closed Bug 1359419 Opened 7 years ago Closed 7 years ago

[geckoview] Add GeckoView.preload(), used to start Gecko before we have a GeckoView

Categories

(Core Graveyard :: Embedding: APIs, enhancement)

enhancement
Not set
normal

Tracking

(firefox55 fixed)

RESOLVED FIXED
mozilla55
Tracking Status
firefox55 --- fixed

People

(Reporter: snorp, Unassigned)

Details

Attachments

(1 file)

      No description provided.
Comment on attachment 8861427 [details]
Bug 1359419 - Add GeckoView.preload()

https://reviewboard.mozilla.org/r/133408/#review136354

::: mobile/android/geckoview/src/main/java/org/mozilla/gecko/GeckoView.java:270
(Diff revision 1)
>  
>          final GeckoViewSettings newSettings = new GeckoViewSettings(settings, getEventDispatcher());
>          init(context, newSettings);
>      }
>  
> -    private void init(final Context context, final GeckoViewSettings settings) {
> +    public static void preload(Context context) {

Can be final.
Attachment #8861427 - Flags: review?(esawin) → review+
Comment on attachment 8861427 [details]
Bug 1359419 - Add GeckoView.preload()

https://reviewboard.mozilla.org/r/133408/#review136436

::: mobile/android/geckoview/src/main/java/org/mozilla/gecko/GeckoView.java:277
(Diff revision 1)
> +            context.getApplicationContext());
> +
>          if (GeckoAppShell.getApplicationContext() == null) {
>              GeckoAppShell.setApplicationContext(context.getApplicationContext());
>          }
> +        GeckoAppShell.setApplicationContext(context.getApplicationContext());

`setApplicationContext` is called twice here
https://hg.mozilla.org/mozilla-central/rev/0a18abb7a8f3
Status: NEW → RESOLVED
Closed: 7 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla55
Product: Core → Core Graveyard
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: