CB-8510 Move requestFocusFromTouch into createViews from init()

Makes more sense there since it's view-creation-related
This commit is contained in:
Andrew Grieve 2015-02-25 12:14:39 -05:00
parent 087ec11e6a
commit d99856c52b
2 changed files with 2 additions and 3 deletions

View File

@ -146,8 +146,6 @@ public class CordovaActivity extends Activity {
if ("media".equals(volumePref.toLowerCase(Locale.ENGLISH))) {
setVolumeControlStream(AudioManager.STREAM_MUSIC);
}
appView.getView().requestFocusFromTouch();
}
@SuppressWarnings("deprecation")
@ -189,6 +187,7 @@ public class CordovaActivity extends Activity {
int backgroundColor = preferences.getInteger("BackgroundColor", Color.BLACK);
root.setBackgroundColor(backgroundColor);
appView.getView().requestFocusFromTouch();
}
/**

View File

@ -278,8 +278,8 @@ public class CordovaWebViewImpl implements CordovaWebView {
@Deprecated
public void hideCustomView() {
// This code is adapted from the original Android Browser code, licensed under the Apache License, Version 2.0
Log.d(TAG, "Hiding Custom View");
if (mCustomView == null) return;
Log.d(TAG, "Hiding Custom View");
// Hide the custom view.
mCustomView.setVisibility(View.GONE);