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

Unified Diff: chrome/browser/ui/views/omnibox/omnibox_view_win.cc

Issue 19805005: Refactored touch-events flag test, correcting "enabled" logic. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Renamed IsTouchEnabled to AreTouchEventsEnabled. Created 7 years, 5 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | chrome/chrome.user32.delay.imports » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/views/omnibox/omnibox_view_win.cc
diff --git a/chrome/browser/ui/views/omnibox/omnibox_view_win.cc b/chrome/browser/ui/views/omnibox/omnibox_view_win.cc
index d4b80da6a9cbc8c969623aaedf722064db479199..914c2cbaa9df4869423962048536af12e9624dc0 100644
--- a/chrome/browser/ui/views/omnibox/omnibox_view_win.cc
+++ b/chrome/browser/ui/views/omnibox/omnibox_view_win.cc
@@ -61,6 +61,7 @@
#include "ui/base/keycodes/keyboard_codes.h"
#include "ui/base/l10n/l10n_util.h"
#include "ui/base/l10n/l10n_util_win.h"
+#include "ui/base/touch/touch_enabled.h"
#include "ui/base/win/hwnd_util.h"
#include "ui/base/win/mouse_wheel_util.h"
#include "ui/base/win/touch_input.h"
@@ -1441,7 +1442,8 @@ LRESULT OmniboxViewWin::OnCreate(const CREATESTRUCTW* /*create_struct*/) {
// Enable TSF support of RichEdit.
SetEditStyle(SES_USECTF, SES_USECTF);
}
- if (base::win::GetVersion() >= base::win::VERSION_WIN8) {
+ if ((base::win::GetVersion() >= base::win::VERSION_WIN8) &&
+ ui::AreTouchEventsEnabled()) {
BOOL touch_mode = RegisterTouchWindow(m_hWnd, TWF_WANTPALM);
DCHECK(touch_mode);
}
« no previous file with comments | « no previous file | chrome/chrome.user32.delay.imports » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698