bug 1025931 - Crash java.lang.NullPointerException in in org.mozilla.gecko.GeckoAppShell.getContext r=snorp

This commit is contained in:
Brad Lassey 2014-06-26 09:37:47 -04:00
parent f4faa3590d
commit e0d05127b0
2 changed files with 4 additions and 0 deletions

View File

@ -2095,6 +2095,8 @@ public class GeckoAppShell
@WrapElementForJNI(allowMultithread = true)
public static Context getContext() {
if (sContextGetter == null)
return null;
return sContextGetter.getContext();
}

View File

@ -102,6 +102,8 @@ public class GeckoApplication extends Application
}
public void onActivityResume(GeckoActivityStatus activity) {
GeckoAppShell.setContextGetter(this);
if (mPausedGecko) {
GeckoAppShell.sendEventToGecko(GeckoEvent.createAppForegroundingEvent());
mPausedGecko = false;