Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1286)

Unified Diff: content/public/android/java/src/org/chromium/content/browser/ContentViewClient.java

Issue 744453002: Fix a bunch of Java Checkstyle issues. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: NeedsBraces to info Created 6 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: content/public/android/java/src/org/chromium/content/browser/ContentViewClient.java
diff --git a/content/public/android/java/src/org/chromium/content/browser/ContentViewClient.java b/content/public/android/java/src/org/chromium/content/browser/ContentViewClient.java
index d18b1df8b7a47db5d403319619309fa4ec8ef6ad..790fea00ae476da6cdc18e14cffbc9c353b490c4 100644
--- a/content/public/android/java/src/org/chromium/content/browser/ContentViewClient.java
+++ b/content/public/android/java/src/org/chromium/content/browser/ContentViewClient.java
@@ -57,10 +57,9 @@ public class ContentViewClient {
if (!shouldPropagateKey(keyCode)) return true;
// We also have to intercept some shortcuts before we send them to the ContentView.
- if (event.isCtrlPressed() && (
- keyCode == KeyEvent.KEYCODE_TAB ||
- keyCode == KeyEvent.KEYCODE_W ||
- keyCode == KeyEvent.KEYCODE_F4)) {
+ if (event.isCtrlPressed() && (keyCode == KeyEvent.KEYCODE_TAB
+ || keyCode == KeyEvent.KEYCODE_W
+ || keyCode == KeyEvent.KEYCODE_F4)) {
return true;
}
@@ -193,18 +192,18 @@ public class ContentViewClient {
* for instance, AKEYCODE_MEDIA_* will be dispatched to webkit*.
*/
public static boolean shouldPropagateKey(int keyCode) {
- if (keyCode == KeyEvent.KEYCODE_MENU ||
- keyCode == KeyEvent.KEYCODE_HOME ||
- keyCode == KeyEvent.KEYCODE_BACK ||
- keyCode == KeyEvent.KEYCODE_CALL ||
- keyCode == KeyEvent.KEYCODE_ENDCALL ||
- keyCode == KeyEvent.KEYCODE_POWER ||
- keyCode == KeyEvent.KEYCODE_HEADSETHOOK ||
- keyCode == KeyEvent.KEYCODE_CAMERA ||
- keyCode == KeyEvent.KEYCODE_FOCUS ||
- keyCode == KeyEvent.KEYCODE_VOLUME_DOWN ||
- keyCode == KeyEvent.KEYCODE_VOLUME_MUTE ||
- keyCode == KeyEvent.KEYCODE_VOLUME_UP) {
+ if (keyCode == KeyEvent.KEYCODE_MENU
+ || keyCode == KeyEvent.KEYCODE_HOME
+ || keyCode == KeyEvent.KEYCODE_BACK
+ || keyCode == KeyEvent.KEYCODE_CALL
+ || keyCode == KeyEvent.KEYCODE_ENDCALL
+ || keyCode == KeyEvent.KEYCODE_POWER
+ || keyCode == KeyEvent.KEYCODE_HEADSETHOOK
+ || keyCode == KeyEvent.KEYCODE_CAMERA
+ || keyCode == KeyEvent.KEYCODE_FOCUS
+ || keyCode == KeyEvent.KEYCODE_VOLUME_DOWN
+ || keyCode == KeyEvent.KEYCODE_VOLUME_MUTE
+ || keyCode == KeyEvent.KEYCODE_VOLUME_UP) {
return false;
}
return true;

Powered by Google App Engine
This is Rietveld 408576698