[automerger skipped] Import translations. DO NOT MERGE ANYWHERE am: ed7db295ed -s ours am: 90b29aba57 -s ours
am skip reason: subject contains skip directive
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/ThemePicker/+/23982607
Change-Id: I85f286d14acaaf71915274e410ba8c28fca08a84
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
diff --git a/.gitignore b/.gitignore
new file mode 100644
index 0000000..bff2d76
--- /dev/null
+++ b/.gitignore
@@ -0,0 +1 @@
+*.iml
diff --git a/Android.bp b/Android.bp
index f6c8558..9c9c222 100644
--- a/Android.bp
+++ b/Android.bp
@@ -82,6 +82,7 @@
"androidx.lifecycle_lifecycle-viewmodel-ktx",
"androidx.recyclerview_recyclerview",
"SystemUICustomizationLib",
+ "hilt_android",
],
jni_libs: [
diff --git a/res/values-ja/strings.xml b/res/values-ja/strings.xml
index 07ec012..fe804f6 100644
--- a/res/values-ja/strings.xml
+++ b/res/values-ja/strings.xml
@@ -136,7 +136,10 @@
<string name="content_description_expressive_color_option" msgid="6081295313456341282">"メインの表現力豊かなテーマ"</string>
<string name="content_description_default_color_option" msgid="7011899327541080695">"デフォルトのカラー オプション"</string>
<string name="content_description_color_option" msgid="4169813692012119578">"カラー オプション <xliff:g id="ID_1">%1$d</xliff:g>"</string>
- <string name="scroll_forward_and_select" msgid="6156132388656395769">"別の文字盤を選択するには、左にスワイプします"</string>
- <string name="scroll_backward_and_select" msgid="5472202348434803757">"別の文字盤を選択するには、右にスワイプします"</string>
- <string name="custom_clocks_label" msgid="8168419717593569347">"カスタム時計"</string>
+ <!-- no translation found for scroll_forward_and_select (6156132388656395769) -->
+ <skip />
+ <!-- no translation found for scroll_backward_and_select (5472202348434803757) -->
+ <skip />
+ <!-- no translation found for custom_clocks_label (8168419717593569347) -->
+ <skip />
</resources>
diff --git a/res/values-ml/strings.xml b/res/values-ml/strings.xml
index 0360316..84e04c4 100644
--- a/res/values-ml/strings.xml
+++ b/res/values-ml/strings.xml
@@ -136,7 +136,10 @@
<string name="content_description_expressive_color_option" msgid="6081295313456341282">"പ്രാഥമിക എക്സ്പ്രസീവ് തീം"</string>
<string name="content_description_default_color_option" msgid="7011899327541080695">"ഡിഫോൾട്ട് വർണ്ണ ഓപ്ഷൻ"</string>
<string name="content_description_color_option" msgid="4169813692012119578">"വർണ്ണ ഓപ്ഷൻ <xliff:g id="ID_1">%1$d</xliff:g>"</string>
- <string name="scroll_forward_and_select" msgid="6156132388656395769">"മറ്റൊരു ക്ലോക്ക് ഫേസ് തിരഞ്ഞെടുക്കാൻ ഇടതുഭാഗത്തേക്ക് സ്വൈപ്പ് ചെയ്യുക"</string>
- <string name="scroll_backward_and_select" msgid="5472202348434803757">"മറ്റൊരു ക്ലോക്ക് ഫേസ് തിരഞ്ഞെടുക്കാൻ വലതുഭാഗത്തേക്ക് സ്വൈപ്പ് ചെയ്യുക"</string>
- <string name="custom_clocks_label" msgid="8168419717593569347">"ഇഷ്ടാനുസൃത ക്ലോക്കുകൾ"</string>
+ <!-- no translation found for scroll_forward_and_select (6156132388656395769) -->
+ <skip />
+ <!-- no translation found for scroll_backward_and_select (5472202348434803757) -->
+ <skip />
+ <!-- no translation found for custom_clocks_label (8168419717593569347) -->
+ <skip />
</resources>
diff --git a/res/values-ms/strings.xml b/res/values-ms/strings.xml
index c1be28d..8f16ecb 100644
--- a/res/values-ms/strings.xml
+++ b/res/values-ms/strings.xml
@@ -136,7 +136,10 @@
<string name="content_description_expressive_color_option" msgid="6081295313456341282">"Tema ekspresif utama"</string>
<string name="content_description_default_color_option" msgid="7011899327541080695">"Pilihan warna lalai"</string>
<string name="content_description_color_option" msgid="4169813692012119578">"Pilihan warna <xliff:g id="ID_1">%1$d</xliff:g>"</string>
- <string name="scroll_forward_and_select" msgid="6156132388656395769">"Leret ke kiri untuk memilih muka jam yang lain"</string>
- <string name="scroll_backward_and_select" msgid="5472202348434803757">"Leret ke kanan untuk memilih muka jam yang lain"</string>
- <string name="custom_clocks_label" msgid="8168419717593569347">"Jam Tersuai"</string>
+ <!-- no translation found for scroll_forward_and_select (6156132388656395769) -->
+ <skip />
+ <!-- no translation found for scroll_backward_and_select (5472202348434803757) -->
+ <skip />
+ <!-- no translation found for custom_clocks_label (8168419717593569347) -->
+ <skip />
</resources>
diff --git a/res/values-tl/strings.xml b/res/values-tl/strings.xml
index efef868..d49233b 100644
--- a/res/values-tl/strings.xml
+++ b/res/values-tl/strings.xml
@@ -136,7 +136,10 @@
<string name="content_description_expressive_color_option" msgid="6081295313456341282">"Pangunahing expressive na tema"</string>
<string name="content_description_default_color_option" msgid="7011899327541080695">"Default na opsyon sa kulay"</string>
<string name="content_description_color_option" msgid="4169813692012119578">"Opsyon sa kulay na <xliff:g id="ID_1">%1$d</xliff:g>"</string>
- <string name="scroll_forward_and_select" msgid="6156132388656395769">"Mag-swipe pakaliwa para pumili ng ibang clock face"</string>
- <string name="scroll_backward_and_select" msgid="5472202348434803757">"Mag-swipe pakanan para pumili ng ibang clock face"</string>
- <string name="custom_clocks_label" msgid="8168419717593569347">"Mga Custom na Orasan"</string>
+ <!-- no translation found for scroll_forward_and_select (6156132388656395769) -->
+ <skip />
+ <!-- no translation found for scroll_backward_and_select (5472202348434803757) -->
+ <skip />
+ <!-- no translation found for custom_clocks_label (8168419717593569347) -->
+ <skip />
</resources>
diff --git a/src/com/android/customization/module/StatsLogUserEventLogger.java b/src/com/android/customization/module/StatsLogUserEventLogger.java
index 32e0599..e16f3ee 100644
--- a/src/com/android/customization/module/StatsLogUserEventLogger.java
+++ b/src/com/android/customization/module/StatsLogUserEventLogger.java
@@ -47,8 +47,6 @@
import com.android.customization.model.color.ColorOption;
import com.android.customization.model.grid.GridOption;
import com.android.customization.model.theme.ThemeBundle;
-import com.android.wallpaper.module.Injector;
-import com.android.wallpaper.module.InjectorProvider;
import com.android.wallpaper.module.NoOpUserEventLogger;
import com.android.wallpaper.module.WallpaperPreferences;
import com.android.wallpaper.module.WallpaperStatusChecker;
@@ -61,16 +59,17 @@
*/
public class StatsLogUserEventLogger extends NoOpUserEventLogger implements ThemesUserEventLogger {
- private static final String TAG = "StatsLogUserEventLogger";
private final Context mContext;
private final WallpaperPreferences mPreferences;
private final WallpaperStatusChecker mWallpaperStatusChecker;
- public StatsLogUserEventLogger(Context appContext) {
+ public StatsLogUserEventLogger(
+ Context appContext,
+ WallpaperPreferences preferences,
+ WallpaperStatusChecker wallpaperStatusChecker) {
mContext = appContext;
- Injector injector = InjectorProvider.getInjector();
- mPreferences = injector.getPreferences(appContext);
- mWallpaperStatusChecker = injector.getWallpaperStatusChecker();
+ mPreferences = preferences;
+ mWallpaperStatusChecker = wallpaperStatusChecker;
}
@Override
@@ -140,7 +139,7 @@
@Override
public void logSnapshot() {
- final boolean isLockWallpaperSet = mWallpaperStatusChecker.isLockWallpaperSet(mContext);
+ final boolean isLockWallpaperSet = mWallpaperStatusChecker.isLockWallpaperSet();
final String homeCollectionId = mPreferences.getHomeWallpaperCollectionId();
final String homeRemoteId = mPreferences.getHomeWallpaperRemoteId();
final String effects = mPreferences.getHomeWallpaperEffects();
diff --git a/src/com/android/customization/module/ThemePickerInjector.kt b/src/com/android/customization/module/ThemePickerInjector.kt
index cceb896..423e19a 100644
--- a/src/com/android/customization/module/ThemePickerInjector.kt
+++ b/src/com/android/customization/module/ThemePickerInjector.kt
@@ -183,8 +183,14 @@
@Synchronized
override fun getUserEventLogger(context: Context): ThemesUserEventLogger {
- return if (userEventLogger != null) userEventLogger as ThemesUserEventLogger
- else StatsLogUserEventLogger(context.applicationContext).also { userEventLogger = it }
+ val appContext = context.applicationContext
+ return userEventLogger as? ThemesUserEventLogger
+ ?: StatsLogUserEventLogger(
+ appContext,
+ getPreferences(appContext),
+ getWallpaperStatusChecker(appContext),
+ )
+ .also { userEventLogger = it }
}
@Synchronized
diff --git a/src/com/android/customization/picker/clock/data/repository/ClockPickerRepositoryImpl.kt b/src/com/android/customization/picker/clock/data/repository/ClockPickerRepositoryImpl.kt
index be6c6cb..2d22c38 100644
--- a/src/com/android/customization/picker/clock/data/repository/ClockPickerRepositoryImpl.kt
+++ b/src/com/android/customization/picker/clock/data/repository/ClockPickerRepositoryImpl.kt
@@ -33,6 +33,7 @@
import kotlinx.coroutines.flow.SharedFlow
import kotlinx.coroutines.flow.SharingStarted
import kotlinx.coroutines.flow.callbackFlow
+import kotlinx.coroutines.flow.distinctUntilChanged
import kotlinx.coroutines.flow.flowOn
import kotlinx.coroutines.flow.map
import kotlinx.coroutines.flow.mapLatest
@@ -146,9 +147,10 @@
)
.map { setting -> setting == 1 }
.map { isDynamic -> if (isDynamic) ClockSize.DYNAMIC else ClockSize.SMALL }
+ .distinctUntilChanged()
.shareIn(
scope = scope,
- started = SharingStarted.WhileSubscribed(),
+ started = SharingStarted.Eagerly,
replay = 1,
)
diff --git a/src/com/android/customization/picker/clock/data/repository/ClockRegistryProvider.kt b/src/com/android/customization/picker/clock/data/repository/ClockRegistryProvider.kt
index 652ffdd..b197edf 100644
--- a/src/com/android/customization/picker/clock/data/repository/ClockRegistryProvider.kt
+++ b/src/com/android/customization/picker/clock/data/repository/ClockRegistryProvider.kt
@@ -29,6 +29,7 @@
import com.android.systemui.shared.plugins.PluginManagerImpl
import com.android.systemui.shared.plugins.PluginPrefs
import com.android.systemui.shared.system.UncaughtExceptionPreHandlerManager_Factory
+import com.android.wallpaper.module.InjectorProvider
import java.util.concurrent.Executors
import kotlinx.coroutines.CoroutineDispatcher
import kotlinx.coroutines.CoroutineScope
@@ -55,6 +56,8 @@
DefaultClockProvider(context, LayoutInflater.from(context), context.resources),
keepAllLoaded = true,
subTag = "Picker",
+ isTransitClockEnabled =
+ InjectorProvider.getInjector().getFlags().isTransitClockEnabled(context)
)
}
diff --git a/src/com/android/customization/picker/clock/ui/fragment/ClockCustomDemoFragment.kt b/src/com/android/customization/picker/clock/ui/fragment/ClockCustomDemoFragment.kt
deleted file mode 100644
index f138d6a..0000000
--- a/src/com/android/customization/picker/clock/ui/fragment/ClockCustomDemoFragment.kt
+++ /dev/null
@@ -1,93 +0,0 @@
-package com.android.customization.picker.clock.ui.fragment
-
-import android.content.Context
-import android.os.Bundle
-import android.util.TypedValue
-import android.view.ContextThemeWrapper
-import android.view.LayoutInflater
-import android.view.View
-import android.view.ViewGroup
-import android.view.ViewGroup.LayoutParams.MATCH_PARENT
-import android.view.ViewGroup.LayoutParams.WRAP_CONTENT
-import android.widget.FrameLayout
-import android.widget.TextView
-import android.widget.Toast
-import androidx.core.view.setPadding
-import androidx.recyclerview.widget.LinearLayoutManager
-import androidx.recyclerview.widget.RecyclerView
-import com.android.customization.module.ThemePickerInjector
-import com.android.internal.annotations.VisibleForTesting
-import com.android.systemui.plugins.ClockMetadata
-import com.android.systemui.shared.clocks.ClockRegistry
-import com.android.wallpaper.R
-import com.android.wallpaper.module.InjectorProvider
-import com.android.wallpaper.picker.AppbarFragment
-
-class ClockCustomDemoFragment : AppbarFragment() {
- @VisibleForTesting lateinit var recyclerView: RecyclerView
- @VisibleForTesting lateinit var clockRegistry: ClockRegistry
-
- override fun onCreateView(
- inflater: LayoutInflater,
- container: ViewGroup?,
- savedInstanceState: Bundle?
- ): View {
- val view = inflater.inflate(R.layout.fragment_clock_custom_picker_demo, container, false)
- setUpToolbar(view)
- clockRegistry =
- (InjectorProvider.getInjector() as ThemePickerInjector).getClockRegistry(
- requireContext(),
- )
- val listInUse = clockRegistry.getClocks().filter { "NOT_IN_USE" !in it.clockId }
-
- recyclerView = view.requireViewById(R.id.clock_preview_card_list_demo)
- recyclerView.layoutManager = LinearLayoutManager(context, RecyclerView.VERTICAL, false)
- recyclerView.adapter =
- ClockRecyclerAdapter(listInUse, requireContext()) {
- clockRegistry.currentClockId = it.clockId
- Toast.makeText(context, "${it.name} selected", Toast.LENGTH_SHORT).show()
- }
- return view
- }
-
- override fun getDefaultTitle(): CharSequence {
- return getString(R.string.clock_title)
- }
-
- internal class ClockRecyclerAdapter(
- val list: List<ClockMetadata>,
- val context: Context,
- val onClockSelected: (ClockMetadata) -> Unit
- ) : RecyclerView.Adapter<ClockRecyclerAdapter.ViewHolder>() {
- class ViewHolder(val view: View, val textView: TextView, val onItemClicked: (Int) -> Unit) :
- RecyclerView.ViewHolder(view) {
- init {
- itemView.setOnClickListener { onItemClicked(absoluteAdapterPosition) }
- }
- }
-
- override fun onCreateViewHolder(viewGroup: ViewGroup, viewType: Int): ViewHolder {
- val rootView = FrameLayout(viewGroup.context)
- val textView =
- TextView(ContextThemeWrapper(viewGroup.context, R.style.SectionTitleTextStyle))
- textView.setPadding(ITEM_PADDING)
- rootView.addView(textView)
- val outValue = TypedValue()
- context.theme.resolveAttribute(android.R.attr.selectableItemBackground, outValue, true)
- rootView.setBackgroundResource(outValue.resourceId)
- val lp = RecyclerView.LayoutParams(MATCH_PARENT, WRAP_CONTENT)
- rootView.layoutParams = lp
- return ViewHolder(rootView, textView) { onClockSelected(list[it]) }
- }
-
- override fun onBindViewHolder(viewHolder: ViewHolder, position: Int) {
- viewHolder.textView.text = list[position].name
- }
-
- override fun getItemCount() = list.size
-
- companion object {
- val ITEM_PADDING = 40
- }
- }
-}
diff --git a/src/com/android/customization/picker/CustomizationPickerApplication.java b/src_override/com/android/customization/picker/CustomizationPickerApplication.java
similarity index 80%
rename from src/com/android/customization/picker/CustomizationPickerApplication.java
rename to src_override/com/android/customization/picker/CustomizationPickerApplication.java
index 178cfbf..2e549ff 100644
--- a/src/com/android/customization/picker/CustomizationPickerApplication.java
+++ b/src_override/com/android/customization/picker/CustomizationPickerApplication.java
@@ -20,7 +20,13 @@
import com.android.customization.module.ThemePickerInjector;
import com.android.wallpaper.module.InjectorProvider;
-public class CustomizationPickerApplication extends Application {
+import dagger.hilt.android.HiltAndroidApp;
+
+/**
+ * Application subclass that initializes the injector.
+ */
+@HiltAndroidApp(Application.class)
+public class CustomizationPickerApplication extends Hilt_CustomizationPickerApplication {
@Override
public void onCreate() {
super.onCreate();
diff --git a/tests/robotests/src/com/android/customization/picker/clock/ui/fragment/ClockCustomDemoFragmentTest.kt b/tests/robotests/src/com/android/customization/picker/clock/ui/fragment/ClockCustomDemoFragmentTest.kt
deleted file mode 100644
index 0a54312..0000000
--- a/tests/robotests/src/com/android/customization/picker/clock/ui/fragment/ClockCustomDemoFragmentTest.kt
+++ /dev/null
@@ -1,75 +0,0 @@
-package com.android.customization.picker.clock.ui.fragment
-
-import android.view.View
-import androidx.appcompat.app.AppCompatActivity
-import androidx.recyclerview.widget.LinearLayoutManager
-import androidx.recyclerview.widget.RecyclerView
-import com.android.systemui.plugins.ClockMetadata
-import com.android.systemui.plugins.ClockSettings
-import com.android.systemui.plugins.PluginManager
-import com.android.systemui.shared.clocks.ClockRegistry
-import org.junit.Assert
-import org.junit.Before
-import org.junit.Ignore
-import org.junit.Test
-import org.junit.runner.RunWith
-import org.mockito.Mock
-import org.mockito.Mockito.verify
-import org.mockito.Mockito.`when` as whenever
-import org.mockito.MockitoAnnotations
-import org.robolectric.Robolectric
-import org.robolectric.RobolectricTestRunner
-import org.robolectric.annotation.Config
-
-/** Tests of [ClockCustomDemoFragment]. */
-@RunWith(RobolectricTestRunner::class)
-@Config(manifest = Config.NONE)
-@Ignore("b/270606895")
-class ClockCustomDemoFragmentTest {
- private lateinit var mActivity: AppCompatActivity
- private var mClockCustomDemoFragment: ClockCustomDemoFragment? = null
- @Mock private lateinit var registry: ClockRegistry
- @Mock private lateinit var mockPluginManager: PluginManager
-
- private var settingValue: ClockSettings? = null
-
- @Before
- fun setUp() {
- MockitoAnnotations.initMocks(this)
- mActivity = Robolectric.buildActivity(AppCompatActivity::class.java).get()
- mClockCustomDemoFragment = ClockCustomDemoFragment()
- whenever(registry.getClocks())
- .thenReturn(
- listOf(
- ClockMetadata("CLOCK_1", "Clock 1"),
- ClockMetadata("CLOCK_2", "Clock 2"),
- ClockMetadata("CLOCK_NOT_IN_USE", "Clock not in use")
- )
- )
-
- mClockCustomDemoFragment!!.clockRegistry = registry
- mClockCustomDemoFragment!!.recyclerView = RecyclerView(mActivity)
- mClockCustomDemoFragment!!.recyclerView.layoutManager =
- LinearLayoutManager(mActivity, RecyclerView.VERTICAL, false)
- }
-
- @Test
- fun testItemCount_getCorrectClockCount() {
- Assert.assertEquals(3, mClockCustomDemoFragment!!.recyclerView.adapter!!.itemCount)
- }
-
- @Test
- fun testClick_setCorrectClockId() {
- mClockCustomDemoFragment!!
- .recyclerView
- .measure(View.MeasureSpec.UNSPECIFIED, View.MeasureSpec.UNSPECIFIED)
- mClockCustomDemoFragment!!.recyclerView.layout(0, 0, 100, 10000)
- val testPosition = 1
- mClockCustomDemoFragment!!
- .recyclerView
- .findViewHolderForAdapterPosition(testPosition)
- ?.itemView
- ?.performClick()
- verify(registry).currentClockId = "CLOCK_1"
- }
-}
diff --git a/tests/src/com/android/customization/testing/TestDefaultCustomizationPreferences.java b/tests/src/com/android/customization/testing/TestDefaultCustomizationPreferences.java
index bcf5a5f..81890f0 100644
--- a/tests/src/com/android/customization/testing/TestDefaultCustomizationPreferences.java
+++ b/tests/src/com/android/customization/testing/TestDefaultCustomizationPreferences.java
@@ -1,3 +1,18 @@
+/*
+ * Copyright (C) 2019 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
package com.android.customization.testing;
import android.content.Context;
diff --git a/tests/src/com/android/customization/testing/TestDrawableLayerResolver.java b/tests/src/com/android/customization/testing/TestDrawableLayerResolver.java
index e507221..8b16299 100644
--- a/tests/src/com/android/customization/testing/TestDrawableLayerResolver.java
+++ b/tests/src/com/android/customization/testing/TestDrawableLayerResolver.java
@@ -1,3 +1,18 @@
+/*
+ * Copyright (C) 2019 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
package com.android.customization.testing;
import android.graphics.drawable.Drawable;
diff --git a/tests/src/com/android/customization/testing/TestPackageStatusNotifier.java b/tests/src/com/android/customization/testing/TestPackageStatusNotifier.java
index 1e6a1a2..2aadae8 100644
--- a/tests/src/com/android/customization/testing/TestPackageStatusNotifier.java
+++ b/tests/src/com/android/customization/testing/TestPackageStatusNotifier.java
@@ -1,3 +1,18 @@
+/*
+ * Copyright (C) 2019 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
package com.android.customization.testing;
import com.android.wallpaper.module.PackageStatusNotifier;
diff --git a/tests/src/com/android/customization/testing/TestThemeManager.java b/tests/src/com/android/customization/testing/TestThemeManager.java
index c4d25fb..5175b24 100644
--- a/tests/src/com/android/customization/testing/TestThemeManager.java
+++ b/tests/src/com/android/customization/testing/TestThemeManager.java
@@ -1,3 +1,18 @@
+/*
+ * Copyright (C) 2019 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
package com.android.customization.testing;
import androidx.fragment.app.FragmentActivity;
diff --git a/tests/src/com/android/customization/testing/TestThemesUserEventLogger.java b/tests/src/com/android/customization/testing/TestThemesUserEventLogger.java
index 2bb2082..22a5b94 100644
--- a/tests/src/com/android/customization/testing/TestThemesUserEventLogger.java
+++ b/tests/src/com/android/customization/testing/TestThemesUserEventLogger.java
@@ -1,3 +1,18 @@
+/*
+ * Copyright (C) 2019 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
package com.android.customization.testing;
import com.android.customization.model.color.ColorOption;