| Index: chrome/browser/printing/print_preview_tab_controller.h
|
| ===================================================================
|
| --- chrome/browser/printing/print_preview_tab_controller.h (revision 140896)
|
| +++ chrome/browser/printing/print_preview_tab_controller.h (working copy)
|
| @@ -15,7 +15,6 @@
|
|
|
| class GURL;
|
| class TabContents;
|
| -typedef TabContents TabContentsWrapper;
|
|
|
| namespace content {
|
| struct LoadCommittedDetails;
|
| @@ -40,20 +39,20 @@
|
|
|
| // Initiate print preview for |initiator_tab|.
|
| // Call this instead of GetOrCreatePreviewTab().
|
| - static void PrintPreview(TabContentsWrapper* initiator_tab);
|
| + static void PrintPreview(TabContents* initiator_tab);
|
|
|
| // Get/Create the print preview tab for |initiator_tab|.
|
| // Exposed for unit tests.
|
| - TabContentsWrapper* GetOrCreatePreviewTab(TabContentsWrapper* initiator_tab);
|
| + TabContents* GetOrCreatePreviewTab(TabContents* initiator_tab);
|
|
|
| // Returns preview tab for |tab|.
|
| // Returns |tab| if |tab| is a preview tab.
|
| // Returns NULL if no preview tab exists for |tab|.
|
| - TabContentsWrapper* GetPrintPreviewForTab(TabContentsWrapper* tab) const;
|
| + TabContents* GetPrintPreviewForTab(TabContents* tab) const;
|
|
|
| // Returns initiator tab for |preview_tab|.
|
| // Returns NULL if no initiator tab exists for |preview_tab|.
|
| - TabContentsWrapper* GetInitiatorTab(TabContentsWrapper* preview_tab);
|
| + TabContents* GetInitiatorTab(TabContents* preview_tab);
|
|
|
| // content::NotificationObserver implementation.
|
| virtual void Observe(int type,
|
| @@ -61,13 +60,13 @@
|
| const content::NotificationDetails& details) OVERRIDE;
|
|
|
| // Returns true if |tab| is a print preview tab.
|
| - static bool IsPrintPreviewTab(TabContentsWrapper* tab);
|
| + static bool IsPrintPreviewTab(TabContents* tab);
|
|
|
| // Returns true if |url| is a print preview url.
|
| static bool IsPrintPreviewURL(const GURL& url);
|
|
|
| // Erase the initiator tab info associated with |preview_tab|.
|
| - void EraseInitiatorTabInfo(TabContentsWrapper* preview_tab);
|
| + void EraseInitiatorTabInfo(TabContents* preview_tab);
|
|
|
| bool is_creating_print_preview_tab() const;
|
|
|
| @@ -77,7 +76,7 @@
|
| // 1:1 relationship between initiator tab and print preview tab.
|
| // Key: Preview tab.
|
| // Value: Initiator tab.
|
| - typedef std::map<TabContentsWrapper*, TabContentsWrapper*> PrintPreviewTabMap;
|
| + typedef std::map<TabContents*, TabContents*> PrintPreviewTabMap;
|
|
|
| virtual ~PrintPreviewTabController();
|
|
|
| @@ -87,28 +86,27 @@
|
|
|
| // Handler for the TAB_CONTENTS_DESTROYED notification. This is observed when
|
| // either tab is closed.
|
| - void OnTabContentsDestroyed(TabContentsWrapper* tab);
|
| + void OnTabContentsDestroyed(TabContents* tab);
|
|
|
| // Handler for the NAV_ENTRY_COMMITTED notification. This is observed when the
|
| // renderer is navigated to a different page.
|
| - void OnNavEntryCommitted(TabContentsWrapper* tab,
|
| + void OnNavEntryCommitted(TabContents* tab,
|
| content::LoadCommittedDetails* details);
|
|
|
| // Creates a new print preview tab.
|
| - TabContentsWrapper* CreatePrintPreviewTab(TabContentsWrapper* initiator_tab);
|
| + TabContents* CreatePrintPreviewTab(TabContents* initiator_tab);
|
|
|
| // Helper function to store the initiator tab(title and url) information
|
| // in PrintPreviewUI.
|
| - void SetInitiatorTabURLAndTitle(TabContentsWrapper* preview_tab);
|
| + void SetInitiatorTabURLAndTitle(TabContents* preview_tab);
|
|
|
| // Adds/Removes observers for notifications from |tab|.
|
| - void AddObservers(TabContentsWrapper* tab);
|
| - void RemoveObservers(TabContentsWrapper* tab);
|
| + void AddObservers(TabContents* tab);
|
| + void RemoveObservers(TabContents* tab);
|
|
|
| // Removes tabs when they close/crash/navigate.
|
| - void RemoveInitiatorTab(TabContentsWrapper* initiator_tab,
|
| - bool is_navigation);
|
| - void RemovePreviewTab(TabContentsWrapper* preview_tab);
|
| + void RemoveInitiatorTab(TabContents* initiator_tab, bool is_navigation);
|
| + void RemovePreviewTab(TabContents* preview_tab);
|
|
|
| // Mapping between print preview tab and the corresponding initiator tab.
|
| PrintPreviewTabMap preview_tab_map_;
|
|
|