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

Unified Diff: chromecast/crash/app_state_tracker.h

Issue 1154383006: Adding crash utilities to chromecast/crash. (Closed) Base URL: https://eureka-internal.googlesource.com/chromium/src@master
Patch Set: Linux-specific utils moved to linux/ Created 5 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: chromecast/crash/app_state_tracker.h
diff --git a/chromecast/crash/app_state_tracker.h b/chromecast/crash/app_state_tracker.h
new file mode 100644
index 0000000000000000000000000000000000000000..f8a17443ed550be6c08b5900b6abce6f8e7155bc
--- /dev/null
+++ b/chromecast/crash/app_state_tracker.h
@@ -0,0 +1,26 @@
+// Copyright 2015 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef CHROMECAST_CRASH_APP_STATE_TRACKER_H_
+#define CHROMECAST_CRASH_APP_STATE_TRACKER_H_
+
+#include <string>
+
+namespace chromecast {
+
+class AppStateTracker {
+ public:
+ // Sets current app state.
+ static void SetLastLaunchedApp(const std::string& app_id);
+ static void SetCurrentApp(const std::string& app_id);
+
+ // Get current app state
+ static std::string GetLastLaunchedApp();
+ static std::string GetCurrentApp();
+ static std::string GetPreviousApp();
+};
+
+} // namespace chromecast
+
+#endif // CHROMECAST_CRASH_APP_STATE_TRACKER_H_

Powered by Google App Engine
This is Rietveld 408576698