| 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 3125 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 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<RenderViewHost>(render_view_host()), |
| 3145 Details<const bool>(&is_editable_node)); | 3145 Details<const bool>(&is_editable_node)); |
| 3146 selected_field_is_editable_ = is_editable_node; |
| 3146 } | 3147 } |
| 3147 | 3148 |
| 3148 void TabContents::UpdateZoomLimits(int minimum_percent, | 3149 void TabContents::UpdateZoomLimits(int minimum_percent, |
| 3149 int maximum_percent, | 3150 int maximum_percent, |
| 3150 bool remember) { | 3151 bool remember) { |
| 3151 minimum_zoom_percent_ = minimum_percent; | 3152 minimum_zoom_percent_ = minimum_percent; |
| 3152 maximum_zoom_percent_ = maximum_percent; | 3153 maximum_zoom_percent_ = maximum_percent; |
| 3153 temporary_zoom_settings_ = !remember; | 3154 temporary_zoom_settings_ = !remember; |
| 3154 } | 3155 } |
| 3155 | 3156 |
| (...skipping 239 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3395 if (pm != NULL) { | 3396 if (pm != NULL) { |
| 3396 if (pm->MaybeUsePreloadedPage(this, url)) { | 3397 if (pm->MaybeUsePreloadedPage(this, url)) { |
| 3397 // TODO(tburkard): If the preloaded page has not finished preloading | 3398 // TODO(tburkard): If the preloaded page has not finished preloading |
| 3398 // yet, we should not do this. | 3399 // yet, we should not do this. |
| 3399 DidStopLoading(); | 3400 DidStopLoading(); |
| 3400 return true; | 3401 return true; |
| 3401 } | 3402 } |
| 3402 } | 3403 } |
| 3403 return false; | 3404 return false; |
| 3404 } | 3405 } |
| OLD | NEW |