// Copyright (c) 2012 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

#include "ui/base/touch/touch_device.h"
#include "base/win/windows_version.h"
#include <windows.h>

namespace ui {

bool IsTouchDevicePresent() {
  int value = GetSystemMetrics(SM_DIGITIZER);
  return (value & (NID_READY | NID_INTEGRATED_TOUCH)) ==
             (NID_READY | NID_INTEGRATED_TOUCH);
}

}  // namespace ui

// Copyright (c) 2012 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

#include "ui/base/touch/touch_device.h"
#include "base/win/windows_version.h"
#include <windows.h>

namespace ui {

bool IsTouchDevicePresent() {
  int value = GetSystemMetrics(SM_DIGITIZER);
  return (value & NID_READY) &&
      ((value & NID_INTEGRATED_TOUCH) || (value & NID_EXTERNAL_TOUCH));
}

}  // namespace ui

Enable touch on external touch devices.
Enable touch on external touch devices.

BUG=176058

Review URL: https://chromiumcodereview.appspot.com/22264009

git-svn-id: de016e52bd170d2d4f2344f9bf92d50478b649e0@216433 0039d316-1c4b-4281-b951-d872f2087c98
