OLD | NEW |
---|---|
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 "chrome/browser/ui/views/apps/native_app_window_views.h" | 5 #include "chrome/browser/ui/views/apps/native_app_window_views.h" |
6 | 6 |
7 #include "apps/ui/views/shell_window_frame_view.h" | 7 #include "apps/ui/views/shell_window_frame_view.h" |
8 #include "base/command_line.h" | 8 #include "base/command_line.h" |
9 #include "base/file_util.h" | 9 #include "base/file_util.h" |
10 #include "base/path_service.h" | 10 #include "base/path_service.h" |
(...skipping 789 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
800 draggable_region_.reset(ShellWindow::RawDraggableRegionsToSkRegion(regions)); | 800 draggable_region_.reset(ShellWindow::RawDraggableRegionsToSkRegion(regions)); |
801 OnViewWasResized(); | 801 OnViewWasResized(); |
802 } | 802 } |
803 | 803 |
804 SkRegion* NativeAppWindowViews::GetDraggableRegion() { | 804 SkRegion* NativeAppWindowViews::GetDraggableRegion() { |
805 return draggable_region_.get(); | 805 return draggable_region_.get(); |
806 } | 806 } |
807 | 807 |
808 void NativeAppWindowViews::UpdateInputRegion(scoped_ptr<SkRegion> region) { | 808 void NativeAppWindowViews::UpdateInputRegion(scoped_ptr<SkRegion> region) { |
809 input_region_ = region.Pass(); | 809 input_region_ = region.Pass(); |
810 | |
811 #if defined(USE_AURA) | |
Ben Goodger (Google)
2013/11/01 16:39:47
is there a reason this has to be USE_AURA? It shou
Wez
2013/11/01 19:59:33
UpdateInputRegion() takes scoped_ptr<SkRegion>, wh
| |
812 if (input_region_) | |
813 window_->SetShape(new SkRegion(*input_region_)); | |
814 else | |
815 window_->SetShape(NULL); | |
816 #endif // defined(USE_AURA) | |
810 } | 817 } |
811 | 818 |
812 void NativeAppWindowViews::HandleKeyboardEvent( | 819 void NativeAppWindowViews::HandleKeyboardEvent( |
813 const content::NativeWebKeyboardEvent& event) { | 820 const content::NativeWebKeyboardEvent& event) { |
814 unhandled_keyboard_event_handler_.HandleKeyboardEvent(event, | 821 unhandled_keyboard_event_handler_.HandleKeyboardEvent(event, |
815 GetFocusManager()); | 822 GetFocusManager()); |
816 } | 823 } |
817 | 824 |
818 bool NativeAppWindowViews::IsFrameless() const { | 825 bool NativeAppWindowViews::IsFrameless() const { |
819 return frameless_; | 826 return frameless_; |
(...skipping 15 matching lines...) Expand all Loading... | |
835 return window_bounds.InsetsFrom(client_bounds); | 842 return window_bounds.InsetsFrom(client_bounds); |
836 } | 843 } |
837 | 844 |
838 bool NativeAppWindowViews::IsVisible() const { | 845 bool NativeAppWindowViews::IsVisible() const { |
839 return window_->IsVisible(); | 846 return window_->IsVisible(); |
840 } | 847 } |
841 | 848 |
842 void NativeAppWindowViews::HideWithApp() {} | 849 void NativeAppWindowViews::HideWithApp() {} |
843 void NativeAppWindowViews::ShowWithApp() {} | 850 void NativeAppWindowViews::ShowWithApp() {} |
844 void NativeAppWindowViews::UpdateWindowMinMaxSize() {} | 851 void NativeAppWindowViews::UpdateWindowMinMaxSize() {} |
OLD | NEW |