diff --git a/res/values/evolution_arrays.xml b/res/values/evolution_arrays.xml index 196afd0..213cbf5 100644 --- a/res/values/evolution_arrays.xml +++ b/res/values/evolution_arrays.xml @@ -162,7 +162,7 @@ - @string/themes_screen_off_animation_default + @string/default_value @string/themes_screen_off_animation_crt @string/themes_screen_off_animation_scale @@ -587,7 +587,7 @@ - @string/color_default + @string/default_value @string/quick_settings_tile_ui_style_a11_circle @string/quick_settings_tile_ui_style_a11_square @string/quick_settings_tile_ui_style_a11_mix @@ -602,7 +602,7 @@ - @string/color_default + @string/default_value @string/quick_settings_panel_style_outline @string/quick_settings_panel_style_two_tone @string/quick_settings_panel_style_color_pop @@ -801,7 +801,7 @@ - @string/color_default + @string/default_value @string/powermenu_style1 @string/powermenu_style2 @string/powermenu_style3 @@ -818,7 +818,7 @@ - @string/color_default + @string/default_value @string/qs_header_style1 @string/qs_header_style2 @string/qs_header_style3 @@ -835,7 +835,7 @@ - @string/color_default + @string/default_value @string/notif_style1 @string/notif_style2 @string/notif_style3 @@ -852,7 +852,7 @@ - @string/color_default + @string/default_value @string/progress_bar_style1 @string/progress_bar_style2 @string/progress_bar_style3 @@ -868,7 +868,7 @@ - @string/color_default + @string/default_value @string/double_layer_style @string/gradient_style @string/neumorph_style @@ -1013,4 +1013,26 @@ 2 3 + + + + @string/default_value + @string/peek_display_minimalist + + + + 0 + 1 + + + + + @string/top + @string/bottom + + + + 0 + 1 + diff --git a/res/values/evolution_strings.xml b/res/values/evolution_strings.xml index 9deb2d9..6d0e4f0 100644 --- a/res/values/evolution_strings.xml +++ b/res/values/evolution_strings.xml @@ -64,7 +64,6 @@ Charging animation Display an animation when the device is plugged in Screen off animation - Default CRT Scale UDFPS animation @@ -584,7 +583,6 @@ Hex: #ff000000 Set - Default Accent color (Default) Notification color Wallpaper color @@ -601,6 +599,9 @@ Enable Disable Boot animation applied + Default + Top + Bottom milliseconds @@ -790,4 +791,14 @@ Apply + + + Peek display + Enable minimal lock screen notification style + Peek display location + Peek display (bottom) top margin + + + Minimalist + Peek display style diff --git a/res/xml/evolution_settings_lock_screen.xml b/res/xml/evolution_settings_lock_screen.xml index d0da27a..c37755e 100644 --- a/res/xml/evolution_settings_lock_screen.xml +++ b/res/xml/evolution_settings_lock_screen.xml @@ -60,11 +60,11 @@ android:summary="@string/dw_wallpaper_enabled_summary" android:fragment="org.evolution.settings.fragments.lockscreen.WallpaperDepth" /> - + + + + + + + + + + + + + + + diff --git a/src/org/evolution/settings/fragments/lockscreen/PeekDisplay.java b/src/org/evolution/settings/fragments/lockscreen/PeekDisplay.java new file mode 100644 index 0000000..40d0acb --- /dev/null +++ b/src/org/evolution/settings/fragments/lockscreen/PeekDisplay.java @@ -0,0 +1,59 @@ +/* + * Copyright (C) 2023-2024 the risingOS Android 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 org.evolution.settings.fragments.lockscreen; + +import android.content.Context; +import android.os.Bundle; + +import com.android.internal.logging.nano.MetricsProto; +import com.android.settings.R; +import com.android.settings.SettingsPreferenceFragment; +import com.android.settings.search.BaseSearchIndexProvider; +import com.android.settingslib.search.SearchIndexable; + +import java.util.List; + +@SearchIndexable +public class PeekDisplay extends SettingsPreferenceFragment { + + public static final String TAG = "PeekDisplay"; + + @Override + public void onCreate(Bundle savedInstanceState) { + super.onCreate(savedInstanceState); + + addPreferencesFromResource(R.xml.evolution_settings_peek_display); + } + + @Override + public int getMetricsCategory() { + return MetricsProto.MetricsEvent.VIEW_UNKNOWN; + } + + /** + * For search + */ + public static final BaseSearchIndexProvider SEARCH_INDEX_DATA_PROVIDER = + new BaseSearchIndexProvider(R.xml.evolution_settings_peek_display) { + + @Override + public List getNonIndexableKeys(Context context) { + List keys = super.getNonIndexableKeys(context); + + return keys; + } + }; +}