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

Unified Diff: chrome/browser/ui/webui/print_preview_ui.h

Issue 7056070: PrintPreview: Preview generation should not block print button. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: '' Created 9 years, 6 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/ui/webui/print_preview_ui.h
diff --git a/chrome/browser/ui/webui/print_preview_ui.h b/chrome/browser/ui/webui/print_preview_ui.h
index 58ceda8488c1960b7dc47cc77dbc7f1e9a3a17c8..95657610514e4d1ff2789ade98f3e27124cbf48b 100644
--- a/chrome/browser/ui/webui/print_preview_ui.h
+++ b/chrome/browser/ui/webui/print_preview_ui.h
@@ -44,6 +44,15 @@ class PrintPreviewUI : public ChromeWebUI {
// message.
void OnInitiatorTabClosed(const std::string& initiator_tab_url);
+ void setTabHiddenForPrint() {
Lei Zhang 2011/06/09 09:54:55 nit: simple setter/getters should be unix_hacker_s
Lei Zhang 2011/06/09 09:54:55 More importantly, why modify PrintPreviewUI at all
kmadhusu 2011/06/09 18:11:44 Removed the getter/setter functions. Made code cha
+ is_tab_hidden_for_print_ = true;
+ }
+
+ // Returns true if the current tab is hidden for printing.
+ bool isHidden() {
+ return is_tab_hidden_for_print_;
+ }
+
private:
// Helper function
PrintPreviewDataService* print_preview_data_service();
@@ -53,6 +62,9 @@ class PrintPreviewUI : public ChromeWebUI {
// Store the PrintPreviewUI address string.
std::string preview_ui_addr_str_;
+ // True when the current tab is hidden for printing.
+ bool is_tab_hidden_for_print_;
+
DISALLOW_COPY_AND_ASSIGN(PrintPreviewUI);
};

Powered by Google App Engine
This is Rietveld 408576698