OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 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/chrome_browser_main.h" | 5 #include "chrome/browser/chrome_browser_main.h" |
6 | 6 |
7 #include <set> | 7 #include <set> |
8 #include <string> | 8 #include <string> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 489 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
500 LoadCompleteListener() { | 500 LoadCompleteListener() { |
501 registrar_.Add(this, | 501 registrar_.Add(this, |
502 content::NOTIFICATION_LOAD_COMPLETED_MAIN_FRAME, | 502 content::NOTIFICATION_LOAD_COMPLETED_MAIN_FRAME, |
503 content::NotificationService::AllSources()); | 503 content::NotificationService::AllSources()); |
504 } | 504 } |
505 virtual ~LoadCompleteListener() {} | 505 virtual ~LoadCompleteListener() {} |
506 | 506 |
507 // content::NotificationObserver implementation. | 507 // content::NotificationObserver implementation. |
508 virtual void Observe(int type, | 508 virtual void Observe(int type, |
509 const content::NotificationSource& source, | 509 const content::NotificationSource& source, |
510 const content::NotificationDetails& details) OVERRIDE { | 510 const content::NotificationDetails& details) override { |
511 DCHECK_EQ(content::NOTIFICATION_LOAD_COMPLETED_MAIN_FRAME, type); | 511 DCHECK_EQ(content::NOTIFICATION_LOAD_COMPLETED_MAIN_FRAME, type); |
512 startup_metric_utils::OnInitialPageLoadComplete(); | 512 startup_metric_utils::OnInitialPageLoadComplete(); |
513 delete this; | 513 delete this; |
514 } | 514 } |
515 | 515 |
516 private: | 516 private: |
517 content::NotificationRegistrar registrar_; | 517 content::NotificationRegistrar registrar_; |
518 DISALLOW_COPY_AND_ASSIGN(LoadCompleteListener); | 518 DISALLOW_COPY_AND_ASSIGN(LoadCompleteListener); |
519 }; | 519 }; |
520 | 520 |
(...skipping 1155 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1676 chromeos::CrosSettings::Shutdown(); | 1676 chromeos::CrosSettings::Shutdown(); |
1677 #endif | 1677 #endif |
1678 #endif | 1678 #endif |
1679 } | 1679 } |
1680 | 1680 |
1681 // Public members: | 1681 // Public members: |
1682 | 1682 |
1683 void ChromeBrowserMainParts::AddParts(ChromeBrowserMainExtraParts* parts) { | 1683 void ChromeBrowserMainParts::AddParts(ChromeBrowserMainExtraParts* parts) { |
1684 chrome_extra_parts_.push_back(parts); | 1684 chrome_extra_parts_.push_back(parts); |
1685 } | 1685 } |
OLD | NEW |