OLD | NEW |
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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 #if defined(OS_CHROMEOS) | 7 #if defined(OS_CHROMEOS) |
8 // For GdkScreen | 8 // For GdkScreen |
9 #include <gdk/gdk.h> | 9 #include <gdk/gdk.h> |
10 #endif // defined(OS_CHROMEOS) | 10 #endif // defined(OS_CHROMEOS) |
(...skipping 771 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
782 } | 782 } |
783 | 783 |
784 bool TabContents::NavigateToPendingEntry( | 784 bool TabContents::NavigateToPendingEntry( |
785 NavigationController::ReloadType reload_type) { | 785 NavigationController::ReloadType reload_type) { |
786 const NavigationEntry& entry = *controller_.pending_entry(); | 786 const NavigationEntry& entry = *controller_.pending_entry(); |
787 | 787 |
788 RenderViewHost* dest_render_view_host = render_manager_.Navigate(entry); | 788 RenderViewHost* dest_render_view_host = render_manager_.Navigate(entry); |
789 if (!dest_render_view_host) | 789 if (!dest_render_view_host) |
790 return false; // Unable to create the desired render view host. | 790 return false; // Unable to create the desired render view host. |
791 | 791 |
792 if (delegate_ && delegate_->ShouldEnablePreferredSizeNotifications()) | 792 if (delegate_ && delegate_->ShouldEnablePreferredSizeNotifications()) { |
793 dest_render_view_host->EnablePreferredSizeChangedMode(); | 793 dest_render_view_host->EnablePreferredSizeChangedMode( |
| 794 kPreferredSizeWidth | kPreferredSizeHeightThisIsSlow); |
| 795 } |
794 | 796 |
795 // For security, we should never send non-DOM-UI URLs (other than about:blank) | 797 // For security, we should never send non-DOM-UI URLs (other than about:blank) |
796 // to a DOM UI renderer. Double check that here. | 798 // to a DOM UI renderer. Double check that here. |
797 int enabled_bindings = dest_render_view_host->enabled_bindings(); | 799 int enabled_bindings = dest_render_view_host->enabled_bindings(); |
798 bool is_allowed_in_dom_ui_renderer = | 800 bool is_allowed_in_dom_ui_renderer = |
799 DOMUIFactory::UseDOMUIForURL(entry.url()) || | 801 DOMUIFactory::UseDOMUIForURL(entry.url()) || |
800 entry.url() == GURL(chrome::kAboutBlankURL); | 802 entry.url() == GURL(chrome::kAboutBlankURL); |
801 CHECK(!BindingsPolicy::is_dom_ui_enabled(enabled_bindings) || | 803 CHECK(!BindingsPolicy::is_dom_ui_enabled(enabled_bindings) || |
802 is_allowed_in_dom_ui_renderer); | 804 is_allowed_in_dom_ui_renderer); |
803 | 805 |
(...skipping 2368 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3172 AddInfoBar(new SavePasswordInfoBarDelegate(this, form_to_save)); | 3174 AddInfoBar(new SavePasswordInfoBarDelegate(this, form_to_save)); |
3173 } | 3175 } |
3174 | 3176 |
3175 Profile* TabContents::GetProfileForPasswordManager() { | 3177 Profile* TabContents::GetProfileForPasswordManager() { |
3176 return profile(); | 3178 return profile(); |
3177 } | 3179 } |
3178 | 3180 |
3179 bool TabContents::DidLastPageLoadEncounterSSLErrors() { | 3181 bool TabContents::DidLastPageLoadEncounterSSLErrors() { |
3180 return controller().ssl_manager()->ProcessedSSLErrorFromRequest(); | 3182 return controller().ssl_manager()->ProcessedSSLErrorFromRequest(); |
3181 } | 3183 } |
OLD | NEW |