From 9e4c033c4f88780c47ebf13ab4b9f180bf63df29 Mon Sep 17 00:00:00 2001 From: "glen@chromium.org" Date: Wed, 25 Feb 2009 17:47:58 +0000 Subject: Enable history and downloads by default, port NewTabUI from DOMUIHost to DOMUI. NewTabUI is only included on OS(WIN) because DOMUI doesn't appear to have been ported. Review URL: http://codereview.chromium.org/28104 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@10344 0039d316-1c4b-4281-b951-d872f2087c98 --- chrome/browser/dom_ui/dom_ui.h | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) (limited to 'chrome/browser/dom_ui/dom_ui.h') diff --git a/chrome/browser/dom_ui/dom_ui.h b/chrome/browser/dom_ui/dom_ui.h index a1b25ec..1de9c42 100644 --- a/chrome/browser/dom_ui/dom_ui.h +++ b/chrome/browser/dom_ui/dom_ui.h @@ -42,6 +42,20 @@ class DOMUI { const Value& arg1, const Value& arg2); + // Overriddable control over the contents. + // Favicon should be displayed normally. + virtual bool ShouldDisplayFavIcon() { return true; } + // No special bookmark bar behavior + virtual bool IsBookmarkBarAlwaysVisible() { return false; } + // When NTP gets the initial focus, focus the URL bar. + virtual void SetInitialFocus() {}; + // Whether we want to display the page's URL. + virtual bool ShouldDisplayURL() { return true; } + // Hide the referrer. + virtual void RequestOpenURL(const GURL& url, const GURL&, + WindowOpenDisposition disposition); + + DOMUIContents* get_contents() { return contents_; } Profile* get_profile() { return contents_->profile(); } protected: @@ -69,7 +83,7 @@ class DOMUI { class DOMMessageHandler { public: explicit DOMMessageHandler(DOMUI* dom_ui); - virtual ~DOMMessageHandler(); + virtual ~DOMMessageHandler() {}; protected: // Adds "url" and "title" keys on incoming dictionary, setting title @@ -90,5 +104,4 @@ class DOMMessageHandler { DISALLOW_COPY_AND_ASSIGN(DOMMessageHandler); }; - #endif // CHROME_BROWSER_DOM_UI_H__ -- cgit v1.1