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

Side by Side Diff: content/browser/android/content_startup_flags.cc

Issue 481683003: Support for Adaptive Handle Orientation (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: changed as per jdduke comments Created 5 years, 3 months 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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "content/browser/android/content_startup_flags.h" 5 #include "content/browser/android/content_startup_flags.h"
6 6
7 #include "base/android/build_info.h" 7 #include "base/android/build_info.h"
8 #include "base/base_switches.h" 8 #include "base/base_switches.h"
9 #include "base/command_line.h" 9 #include "base/command_line.h"
10 #include "base/logging.h" 10 #include "base/logging.h"
(...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after
58 58
59 parsed_command_line->AppendSwitch(cc::switches::kEnableBeginFrameScheduling); 59 parsed_command_line->AppendSwitch(cc::switches::kEnableBeginFrameScheduling);
60 60
61 parsed_command_line->AppendSwitch(switches::kEnablePinch); 61 parsed_command_line->AppendSwitch(switches::kEnablePinch);
62 parsed_command_line->AppendSwitch(switches::kEnableOverlayScrollbar); 62 parsed_command_line->AppendSwitch(switches::kEnableOverlayScrollbar);
63 parsed_command_line->AppendSwitch(switches::kValidateInputEventStream); 63 parsed_command_line->AppendSwitch(switches::kValidateInputEventStream);
64 64
65 // TODO(jdduke): Use the proper SDK version when available, crbug.com/466749. 65 // TODO(jdduke): Use the proper SDK version when available, crbug.com/466749.
66 if (base::android::BuildInfo::GetInstance()->sdk_int() > 66 if (base::android::BuildInfo::GetInstance()->sdk_int() >
67 base::android::SDK_VERSION_LOLLIPOP_MR1) { 67 base::android::SDK_VERSION_LOLLIPOP_MR1) {
68 parsed_command_line->AppendSwitch(
69 switches::kEnableAdaptiveHandleOrientation);
jdduke (slow) 2015/09/09 22:19:50 Can we just not add the flag here? I'd much prefer
AviD 2015/09/10 06:06:13 Done.
68 parsed_command_line->AppendSwitch(switches::kEnableLongpressDragSelection); 70 parsed_command_line->AppendSwitch(switches::kEnableLongpressDragSelection);
69 parsed_command_line->AppendSwitchASCII( 71 parsed_command_line->AppendSwitchASCII(
70 switches::kTouchTextSelectionStrategy, "direction"); 72 switches::kTouchTextSelectionStrategy, "direction");
71 } 73 }
72 74
73 // There is no software fallback on Android, so don't limit GPU crashes. 75 // There is no software fallback on Android, so don't limit GPU crashes.
74 parsed_command_line->AppendSwitch(switches::kDisableGpuProcessCrashLimit); 76 parsed_command_line->AppendSwitch(switches::kDisableGpuProcessCrashLimit);
75 77
76 // On legacy low-memory devices the behavior has not been studied with regard 78 // On legacy low-memory devices the behavior has not been studied with regard
77 // to having an extra process with similar priority as the foreground renderer 79 // to having an extra process with similar priority as the foreground renderer
(...skipping 25 matching lines...) Expand all
103 } 105 }
104 106
105 cc::LayerSettings layer_settings; 107 cc::LayerSettings layer_settings;
106 if (parsed_command_line->HasSwitch( 108 if (parsed_command_line->HasSwitch(
107 switches::kEnableAndroidCompositorAnimationTimelines)) 109 switches::kEnableAndroidCompositorAnimationTimelines))
108 layer_settings.use_compositor_animation_timelines = true; 110 layer_settings.use_compositor_animation_timelines = true;
109 Compositor::SetLayerSettings(layer_settings); 111 Compositor::SetLayerSettings(layer_settings);
110 } 112 }
111 113
112 } // namespace content 114 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698