Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "ui/views/controls/table/table_view_win.h" | 5 #include "ui/views/controls/table/table_view_win.h" |
| 6 | 6 |
| 7 #include <commctrl.h> | 7 #include <commctrl.h> |
| 8 #include <windowsx.h> | 8 #include <windowsx.h> |
| 9 | 9 |
| 10 #include <algorithm> | 10 #include <algorithm> |
| 11 | 11 |
| 12 #include "base/i18n/rtl.h" | 12 #include "base/i18n/rtl.h" |
| 13 #include "base/string_util.h" | 13 #include "base/string_util.h" |
| 14 #include "base/win/scoped_gdi_object.h" | 14 #include "base/win/scoped_gdi_object.h" |
| 15 #include "skia/ext/skia_utils_win.h" | 15 #include "skia/ext/skia_utils_win.h" |
| 16 #include "ui/gfx/image/image_skia.h" | |
| 17 #include "third_party/skia/include/core/SkColorFilter.h" | 16 #include "third_party/skia/include/core/SkColorFilter.h" |
| 18 #include "ui/base/l10n/l10n_util.h" | 17 #include "ui/base/l10n/l10n_util.h" |
| 19 #include "ui/base/l10n/l10n_util_win.h" | 18 #include "ui/base/l10n/l10n_util_win.h" |
| 20 #include "ui/base/models/table_model.h" | 19 #include "ui/base/models/table_model.h" |
| 21 #include "ui/base/resource/resource_bundle.h" | 20 #include "ui/base/resource/resource_bundle.h" |
| 22 #include "ui/base/win/hwnd_util.h" | 21 #include "ui/base/win/hwnd_util.h" |
| 23 #include "ui/gfx/canvas.h" | 22 #include "ui/gfx/canvas.h" |
| 24 #include "ui/gfx/favicon_size.h" | 23 #include "ui/gfx/favicon_size.h" |
| 25 #include "ui/gfx/font.h" | 24 #include "ui/gfx/font.h" |
| 26 #include "ui/gfx/icon_util.h" | 25 #include "ui/gfx/icon_util.h" |
| 27 #include "ui/gfx/image/image_skia.h" | 26 #include "ui/gfx/image/image_skia.h" |
|
sky
2012/05/29 16:32:17
Remove this.
| |
| 27 #include "ui/gfx/image/image_skia.h" | |
| 28 #include "ui/views/controls/native/native_view_host.h" | 28 #include "ui/views/controls/native/native_view_host.h" |
| 29 #include "ui/views/controls/table/table_view_observer.h" | 29 #include "ui/views/controls/table/table_view_observer.h" |
| 30 | 30 |
| 31 namespace { | 31 namespace { |
| 32 | 32 |
| 33 int GetViewIndexFromPoint(HWND window, const gfx::Point& p) { | 33 int GetViewIndexFromPoint(HWND window, const gfx::Point& p) { |
| 34 LVHITTESTINFO hit_info = {0}; | 34 LVHITTESTINFO hit_info = {0}; |
| 35 hit_info.pt.x = p.x(); | 35 hit_info.pt.x = p.x(); |
| 36 hit_info.pt.y = p.y(); | 36 hit_info.pt.y = p.y(); |
| 37 return ListView_HitTest(window, &hit_info); | 37 return ListView_HitTest(window, &hit_info); |
| (...skipping 1602 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 1640 } | 1640 } |
| 1641 | 1641 |
| 1642 void TableSelectionIterator::UpdateModelIndexFromViewIndex() { | 1642 void TableSelectionIterator::UpdateModelIndexFromViewIndex() { |
| 1643 if (view_index_ == -1) | 1643 if (view_index_ == -1) |
| 1644 model_index_ = -1; | 1644 model_index_ = -1; |
| 1645 else | 1645 else |
| 1646 model_index_ = table_view_->ViewToModel(view_index_); | 1646 model_index_ = table_view_->ViewToModel(view_index_); |
| 1647 } | 1647 } |
| 1648 | 1648 |
| 1649 } // namespace views | 1649 } // namespace views |
| OLD | NEW |