OLD | NEW |
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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 #include "vr_usage_monitor.h" | 5 #include "vr_usage_monitor.h" |
6 #include "base/logging.h" | 6 #include "base/logging.h" |
7 #include "base/metrics/histogram_macros.h" | 7 #include "base/metrics/histogram_macros.h" |
8 #include "chrome/browser/browser_process.h" | 8 #include "chrome/browser/browser_process.h" |
9 #include "components/rappor/rappor_utils.h" | 9 #include "components/rappor/public/rappor_utils.h" |
10 #include "content/public/browser/browser_thread.h" | 10 #include "content/public/browser/browser_thread.h" |
11 | 11 |
12 namespace vr_shell { | 12 namespace vr_shell { |
13 | 13 |
14 // minimum duration: 7 seconds for video, no minimum for headset/vr modes | 14 // minimum duration: 7 seconds for video, no minimum for headset/vr modes |
15 // maximum gap: 7 seconds between videos. no gap for headset/vr-modes | 15 // maximum gap: 7 seconds between videos. no gap for headset/vr-modes |
16 namespace { | 16 namespace { |
17 base::TimeDelta minimumVideoSessionDuration(base::TimeDelta::FromSecondsD(7)); | 17 base::TimeDelta minimumVideoSessionDuration(base::TimeDelta::FromSecondsD(7)); |
18 base::TimeDelta maximumVideoSessionGap(base::TimeDelta::FromSecondsD(7)); | 18 base::TimeDelta maximumVideoSessionGap(base::TimeDelta::FromSecondsD(7)); |
19 | 19 |
(...skipping 331 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
351 } | 351 } |
352 | 352 |
353 void VrMetricsHelper::DidToggleFullscreenModeForTab(bool entered_fullscreen, | 353 void VrMetricsHelper::DidToggleFullscreenModeForTab(bool entered_fullscreen, |
354 bool will_cause_resize) { | 354 bool will_cause_resize) { |
355 DCHECK_EQ(thread_id_, base::PlatformThread::CurrentId()); | 355 DCHECK_EQ(thread_id_, base::PlatformThread::CurrentId()); |
356 is_fullscreen_ = entered_fullscreen; | 356 is_fullscreen_ = entered_fullscreen; |
357 UpdateMode(); | 357 UpdateMode(); |
358 } | 358 } |
359 | 359 |
360 } // namespace vr_shell | 360 } // namespace vr_shell |
OLD | NEW |