summaryrefslogtreecommitdiffstats
path: root/chrome/browser/views/options/general_page_view.h
diff options
context:
space:
mode:
authorfinnur@google.com <finnur@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2008-07-30 05:58:17 +0000
committerfinnur@google.com <finnur@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2008-07-30 05:58:17 +0000
commit2baf83d75ea5d1233d3ddcf8e28aa4f4466c115c (patch)
tree617cf49b21490c8e7b2e3c5a821c5d72c5735894 /chrome/browser/views/options/general_page_view.h
parent492399e06e64635ca8e3191f0653a8b081863b33 (diff)
downloadchromium_src-2baf83d75ea5d1233d3ddcf8e28aa4f4466c115c.zip
chromium_src-2baf83d75ea5d1233d3ddcf8e28aa4f4466c115c.tar.gz
chromium_src-2baf83d75ea5d1233d3ddcf8e28aa4f4466c115c.tar.bz2
Fix 1295677: REGRESSION: Import SETS startup page to imported home page.
We had only kHomePage pref before, which if blank/set to chrome-internal: meant that the New Tab page should be shown when Home is pressed. Now we add a pref called kHomePageIsNewTabPage for this purpose, which allows us to set the kHomePage value during import without actually using it as the HomePage (effectively importing home page becomes importing a default suggestion for when the users want a home page instead of the New Tab page). BUG=1295677 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@107 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/views/options/general_page_view.h')
-rw-r--r--chrome/browser/views/options/general_page_view.h13
1 files changed, 10 insertions, 3 deletions
diff --git a/chrome/browser/views/options/general_page_view.h b/chrome/browser/views/options/general_page_view.h
index 597db44..1ea1ae1 100644
--- a/chrome/browser/views/options/general_page_view.h
+++ b/chrome/browser/views/options/general_page_view.h
@@ -27,8 +27,8 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-#ifndef CHROME_BROWSER_VIEWS_OPTIONS_GENERAL_PAGE_VIEW_H__
-#define CHROME_BROWSER_VIEWS_OPTIONS_GENERAL_PAGE_VIEW_H__
+#ifndef CHROME_BROWSER_VIEWS_OPTIONS_GENERAL_PAGE_VIEW_H_
+#define CHROME_BROWSER_VIEWS_OPTIONS_GENERAL_PAGE_VIEW_H_
#include "chrome/browser/views/options/options_page_view.h"
#include "chrome/browser/views/shelf_item_dialog.h"
@@ -126,6 +126,12 @@ class GeneralPageView : public OptionsPageView,
const std::wstring& title,
const GURL& url);
+ // Sets the home page preferences for kNewTabPageIsHomePage and kHomePage.
+ // If a blank string is passed in we revert to using NewTab page as the Home
+ // page. When setting the Home Page to NewTab page, we preserve the old value
+ // of kHomePage (we don't overwrite it).
+ void SetHomepage(const std::wstring& homepage);
+
// Invoked when the selection of the table view changes. Updates the enabled
// property of the remove button.
virtual void OnSelectionChanged();
@@ -153,6 +159,7 @@ class GeneralPageView : public OptionsPageView,
ChromeViews::RadioButton* homepage_use_url_radio_;
ChromeViews::TextField* homepage_use_url_textfield_;
ChromeViews::CheckBox* homepage_show_home_button_checkbox_;
+ BooleanPrefMember new_tab_page_is_home_page_;
StringPrefMember homepage_;
BooleanPrefMember show_home_button_;
@@ -175,4 +182,4 @@ class GeneralPageView : public OptionsPageView,
DISALLOW_EVIL_CONSTRUCTORS(GeneralPageView);
};
-#endif // #ifndef CHROME_BROWSER_VIEWS_OPTIONS_GENERAL_PAGE_VIEW_H__
+#endif // CHROME_BROWSER_VIEWS_OPTIONS_GENERAL_PAGE_VIEW_H_