From ca8f09807b4c1480cff75bbb23daffae5631aa93 Mon Sep 17 00:00:00 2001 From: nyne Date: Sun, 9 Mar 2025 16:38:39 +0800 Subject: [PATCH] Add a refresh button to network favorites page. --- assets/translation.json | 8 ++++++-- lib/pages/favorites/network_favorites_page.dart | 9 +++++++++ 2 files changed, 15 insertions(+), 2 deletions(-) diff --git a/assets/translation.json b/assets/translation.json index 32392a4..aa9f35c 100644 --- a/assets/translation.json +++ b/assets/translation.json @@ -367,7 +367,9 @@ "Home Page": "主页", "Favorites Page": "收藏页面", "Explore Page": "探索页面", - "Categories Page": "分类页面" + "Categories Page": "分类页面", + "Convert to local": "转换为本地", + "Refresh": "刷新" }, "zh_TW": { "Home": "首頁", @@ -737,6 +739,8 @@ "Home Page": "主頁", "Favorites Page": "收藏頁面", "Explore Page": "探索頁面", - "Categories Page": "分類頁面" + "Categories Page": "分類頁面", + "Convert to local": "轉換為本地", + "Refresh": "刷新" } } diff --git a/lib/pages/favorites/network_favorites_page.dart b/lib/pages/favorites/network_favorites_page.dart index 5baef91..57582e7 100644 --- a/lib/pages/favorites/network_favorites_page.dart +++ b/lib/pages/favorites/network_favorites_page.dart @@ -110,6 +110,15 @@ class _NormalFavoritePageState extends State<_NormalFavoritePage> { child: Text(widget.data.title), ), actions: [ + Tooltip( + message: "Refresh".tl, + child: IconButton( + icon: const Icon(Icons.refresh), + onPressed: () { + comicListKey.currentState!.refresh(); + }, + ), + ), MenuButton(entries: [ MenuEntry( icon: Icons.sync,