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/browser.h" | 5 #include "chrome/browser/ui/browser.h" |
6 | 6 |
7 #if defined(OS_WIN) | 7 #if defined(OS_WIN) |
8 #include <windows.h> | 8 #include <windows.h> |
9 #include <shellapi.h> | 9 #include <shellapi.h> |
10 #endif // defined(OS_WIN) | 10 #endif // defined(OS_WIN) |
(...skipping 1828 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1839 window_->SetStarredState(starred); | 1839 window_->SetStarredState(starred); |
1840 } | 1840 } |
1841 | 1841 |
1842 /////////////////////////////////////////////////////////////////////////////// | 1842 /////////////////////////////////////////////////////////////////////////////// |
1843 // Browser, ZoomObserver implementation: | 1843 // Browser, ZoomObserver implementation: |
1844 | 1844 |
1845 void Browser::OnZoomChanged(const ZoomController::ZoomChangedEventData& data) { | 1845 void Browser::OnZoomChanged(const ZoomController::ZoomChangedEventData& data) { |
1846 if (data.web_contents == tab_strip_model_->GetActiveWebContents()) { | 1846 if (data.web_contents == tab_strip_model_->GetActiveWebContents()) { |
1847 // Only show the zoom bubble for zoom changes in the active window. | 1847 // Only show the zoom bubble for zoom changes in the active window. |
1848 window_->ZoomChangedForActiveTab(data.can_show_bubble && | 1848 window_->ZoomChangedForActiveTab(data.can_show_bubble && |
1849 window_->IsActive() && !is_devtools()); | 1849 window_->IsActive()); |
1850 } | 1850 } |
1851 } | 1851 } |
1852 | 1852 |
1853 /////////////////////////////////////////////////////////////////////////////// | 1853 /////////////////////////////////////////////////////////////////////////////// |
1854 // Browser, ui::SelectFileDialog::Listener implementation: | 1854 // Browser, ui::SelectFileDialog::Listener implementation: |
1855 | 1855 |
1856 void Browser::FileSelected(const base::FilePath& path, int index, | 1856 void Browser::FileSelected(const base::FilePath& path, int index, |
1857 void* params) { | 1857 void* params) { |
1858 FileSelectedWithExtraInfo(ui::SelectedFileInfo(path, path), index, params); | 1858 FileSelectedWithExtraInfo(ui::SelectedFileInfo(path, path), index, params); |
1859 } | 1859 } |
(...skipping 562 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2422 if (contents && !allow_js_access) { | 2422 if (contents && !allow_js_access) { |
2423 contents->web_contents()->GetController().LoadURL( | 2423 contents->web_contents()->GetController().LoadURL( |
2424 target_url, | 2424 target_url, |
2425 content::Referrer(), | 2425 content::Referrer(), |
2426 content::PAGE_TRANSITION_LINK, | 2426 content::PAGE_TRANSITION_LINK, |
2427 std::string()); // No extra headers. | 2427 std::string()); // No extra headers. |
2428 } | 2428 } |
2429 | 2429 |
2430 return contents != NULL; | 2430 return contents != NULL; |
2431 } | 2431 } |
OLD | NEW |