win: No more need to convert to DIP point for context menu.

This commit is contained in:
Cheng Zhao 2014-07-28 20:44:11 +08:00
parent 8dd7f81175
commit 1c415b0666
3 changed files with 4 additions and 20 deletions

View file

@ -8,10 +8,6 @@
#include "ui/gfx/screen.h"
#include "ui/views/controls/menu/menu_runner.h"
#if defined(OS_WIN)
#include "ui/gfx/win/dpi.h"
#endif
namespace atom {
namespace api {
@ -21,10 +17,6 @@ MenuViews::MenuViews() {
void MenuViews::Popup(Window* window) {
gfx::Point cursor = gfx::Screen::GetNativeScreen()->GetCursorScreenPoint();
#if defined(OS_WIN)
cursor = gfx::win::ScreenToDIPPoint(cursor);
#endif
views::MenuRunner menu_runner(model());
ignore_result(menu_runner.RunMenuAt(
static_cast<NativeWindowViews*>(window->window())->widget(),