| OLD | NEW |
| 1 // Copyright 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 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 2002 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2013 // GetActiveWebContents can return NULL for example under Purify when | 2013 // GetActiveWebContents can return NULL for example under Purify when |
| 2014 // the animations are running slowly and this function is called on a timer | 2014 // the animations are running slowly and this function is called on a timer |
| 2015 // through LoadingAnimationCallback. | 2015 // through LoadingAnimationCallback. |
| 2016 frame_->UpdateThrobber(web_contents && web_contents->IsLoading()); | 2016 frame_->UpdateThrobber(web_contents && web_contents->IsLoading()); |
| 2017 } | 2017 } |
| 2018 } | 2018 } |
| 2019 | 2019 |
| 2020 void BrowserView::OnLoadCompleted() { | 2020 void BrowserView::OnLoadCompleted() { |
| 2021 #if defined(OS_WIN) | 2021 #if defined(OS_WIN) |
| 2022 DCHECK(!jumplist_); | 2022 DCHECK(!jumplist_); |
| 2023 jumplist_ = new JumpList(); | 2023 jumplist_ = new JumpList(browser_->profile()); |
| 2024 jumplist_->AddObserver(browser_->profile()); | |
| 2025 #endif | 2024 #endif |
| 2026 } | 2025 } |
| 2027 | 2026 |
| 2028 BrowserViewLayout* BrowserView::GetBrowserViewLayout() const { | 2027 BrowserViewLayout* BrowserView::GetBrowserViewLayout() const { |
| 2029 return static_cast<BrowserViewLayout*>(GetLayoutManager()); | 2028 return static_cast<BrowserViewLayout*>(GetLayoutManager()); |
| 2030 } | 2029 } |
| 2031 | 2030 |
| 2032 ContentsLayoutManager* BrowserView::GetContentsLayoutManager() const { | 2031 ContentsLayoutManager* BrowserView::GetContentsLayoutManager() const { |
| 2033 return static_cast<ContentsLayoutManager*>( | 2032 return static_cast<ContentsLayoutManager*>( |
| 2034 contents_container_->GetLayoutManager()); | 2033 contents_container_->GetLayoutManager()); |
| (...skipping 510 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2545 !GetLocationBar()->GetOmniboxView()->model()->popup_model()->IsOpen()) { | 2544 !GetLocationBar()->GetOmniboxView()->model()->popup_model()->IsOpen()) { |
| 2546 gfx::Point icon_bottom( | 2545 gfx::Point icon_bottom( |
| 2547 toolbar_->location_bar()->GetLocationBarAnchorPoint()); | 2546 toolbar_->location_bar()->GetLocationBarAnchorPoint()); |
| 2548 ConvertPointToTarget(toolbar_->location_bar(), this, &icon_bottom); | 2547 ConvertPointToTarget(toolbar_->location_bar(), this, &icon_bottom); |
| 2549 gfx::Point infobar_top(0, infobar_container_->GetVerticalOverlap(NULL)); | 2548 gfx::Point infobar_top(0, infobar_container_->GetVerticalOverlap(NULL)); |
| 2550 ConvertPointToTarget(infobar_container_, this, &infobar_top); | 2549 ConvertPointToTarget(infobar_container_, this, &infobar_top); |
| 2551 top_arrow_height = infobar_top.y() - icon_bottom.y(); | 2550 top_arrow_height = infobar_top.y() - icon_bottom.y(); |
| 2552 } | 2551 } |
| 2553 return top_arrow_height; | 2552 return top_arrow_height; |
| 2554 } | 2553 } |
| OLD | NEW |