Commit 13458a61 authored by ankit2.kumar's avatar ankit2.kumar Committed by Commit bot

Remove focus on back key press if focus is on url bar.

Handlind back key event and clearing focus of url bar
and retaining focus to content view.

BUG=

Review URL: https://codereview.chromium.org/540853002

Cr-Commit-Position: refs/heads/master@{#294105}
parent 668c5c10
...@@ -166,6 +166,16 @@ public class Shell extends LinearLayout { ...@@ -166,6 +166,16 @@ public class Shell extends LinearLayout {
} }
} }
}); });
mUrlTextView.setOnKeyListener(new OnKeyListener() {
@Override
public boolean onKey(View v, int keyCode, KeyEvent event) {
if (keyCode == KeyEvent.KEYCODE_BACK) {
mContentViewCore.getContainerView().requestFocus();
return true;
}
return false;
}
});
} }
/** /**
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment