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/tab_contents_wrapper.h" | |
10 #include "chrome/browser/tabs/tab_strip_model.h" | 9 #include "chrome/browser/tabs/tab_strip_model.h" |
11 #include "chrome/browser/ui/browser.h" | 10 #include "chrome/browser/ui/browser.h" |
12 #include "chrome/browser/ui/browser_list.h" | 11 #include "chrome/browser/ui/browser_list.h" |
13 #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" |
14 #include "chrome/common/notification_service.h" | 14 #include "chrome/common/notification_service.h" |
15 #include "chrome/common/url_constants.h" | 15 #include "chrome/common/url_constants.h" |
16 | 16 |
17 namespace printing { | 17 namespace printing { |
18 | 18 |
19 // static | 19 // static |
20 PrintPreviewTabController* PrintPreviewTabController::GetInstance() { | 20 PrintPreviewTabController* PrintPreviewTabController::GetInstance() { |
21 if (!g_browser_process) | 21 if (!g_browser_process) |
22 return NULL; | 22 return NULL; |
23 return g_browser_process->print_preview_tab_controller(); | 23 return g_browser_process->print_preview_tab_controller(); |
(...skipping 162 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
186 if (source_tab == preview_tab) { | 186 if (source_tab == preview_tab) { |
187 preview_tab_map_.erase(preview_tab); | 187 preview_tab_map_.erase(preview_tab); |
188 RemoveObservers(preview_tab); | 188 RemoveObservers(preview_tab); |
189 } | 189 } |
190 | 190 |
191 if (initiator_tab) | 191 if (initiator_tab) |
192 RemoveObservers(initiator_tab); | 192 RemoveObservers(initiator_tab); |
193 } | 193 } |
194 | 194 |
195 } // namespace printing | 195 } // namespace printing |
OLD | NEW |