summaryrefslogtreecommitdiff
path: root/chromium/ui/base/idle/idle_internal.cc
diff options
context:
space:
mode:
Diffstat (limited to 'chromium/ui/base/idle/idle_internal.cc')
-rw-r--r--chromium/ui/base/idle/idle_internal.cc16
1 files changed, 16 insertions, 0 deletions
diff --git a/chromium/ui/base/idle/idle_internal.cc b/chromium/ui/base/idle/idle_internal.cc
new file mode 100644
index 00000000000..ac62882ee5f
--- /dev/null
+++ b/chromium/ui/base/idle/idle_internal.cc
@@ -0,0 +1,16 @@
+// Copyright 2019 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.
+
+#include "ui/base/idle/idle_internal.h"
+
+#include "base/no_destructor.h"
+
+namespace ui {
+
+base::Optional<IdleState>& IdleStateForTesting() {
+ static base::NoDestructor<base::Optional<IdleState>> idle_state;
+ return *idle_state;
+}
+
+} // namespace ui