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 "chrome/browser/ui/views/frame/browser_view.h" | 5 #include "chrome/browser/ui/views/frame/browser_view.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 | 8 |
| 9 #include "base/auto_reset.h" | 9 #include "base/auto_reset.h" |
| 10 #include "base/command_line.h" | 10 #include "base/command_line.h" |
| (...skipping 1845 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 1856 if (child != infobar_container_) | 1856 if (child != infobar_container_) |
| 1857 child->Paint(canvas); | 1857 child->Paint(canvas); |
| 1858 } | 1858 } |
| 1859 | 1859 |
| 1860 infobar_container_->Paint(canvas); | 1860 infobar_container_->Paint(canvas); |
| 1861 } | 1861 } |
| 1862 | 1862 |
| 1863 void BrowserView::ViewHierarchyChanged(bool is_add, | 1863 void BrowserView::ViewHierarchyChanged(bool is_add, |
| 1864 views::View* parent, | 1864 views::View* parent, |
| 1865 views::View* child) { | 1865 views::View* child) { |
| 1866 if (is_add && child == this && GetWidget() && !initialized_) { | 1866 if (!initialized_ && is_add && child == this && GetWidget()) { |
|
sky
2012/11/08 02:04:24
This in no way relates to this patch, but checking
Peter Kasting
2012/11/08 18:55:47
GetWidget() is expensive?
I don't mind the change
| |
| 1867 Init(); | 1867 Init(); |
| 1868 initialized_ = true; | 1868 initialized_ = true; |
| 1869 } | 1869 } |
| 1870 } | 1870 } |
| 1871 | 1871 |
| 1872 void BrowserView::ChildPreferredSizeChanged(View* child) { | 1872 void BrowserView::ChildPreferredSizeChanged(View* child) { |
| 1873 Layout(); | 1873 Layout(); |
| 1874 } | 1874 } |
| 1875 | 1875 |
| 1876 void BrowserView::GetAccessibleState(ui::AccessibleViewState* state) { | 1876 void BrowserView::GetAccessibleState(ui::AccessibleViewState* state) { |
| (...skipping 710 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 2587 modal_browser->window()->Activate(); | 2587 modal_browser->window()->Activate(); |
| 2588 } | 2588 } |
| 2589 | 2589 |
| 2590 AppModalDialogQueue::GetInstance()->ActivateModalDialog(); | 2590 AppModalDialogQueue::GetInstance()->ActivateModalDialog(); |
| 2591 } | 2591 } |
| 2592 | 2592 |
| 2593 void BrowserView::MaybeStackBookmarkBarAtTop() { | 2593 void BrowserView::MaybeStackBookmarkBarAtTop() { |
| 2594 if (bookmark_bar_view_.get()) | 2594 if (bookmark_bar_view_.get()) |
| 2595 bookmark_bar_view_->MaybeStackAtTop(); | 2595 bookmark_bar_view_->MaybeStackAtTop(); |
| 2596 } | 2596 } |
| OLD | NEW |