深色模式、首页设置页面和功能优化

This commit is contained in:
Developer
2026-04-02 07:06:55 +08:00
parent f0a62ed68b
commit 954d173329
88 changed files with 12157 additions and 7578 deletions

View File

@@ -1,5 +1,6 @@
import { router } from '@kit.ArkUI';
import { preferences } from '@kit.ArkData';
import { common } from '@kit.AbilityKit';
//todo 重要 后续 刷新按钮要求固定显示
@Entry
@Component
@@ -45,7 +46,7 @@ struct WidgetSettings {
async saveSettings() {
try {
if (!this.preference) {
const context = getContext(this);
const context = getContext(this) as common.UIAbilityContext;
this.preference = await preferences.getPreferences(context, 'widget_settings');
}
console.info('[WidgetSettings] Saving settings - showTime: ' + this.showTime + ', showWeather: ' + this.showWeather);