OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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/tab_contents/tab_contents.h" | 5 #include "chrome/browser/tab_contents/tab_contents.h" |
6 | 6 |
7 #include <cmath> | 7 #include <cmath> |
8 | 8 |
9 #include "base/auto_reset.h" | 9 #include "base/auto_reset.h" |
10 #include "base/metrics/histogram.h" | 10 #include "base/metrics/histogram.h" |
(...skipping 3123 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3134 return delegate()->IsExternalTabContainer(); | 3134 return delegate()->IsExternalTabContainer(); |
3135 } | 3135 } |
3136 | 3136 |
3137 void TabContents::DidInsertCSS() { | 3137 void TabContents::DidInsertCSS() { |
3138 // This RVHDelegate function is used for extensions and not us. | 3138 // This RVHDelegate function is used for extensions and not us. |
3139 } | 3139 } |
3140 | 3140 |
3141 void TabContents::FocusedNodeChanged(bool is_editable_node) { | 3141 void TabContents::FocusedNodeChanged(bool is_editable_node) { |
3142 NotificationService::current()->Notify( | 3142 NotificationService::current()->Notify( |
3143 NotificationType::FOCUS_CHANGED_IN_PAGE, | 3143 NotificationType::FOCUS_CHANGED_IN_PAGE, |
3144 Source<RenderViewHost>(render_view_host()), | 3144 Source<TabContents>(this), |
3145 Details<const bool>(&is_editable_node)); | 3145 Details<const bool>(&is_editable_node)); |
3146 } | 3146 } |
3147 | 3147 |
3148 void TabContents::UpdateZoomLimits(int minimum_percent, | 3148 void TabContents::UpdateZoomLimits(int minimum_percent, |
3149 int maximum_percent, | 3149 int maximum_percent, |
3150 bool remember) { | 3150 bool remember) { |
3151 minimum_zoom_percent_ = minimum_percent; | 3151 minimum_zoom_percent_ = minimum_percent; |
3152 maximum_zoom_percent_ = maximum_percent; | 3152 maximum_zoom_percent_ = maximum_percent; |
3153 temporary_zoom_settings_ = !remember; | 3153 temporary_zoom_settings_ = !remember; |
3154 } | 3154 } |
(...skipping 240 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3395 if (pm != NULL) { | 3395 if (pm != NULL) { |
3396 if (pm->MaybeUsePreloadedPage(this, url)) { | 3396 if (pm->MaybeUsePreloadedPage(this, url)) { |
3397 // TODO(tburkard): If the preloaded page has not finished preloading | 3397 // TODO(tburkard): If the preloaded page has not finished preloading |
3398 // yet, we should not do this. | 3398 // yet, we should not do this. |
3399 DidStopLoading(); | 3399 DidStopLoading(); |
3400 return true; | 3400 return true; |
3401 } | 3401 } |
3402 } | 3402 } |
3403 return false; | 3403 return false; |
3404 } | 3404 } |
OLD | NEW |