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/widget/native_widget_aura.h" | 5 #include "ui/views/widget/native_widget_aura.h" |
6 | 6 |
7 #include "base/bind.h" | 7 #include "base/bind.h" |
8 #include "base/strings/string_util.h" | 8 #include "base/strings/string_util.h" |
9 #include "third_party/skia/include/core/SkRegion.h" | 9 #include "third_party/skia/include/core/SkRegion.h" |
10 #include "ui/aura/client/aura_constants.h" | 10 #include "ui/aura/client/aura_constants.h" |
(...skipping 753 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
764 // handles the case of a maximize animation acquiring the layer (acquiring a | 764 // handles the case of a maximize animation acquiring the layer (acquiring a |
765 // layer results in clearing the bounds). | 765 // layer results in clearing the bounds). |
766 if (old_bounds.origin() != new_bounds.origin() || | 766 if (old_bounds.origin() != new_bounds.origin() || |
767 (old_bounds == gfx::Rect(0, 0, 0, 0) && !new_bounds.IsEmpty())) { | 767 (old_bounds == gfx::Rect(0, 0, 0, 0) && !new_bounds.IsEmpty())) { |
768 delegate_->OnNativeWidgetMove(); | 768 delegate_->OnNativeWidgetMove(); |
769 } | 769 } |
770 if (old_bounds.size() != new_bounds.size()) | 770 if (old_bounds.size() != new_bounds.size()) |
771 delegate_->OnNativeWidgetSizeChanged(new_bounds.size()); | 771 delegate_->OnNativeWidgetSizeChanged(new_bounds.size()); |
772 } | 772 } |
773 | 773 |
| 774 ui::TextInputClient* NativeWidgetAura::GetFocusedTextInputClient() { |
| 775 return GetWidget()->GetFocusedTextInputClient(); |
| 776 } |
| 777 |
774 gfx::NativeCursor NativeWidgetAura::GetCursor(const gfx::Point& point) { | 778 gfx::NativeCursor NativeWidgetAura::GetCursor(const gfx::Point& point) { |
775 return cursor_; | 779 return cursor_; |
776 } | 780 } |
777 | 781 |
778 int NativeWidgetAura::GetNonClientComponent(const gfx::Point& point) const { | 782 int NativeWidgetAura::GetNonClientComponent(const gfx::Point& point) const { |
779 return delegate_->GetNonClientComponent(point); | 783 return delegate_->GetNonClientComponent(point); |
780 } | 784 } |
781 | 785 |
782 bool NativeWidgetAura::ShouldDescendIntoChildForEventHandling( | 786 bool NativeWidgetAura::ShouldDescendIntoChildForEventHandling( |
783 aura::Window* child, | 787 aura::Window* child, |
(...skipping 417 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1201 l10n_util::AdjustUIFont(&(ncm.lfCaptionFont)); | 1205 l10n_util::AdjustUIFont(&(ncm.lfCaptionFont)); |
1202 base::win::ScopedHFONT caption_font(CreateFontIndirect(&(ncm.lfCaptionFont))); | 1206 base::win::ScopedHFONT caption_font(CreateFontIndirect(&(ncm.lfCaptionFont))); |
1203 return gfx::FontList(gfx::Font(caption_font)); | 1207 return gfx::FontList(gfx::Font(caption_font)); |
1204 #else | 1208 #else |
1205 return gfx::FontList(); | 1209 return gfx::FontList(); |
1206 #endif | 1210 #endif |
1207 } | 1211 } |
1208 | 1212 |
1209 } // namespace internal | 1213 } // namespace internal |
1210 } // namespace views | 1214 } // namespace views |
OLD | NEW |