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

Unified Diff: chromeos/dbus/cryptohome_client.h

Issue 2082363004: Show notifications on low disk space. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@low-disk-strings
Patch Set: Created 4 years, 6 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 side-by-side diff with in-line comments
Download patch
Index: chromeos/dbus/cryptohome_client.h
diff --git a/chromeos/dbus/cryptohome_client.h b/chromeos/dbus/cryptohome_client.h
index 15ce84f5e9fb43c6584304f32d4f19b5e48a8604..331b221e5b12f9388ecb62ea1b246e7de1ea823c 100644
--- a/chromeos/dbus/cryptohome_client.h
+++ b/chromeos/dbus/cryptohome_client.h
@@ -62,6 +62,8 @@ class CHROMEOS_EXPORT CryptohomeClient : public DBusClient {
typedef base::Callback<void(DBusMethodCallStatus call_status,
const std::vector<uint8_t>& system_salt)>
GetSystemSaltCallback;
+ // A callback to handle LowDiskSpace signals.
+ typedef base::Callback<void(uint64_t disk_free_bytes)> LowDiskSpaceHandler;
// A callback for WaitForServiceToBeAvailable().
typedef base::Callback<void(bool service_is_ready)>
WaitForServiceToBeAvailableCallback;
@@ -110,6 +112,13 @@ class CHROMEOS_EXPORT CryptohomeClient : public DBusClient {
// Resets AsyncCallStatus signal handlers.
virtual void ResetAsyncCallStatusHandlers() = 0;
+ // Sets LowDiskSpace signal handler. |handler| is called when the cryptohome
+ // partition is running out of disk space.
+ virtual void SetLowDiskSpaceHandler(const LowDiskSpaceHandler& handler) = 0;
+
+ // Resets LowDiskSpace signal handlers.
+ virtual void ResetLowDiskSpaceHandler() = 0;
+
// Runs the callback as soon as the service becomes available.
virtual void WaitForServiceToBeAvailable(
const WaitForServiceToBeAvailableCallback& callback) = 0;

Powered by Google App Engine
This is Rietveld 408576698