OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 "chromecast/base/android/system_time_change_notifier_android.h" | 5 #include "chromecast/base/android/system_time_change_notifier_android.h" |
6 | 6 |
| 7 #include "base/android/context_utils.h" |
7 #include "jni/SystemTimeChangeNotifierAndroid_jni.h" | 8 #include "jni/SystemTimeChangeNotifierAndroid_jni.h" |
8 | 9 |
9 namespace chromecast { | 10 namespace chromecast { |
10 | 11 |
11 // static | 12 // static |
12 bool SystemTimeChangeNotifierAndroid::RegisterJni(JNIEnv* env) { | 13 bool SystemTimeChangeNotifierAndroid::RegisterJni(JNIEnv* env) { |
13 return RegisterNativesImpl(env); | 14 return RegisterNativesImpl(env); |
14 } | 15 } |
15 | 16 |
16 SystemTimeChangeNotifierAndroid::SystemTimeChangeNotifierAndroid() { | 17 SystemTimeChangeNotifierAndroid::SystemTimeChangeNotifierAndroid() { |
(...skipping 14 matching lines...) Expand all Loading... |
31 JNIEnv* env = base::android::AttachCurrentThread(); | 32 JNIEnv* env = base::android::AttachCurrentThread(); |
32 Java_SystemTimeChangeNotifierAndroid_finalizeFromNative( | 33 Java_SystemTimeChangeNotifierAndroid_finalizeFromNative( |
33 env, java_notifier_.obj()); | 34 env, java_notifier_.obj()); |
34 } | 35 } |
35 | 36 |
36 void SystemTimeChangeNotifierAndroid::OnTimeChanged(JNIEnv* env, jobject jobj) { | 37 void SystemTimeChangeNotifierAndroid::OnTimeChanged(JNIEnv* env, jobject jobj) { |
37 NotifySystemTimeChanged(); | 38 NotifySystemTimeChanged(); |
38 } | 39 } |
39 | 40 |
40 } // namespace chromecast | 41 } // namespace chromecast |
OLD | NEW |