summaryrefslogtreecommitdiffstats
path: root/chrome/browser/sync/personalization.h
diff options
context:
space:
mode:
authortim@chromium.org <tim@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-08-15 01:19:11 +0000
committertim@chromium.org <tim@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-08-15 01:19:11 +0000
commit48352c11fe849f7f786c43bdfe293dc2c58d12c5 (patch)
tree57708d7e211d7cbcf2b81b1395740f5859a62aa1 /chrome/browser/sync/personalization.h
parent20cc723d102acb16b61789714bbf443ba3d7d1f5 (diff)
downloadchromium_src-48352c11fe849f7f786c43bdfe293dc2c58d12c5.zip
chromium_src-48352c11fe849f7f786c43bdfe293dc2c58d12c5.tar.gz
chromium_src-48352c11fe849f7f786c43bdfe293dc2c58d12c5.tar.bz2
Some personalization cleanup:
- Removes ProfilePersonalization (which is why the CL appears huge) - Makes Profile do the work ProfilePersonalization did for creating PSS - cloudy:stats > about:sync - Removes the cloudy:// scheme and uses chrome:// for resources. (Note SyncResourcesSource is a straight copy of CloudyResourceSource). - Moves prefs and switches to pref_names and chrome_switches. BUG=none TEST=ProfileSyncServiceTest, LiveBookmarkSyncTests, SyncSetupWizardTest Review URL: http://codereview.chromium.org/164544 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@23505 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/sync/personalization.h')
-rw-r--r--chrome/browser/sync/personalization.h58
1 files changed, 2 insertions, 56 deletions
diff --git a/chrome/browser/sync/personalization.h b/chrome/browser/sync/personalization.h
index f278d28d..fb6a4ed 100644
--- a/chrome/browser/sync/personalization.h
+++ b/chrome/browser/sync/personalization.h
@@ -27,58 +27,15 @@ class ProfileSyncServiceObserver;
namespace views { class View; }
-// TODO(ncarter): Move these switches into chrome_switches. They are here
-// now because we want to keep them secret during early development.
-namespace switches {
-extern const wchar_t kSyncServiceURL[];
-extern const wchar_t kSyncServicePort[];
-extern const wchar_t kSyncUserForTest[];
-extern const wchar_t kSyncPasswordForTest[];
-}
-
-// Names of various preferences.
-// TODO(munjal): Move these preferences to common/pref_names.h.
-namespace prefs {
-extern const wchar_t kSyncPath[];
-extern const wchar_t kSyncLastSyncedTime[];
-extern const wchar_t kSyncUserName[];
-extern const wchar_t kSyncHasSetupCompleted[];
-}
-
-// Contains a profile sync service, which is initialized at profile creation.
-// A pointer to this class is passed as a handle.
-class ProfilePersonalization {
- public:
- ProfilePersonalization() {}
- virtual ~ProfilePersonalization() {}
-
- virtual ProfileSyncService* sync_service() = 0;
-
- private:
- DISALLOW_COPY_AND_ASSIGN(ProfilePersonalization);
-};
-
// Contains methods to perform Personalization-related tasks on behalf of the
// caller.
namespace Personalization {
-// Checks if P13N is globally disabled or not, and that |profile| has a valid
-// ProfilePersonalization member (it can be NULL for TestingProfiles).
-bool IsSyncEnabled(Profile* profile);
-
// Returns whether |url| should be loaded in a DOMUI.
bool NeedsDOMUI(const GURL& url);
-// Construct a new ProfilePersonalization and return it so the caller can take
-// ownership.
-ProfilePersonalization* CreateProfilePersonalization(Profile* p);
-
-// The caller of Create...() above should call this when the returned
-// ProfilePersonalization object should be deleted.
-void CleanupProfilePersonalization(ProfilePersonalization* p);
-
-// Handler for "cloudy:stats"
-std::string MakeCloudyStats();
+// Handler for "about:sync"
+std::string AboutSync();
// Construct a new DOMMessageHandler for the new tab page |dom_ui|.
DOMMessageHandler* CreateNewTabPageHandler(DOMUI* dom_ui);
@@ -94,16 +51,5 @@ std::wstring GetMenuItemInfoText(Browser* browser);
void HandleMenuItemClick(Profile* p);
} // namespace Personalization
-// The internal scheme used to retrieve HTML resources for personalization
-// related code (e.g cloudy:stats, GAIA login page).
-// We need to ensure the GAIA login HTML is loaded into an HTMLDialogContents.
-// Outside of p13n (for the time being) only "gears://" gives this (see
-// HtmlDialogContents::IsHtmlDialogUrl) for the application shortcut dialog.
-// TODO(timsteele): We should have a robust way to handle this to allow more
-// reuse of our HTML dialog code, perhaps by using a dedicated "dialog-resource"
-// scheme (chrome-resource is coupled to DOM_UI). Figure out if that is the best
-// course of action / pitch this idea to chromium-dev.
-static const char kPersonalizationScheme[] = "cloudy";
-
#endif // CHROME_BROWSER_SYNC_PERSONALIZATION_H_
#endif // CHROME_PERSONALIZATION