Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(353)

Side by Side Diff: chrome/browser/tab_contents/tab_contents.cc

Issue 3473006: Fix a bunch of clang warnings/errors. (Closed)
Patch Set: Created 10 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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 1525 matching lines...) Expand 10 before | Expand all | Expand 10 after
1536 if (!blocked_popups_) 1536 if (!blocked_popups_)
1537 blocked_popups_ = new BlockedPopupContainer(this); 1537 blocked_popups_ = new BlockedPopupContainer(this);
1538 blocked_popups_->AddTabContents(new_contents, initial_pos); 1538 blocked_popups_->AddTabContents(new_contents, initial_pos);
1539 content_settings_delegate_->OnContentBlocked(CONTENT_SETTINGS_TYPE_POPUPS, 1539 content_settings_delegate_->OnContentBlocked(CONTENT_SETTINGS_TYPE_POPUPS,
1540 std::string()); 1540 std::string());
1541 if (!is_being_destroyed()) 1541 if (!is_being_destroyed())
1542 PopupBlockedAnimation::Show(this); 1542 PopupBlockedAnimation::Show(this);
1543 } 1543 }
1544 } 1544 }
1545 1545
1546 namespace {
1547 bool TransitionIsReload(PageTransition::Type transition) {
1548 return PageTransition::StripQualifier(transition) == PageTransition::RELOAD;
1549 }
1550 }
1551
1552 void TabContents::ExpireInfoBars( 1546 void TabContents::ExpireInfoBars(
1553 const NavigationController::LoadCommittedDetails& details) { 1547 const NavigationController::LoadCommittedDetails& details) {
1554 // Only hide InfoBars when the user has done something that makes the main 1548 // Only hide InfoBars when the user has done something that makes the main
1555 // frame load. We don't want various automatic or subframe navigations making 1549 // frame load. We don't want various automatic or subframe navigations making
1556 // it disappear. 1550 // it disappear.
1557 if (!details.is_user_initiated_main_frame_load()) 1551 if (!details.is_user_initiated_main_frame_load())
1558 return; 1552 return;
1559 1553
1560 for (int i = infobar_delegate_count() - 1; i >= 0; --i) { 1554 for (int i = infobar_delegate_count() - 1; i >= 0; --i) {
1561 InfoBarDelegate* delegate = GetInfoBarDelegateAt(i); 1555 InfoBarDelegate* delegate = GetInfoBarDelegateAt(i);
(...skipping 1733 matching lines...) Expand 10 before | Expand all | Expand 10 after
3295 AddInfoBar(new SavePasswordInfoBarDelegate(this, form_to_save)); 3289 AddInfoBar(new SavePasswordInfoBarDelegate(this, form_to_save));
3296 } 3290 }
3297 3291
3298 Profile* TabContents::GetProfileForPasswordManager() { 3292 Profile* TabContents::GetProfileForPasswordManager() {
3299 return profile(); 3293 return profile();
3300 } 3294 }
3301 3295
3302 bool TabContents::DidLastPageLoadEncounterSSLErrors() { 3296 bool TabContents::DidLastPageLoadEncounterSSLErrors() {
3303 return controller().ssl_manager()->ProcessedSSLErrorFromRequest(); 3297 return controller().ssl_manager()->ProcessedSSLErrorFromRequest();
3304 } 3298 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698