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 "content/browser/renderer_host/render_widget_host_view_aura.h" | 5 #include "content/browser/renderer_host/render_widget_host_view_aura.h" |
| 6 | 6 |
| 7 #include "base/auto_reset.h" | 7 #include "base/auto_reset.h" |
| 8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
| 9 #include "base/bind.h" | 9 #include "base/bind.h" |
| 10 #include "base/callback_helpers.h" | 10 #include "base/callback_helpers.h" |
| (...skipping 590 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 601 } | 601 } |
| 602 LPARAM lparam = reinterpret_cast<LPARAM>(this); | 602 LPARAM lparam = reinterpret_cast<LPARAM>(this); |
| 603 EnumChildWindows(ui::GetHiddenWindow(), ShowWindowsCallback, lparam); | 603 EnumChildWindows(ui::GetHiddenWindow(), ShowWindowsCallback, lparam); |
| 604 | 604 |
| 605 if (legacy_render_widget_host_HWND_) | 605 if (legacy_render_widget_host_HWND_) |
| 606 legacy_render_widget_host_HWND_->Show(); | 606 legacy_render_widget_host_HWND_->Show(); |
| 607 #endif | 607 #endif |
| 608 } | 608 } |
| 609 | 609 |
| 610 void RenderWidgetHostViewAura::Hide() { | 610 void RenderWidgetHostViewAura::Hide() { |
| 611 window_->Hide(); | 611 Hide(false); |
| 612 } | |
| 613 | |
| 614 void RenderWidgetHostViewAura::Hide(bool content_visible) { | |
| 615 // We need to show content in a workspace view like Mac OSX Expose. | |
| 616 if (!content_visible) | |
|
no sievers
2015/03/03 21:12:53
Can you explain why it makes sense to have |window
joone
2015/03/04 05:22:45
I tried to call the Hide method when the browser w
no sievers
2015/03/04 19:21:25
This is the code right here. You mean the 'content
joone
2015/03/04 22:05:04
Yes, because if we calll window->Hide(), we only s
| |
| 617 window_->Hide(); | |
| 612 | 618 |
| 613 if (host_ && !host_->is_hidden()) { | 619 if (host_ && !host_->is_hidden()) { |
| 614 host_->WasHidden(); | 620 host_->WasHidden(); |
| 615 delegated_frame_host_->WasHidden(); | 621 delegated_frame_host_->WasHidden(); |
| 616 | 622 |
| 617 #if defined(OS_WIN) | 623 #if defined(OS_WIN) |
| 618 constrained_rects_.clear(); | 624 constrained_rects_.clear(); |
| 619 aura::WindowTreeHost* host = window_->GetHost(); | 625 aura::WindowTreeHost* host = window_->GetHost(); |
| 620 if (host) { | 626 if (host) { |
| 621 HWND parent = host->GetAcceleratedWidget(); | 627 HWND parent = host->GetAcceleratedWidget(); |
| (...skipping 2057 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 2679 | 2685 |
| 2680 //////////////////////////////////////////////////////////////////////////////// | 2686 //////////////////////////////////////////////////////////////////////////////// |
| 2681 // RenderWidgetHostViewBase, public: | 2687 // RenderWidgetHostViewBase, public: |
| 2682 | 2688 |
| 2683 // static | 2689 // static |
| 2684 void RenderWidgetHostViewBase::GetDefaultScreenInfo(WebScreenInfo* results) { | 2690 void RenderWidgetHostViewBase::GetDefaultScreenInfo(WebScreenInfo* results) { |
| 2685 GetScreenInfoForWindow(results, NULL); | 2691 GetScreenInfoForWindow(results, NULL); |
| 2686 } | 2692 } |
| 2687 | 2693 |
| 2688 } // namespace content | 2694 } // namespace content |
| OLD | NEW |