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

Unified Diff: ui/views/cocoa/bridged_content_view.mm

Issue 2587833002: MacViews: Perform word lookup on force touch. (Closed)
Patch Set: Address review. Created 4 years 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/views/cocoa/bridged_content_view.mm
diff --git a/ui/views/cocoa/bridged_content_view.mm b/ui/views/cocoa/bridged_content_view.mm
index d1df25251c718fc27151643c891160406a6f233b..b5d67a19df856cc326768644356b961c201fc628 100644
--- a/ui/views/cocoa/bridged_content_view.mm
+++ b/ui/views/cocoa/bridged_content_view.mm
@@ -10,6 +10,7 @@
#import "base/mac/sdk_forward_declarations.h"
#include "base/strings/sys_string_conversions.h"
#include "skia/ext/skia_utils_mac.h"
+#import "ui/base/cocoa/appkit_utils.h"
#include "ui/base/cocoa/cocoa_base_utils.h"
#include "ui/base/dragdrop/drag_drop_types.h"
#include "ui/base/dragdrop/os_exchange_data_provider_mac.h"
@@ -618,6 +619,11 @@ - (void)mouseEvent:(NSEvent*)theEvent {
hostedView_->GetWidget()->OnMouseEvent(&event);
}
+- (void)forceTouchEvent:(NSEvent*)theEvent {
+ if (ui::ForceClickInvokesQuickLook())
+ [self quickLookWithEvent:theEvent];
+}
+
// NSView implementation.
- (BOOL)acceptsFirstResponder {
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698