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

Side by Side Diff: content/browser/web_contents/web_contents_impl.cc

Issue 26764002: Chromium side of maxTouchPoints implementation. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 7 years, 2 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/web_contents/web_contents_impl.h" 5 #include "content/browser/web_contents/web_contents_impl.h"
6 6
7 #include <utility> 7 #include <utility>
8 8
9 #include "base/command_line.h" 9 #include "base/command_line.h"
10 #include "base/debug/trace_event.h" 10 #include "base/debug/trace_event.h"
(...skipping 583 matching lines...) Expand 10 before | Expand all | Expand 10 after
594 switches::kDisableGestureRequirementForMediaFullscreen); 594 switches::kDisableGestureRequirementForMediaFullscreen);
595 #endif 595 #endif
596 596
597 prefs.touch_enabled = ui::AreTouchEventsEnabled(); 597 prefs.touch_enabled = ui::AreTouchEventsEnabled();
598 prefs.device_supports_touch = prefs.touch_enabled && 598 prefs.device_supports_touch = prefs.touch_enabled &&
599 ui::IsTouchDevicePresent(); 599 ui::IsTouchDevicePresent();
600 #if defined(OS_ANDROID) 600 #if defined(OS_ANDROID)
601 prefs.device_supports_mouse = false; 601 prefs.device_supports_mouse = false;
602 #endif 602 #endif
603 603
604 prefs.pointer_events_max_touch_points_enabled = prefs.touch_enabled &&
Rick Byers 2013/10/10 22:42:40 I don't think you want to look at touch_enabled he
Rick Byers 2013/10/10 22:42:40 Does this override the status=experimental propert
605 ui::CanDetectMaxTouchPoints();
606 prefs.pointer_events_max_touch_points = ui::MaxTouchPoints();
607
604 prefs.touch_adjustment_enabled = 608 prefs.touch_adjustment_enabled =
605 !command_line.HasSwitch(switches::kDisableTouchAdjustment); 609 !command_line.HasSwitch(switches::kDisableTouchAdjustment);
606 prefs.compositor_touch_hit_testing = 610 prefs.compositor_touch_hit_testing =
607 !command_line.HasSwitch(cc::switches::kDisableCompositorTouchHitTesting); 611 !command_line.HasSwitch(cc::switches::kDisableCompositorTouchHitTesting);
608 612
609 #if defined(OS_MACOSX) || defined(OS_CHROMEOS) 613 #if defined(OS_MACOSX) || defined(OS_CHROMEOS)
610 bool default_enable_scroll_animator = true; 614 bool default_enable_scroll_animator = true;
611 #else 615 #else
612 bool default_enable_scroll_animator = false; 616 bool default_enable_scroll_animator = false;
613 #endif 617 #endif
(...skipping 3220 matching lines...) Expand 10 before | Expand all | Expand 10 after
3834 } 3838 }
3835 3839
3836 void WebContentsImpl::OnFrameRemoved( 3840 void WebContentsImpl::OnFrameRemoved(
3837 RenderViewHostImpl* render_view_host, 3841 RenderViewHostImpl* render_view_host,
3838 int64 frame_id) { 3842 int64 frame_id) {
3839 FOR_EACH_OBSERVER(WebContentsObserver, observers_, 3843 FOR_EACH_OBSERVER(WebContentsObserver, observers_,
3840 FrameDetached(render_view_host, frame_id)); 3844 FrameDetached(render_view_host, frame_id));
3841 } 3845 }
3842 3846
3843 } // namespace content 3847 } // namespace content
OLDNEW
« no previous file with comments | « no previous file | content/public/common/common_param_traits_macros.h » ('j') | ui/base/touch/touch_device.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698