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

Unified Diff: chrome/browser/views/keyword_editor_view.cc

Issue 195035: Use MAKEPOINTS instead of GET_X/Y_LPARAM to reduce a dependency on ATL.... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 11 years, 3 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 | « base/gfx/point.cc ('k') | views/controls/tree/tree_view.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/views/keyword_editor_view.cc
===================================================================
--- chrome/browser/views/keyword_editor_view.cc (revision 25700)
+++ chrome/browser/views/keyword_editor_view.cc (working copy)
@@ -4,11 +4,10 @@
#include "chrome/browser/views/keyword_editor_view.h"
-#include <atlbase.h>
-#include <atlapp.h>
#include <vector>
#include "app/l10n_util.h"
+#include "base/gfx/point.h"
#include "base/stl_util-inl.h"
#include "base/string_util.h"
#include "chrome/browser/profile.h"
@@ -219,9 +218,9 @@
void KeywordEditorView::OnDoubleClick() {
if (edit_button_->IsEnabled()) {
DWORD pos = GetMessagePos();
- POINT cursor_point = { GET_X_LPARAM(pos), GET_Y_LPARAM(pos) };
+ gfx::Point cursor_point(pos);
views::MouseEvent event(views::Event::ET_MOUSE_RELEASED,
- cursor_point.x, cursor_point.y,
+ cursor_point.x(), cursor_point.y(),
views::Event::EF_LEFT_BUTTON_DOWN);
ButtonPressed(edit_button_, event);
}
@@ -233,7 +232,7 @@
browser::EditSearchEngine(GetWindow()->GetNativeWindow(), NULL, this,
profile_);
} else if (sender == remove_button_) {
- DCHECK(table_view_->SelectedRowCount() == 1);
+ DCHECK_EQ(1, table_view_->SelectedRowCount());
int last_view_row = -1;
for (views::TableView::iterator i = table_view_->SelectionBegin();
i != table_view_->SelectionEnd(); ++i) {
« no previous file with comments | « base/gfx/point.cc ('k') | views/controls/tree/tree_view.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698