| 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/printing/print_preview_tab_controller.h" | 5 #include "chrome/browser/printing/print_preview_tab_controller.h" |
| 6 | 6 |
| 7 #include "chrome/browser/browser_process.h" | 7 #include "chrome/browser/browser_process.h" |
| 8 #include "chrome/browser/tab_contents/tab_contents.h" | 8 #include "chrome/browser/tab_contents/tab_contents.h" |
| 9 #include "chrome/browser/tabs/tab_strip_model.h" | 9 #include "chrome/browser/tabs/tab_strip_model.h" |
| 10 #include "chrome/browser/ui/browser.h" | 10 #include "chrome/browser/ui/browser.h" |
| 11 #include "chrome/browser/ui/browser_list.h" | 11 #include "chrome/browser/ui/browser_list.h" |
| 12 #include "chrome/browser/ui/browser_navigator.h" | 12 #include "chrome/browser/ui/browser_navigator.h" |
| 13 #include "chrome/browser/ui/tab_contents/tab_contents_wrapper.h" | 13 #include "chrome/browser/ui/tab_contents/tab_contents_wrapper.h" |
| 14 #include "chrome/common/notification_service.h" | 14 #include "chrome/common/notification_details.h" |
| 15 #include "chrome/common/notification_source.h" |
| 15 #include "chrome/common/url_constants.h" | 16 #include "chrome/common/url_constants.h" |
| 16 | 17 |
| 17 namespace printing { | 18 namespace printing { |
| 18 | 19 |
| 19 PrintPreviewTabController::PrintPreviewTabController() | 20 PrintPreviewTabController::PrintPreviewTabController() |
| 20 : waiting_for_new_preview_page_(false) { | 21 : waiting_for_new_preview_page_(false) { |
| 21 } | 22 } |
| 22 | 23 |
| 23 PrintPreviewTabController::~PrintPreviewTabController() {} | 24 PrintPreviewTabController::~PrintPreviewTabController() {} |
| 24 | 25 |
| (...skipping 157 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 182 } | 183 } |
| 183 | 184 |
| 184 void PrintPreviewTabController::RemoveObservers(TabContents* tab) { | 185 void PrintPreviewTabController::RemoveObservers(TabContents* tab) { |
| 185 registrar_.Remove(this, NotificationType::TAB_CONTENTS_DESTROYED, | 186 registrar_.Remove(this, NotificationType::TAB_CONTENTS_DESTROYED, |
| 186 Source<TabContents>(tab)); | 187 Source<TabContents>(tab)); |
| 187 registrar_.Remove(this, NotificationType::NAV_ENTRY_COMMITTED, | 188 registrar_.Remove(this, NotificationType::NAV_ENTRY_COMMITTED, |
| 188 Source<NavigationController>(&tab->controller())); | 189 Source<NavigationController>(&tab->controller())); |
| 189 } | 190 } |
| 190 | 191 |
| 191 } // namespace printing | 192 } // namespace printing |
| OLD | NEW |