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

Side by Side Diff: chrome/browser/sync/profile_sync_service.h

Issue 9956097: suppress user/password dialog when re-enabling sync (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: resolve Drew's comments. Created 8 years, 8 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef CHROME_BROWSER_SYNC_PROFILE_SYNC_SERVICE_H_ 5 #ifndef CHROME_BROWSER_SYNC_PROFILE_SYNC_SERVICE_H_
6 #define CHROME_BROWSER_SYNC_PROFILE_SYNC_SERVICE_H_ 6 #define CHROME_BROWSER_SYNC_PROFILE_SYNC_SERVICE_H_
7 #pragma once 7 #pragma once
8 8
9 #include <list> 9 #include <list>
10 #include <string> 10 #include <string>
(...skipping 465 matching lines...) Expand 10 before | Expand all | Expand 10 after
476 // any model-modifying operations. 476 // any model-modifying operations.
477 bool ShouldPushChanges(); 477 bool ShouldPushChanges();
478 478
479 const GURL& sync_service_url() const { return sync_service_url_; } 479 const GURL& sync_service_url() const { return sync_service_url_; }
480 bool auto_start_enabled() const { return auto_start_enabled_; } 480 bool auto_start_enabled() const { return auto_start_enabled_; }
481 SigninManager* signin() const { return signin_; } 481 SigninManager* signin() const { return signin_; }
482 482
483 // Stops the sync backend and sets the flag for suppressing sync startup. 483 // Stops the sync backend and sets the flag for suppressing sync startup.
484 void StopAndSuppress(); 484 void StopAndSuppress();
485 485
486 // Resets the flag for suppressing sync startup.
487 void Unsuppress();
Andrew T Wilson (Slow) 2012/04/03 22:22:33 Is this needed? I think mostly people talk directl
kochi 2012/04/03 23:21:48 Reverted. On 2012/04/03 22:22:33, Andrew T Wilson
488
486 // Resets the flag for suppressing sync startup and starts the sync backend. 489 // Resets the flag for suppressing sync startup and starts the sync backend.
487 void UnsuppressAndStart(); 490 void UnsuppressAndStart();
488 491
489 // Marks all currently registered types as "acknowledged" so we won't prompt 492 // Marks all currently registered types as "acknowledged" so we won't prompt
490 // the user about them any more. 493 // the user about them any more.
491 void AcknowledgeSyncedTypes(); 494 void AcknowledgeSyncedTypes();
492 495
493 SyncGlobalError* sync_global_error() { return sync_global_error_.get(); } 496 SyncGlobalError* sync_global_error() { return sync_global_error_.get(); }
494 497
495 virtual const FailedDatatypesHandler& failed_datatypes_handler(); 498 virtual const FailedDatatypesHandler& failed_datatypes_handler();
(...skipping 114 matching lines...) Expand 10 before | Expand all | Expand 10 after
610 // backend is because if we had encountered an unrecoverable error we don't 613 // backend is because if we had encountered an unrecoverable error we don't
611 // want to startup once more. 614 // want to startup once more.
612 virtual void ReconfigureDatatypeManager(); 615 virtual void ReconfigureDatatypeManager();
613 616
614 // Called when the user changes the sync configuration, to update the UMA 617 // Called when the user changes the sync configuration, to update the UMA
615 // stats. 618 // stats.
616 void UpdateSelectedTypesHistogram( 619 void UpdateSelectedTypesHistogram(
617 bool sync_everything, 620 bool sync_everything,
618 const syncable::ModelTypeSet chosen_types) const; 621 const syncable::ModelTypeSet chosen_types) const;
619 622
623 // Refresh spare sync bootstrap token for re-enabling the sync service.
624 // Call this whenever user enters GAIA login password.
625 void RefreshSpareBootstrapToken(const std::string& passphrase);
626
620 // Factory used to create various dependent objects. 627 // Factory used to create various dependent objects.
621 scoped_ptr<ProfileSyncComponentsFactory> factory_; 628 scoped_ptr<ProfileSyncComponentsFactory> factory_;
622 629
623 // The profile whose data we are synchronizing. 630 // The profile whose data we are synchronizing.
624 Profile* profile_; 631 Profile* profile_;
625 632
626 // The class that handles getting, setting, and persisting sync 633 // The class that handles getting, setting, and persisting sync
627 // preferences. 634 // preferences.
628 browser_sync::SyncPrefs sync_prefs_; 635 browser_sync::SyncPrefs sync_prefs_;
629 636
(...skipping 107 matching lines...) Expand 10 before | Expand all | Expand 10 after
737 bool setup_in_progress_; 744 bool setup_in_progress_;
738 745
739 DISALLOW_COPY_AND_ASSIGN(ProfileSyncService); 746 DISALLOW_COPY_AND_ASSIGN(ProfileSyncService);
740 }; 747 };
741 748
742 bool ShouldShowActionOnUI( 749 bool ShouldShowActionOnUI(
743 const browser_sync::SyncProtocolError& error); 750 const browser_sync::SyncProtocolError& error);
744 751
745 752
746 #endif // CHROME_BROWSER_SYNC_PROFILE_SYNC_SERVICE_H_ 753 #endif // CHROME_BROWSER_SYNC_PROFILE_SYNC_SERVICE_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698