Index: chrome/browser/chromeos/drive/file_system_util.h |
diff --git a/chrome/browser/chromeos/drive/file_system_util.h b/chrome/browser/chromeos/drive/file_system_util.h |
index 96029f8eca2afbee75d0afcd0aa56669863a8a3d..7766f0c74fe30c47a049bb21c3b06c9bc49dad07 100644 |
--- a/chrome/browser/chromeos/drive/file_system_util.h |
+++ b/chrome/browser/chromeos/drive/file_system_util.h |
@@ -204,6 +204,25 @@ std::string ReadResourceIdFromGDocFile(const base::FilePath& file_path); |
// Returns true if Drive is enabled for the given Profile. |
bool IsDriveEnabledForProfile(Profile* profile); |
+// Enum type for describing the current connection status to Drive. |
+enum ConnectionStatusType { |
+ // Disconnected because Drive service is unavailable for this account (either |
+ // disabled by a flag or the account has no Google account (e.g., guests)). |
+ DRIVE_DISCONNECTED_NOSERVICE, |
+ // Disconnected because no network is available. |
+ DRIVE_DISCONNECTED_NONETWORK, |
+ // Disconnected because authentication is not ready. |
+ DRIVE_DISCONNECTED_NOTREADY, |
+ // Connected by cellular network. Background sync is disabled. |
+ DRIVE_CONNECTED_METERED, |
+ // Connected without condition (WiFi, Ethernet, or cellular with the |
+ // disable-sync preference turned off.) |
+ DRIVE_CONNECTED, |
+}; |
+ |
+// Returns the Drive connection status for the |profile|. |
+ConnectionStatusType GetDriveConnectionStatus(Profile* profile); |
+ |
} // namespace util |
} // namespace drive |