opt.: sftp dl

This commit is contained in:
lollipopkit🏳️‍⚧️
2025-07-21 16:20:27 +08:00
parent 263d4eabb4
commit ec4bf3df24
8 changed files with 73 additions and 64 deletions

View File

@@ -73,11 +73,24 @@ class _LocalFilePageState extends State<LocalFilePage> with AutomaticKeepAliveCl
},
icon: const Icon(Icons.add),
),
if (!isMobile)
IconButton(
icon: const Icon(Icons.refresh),
tooltip: MaterialLocalizations.of(context).refreshIndicatorSemanticLabel,
onPressed: () => setState(() {}),
),
if (!isPickFile) _buildMissionBtn(),
_buildSortBtn(),
],
),
body: _sortType.listen(_buildBody),
body: isMobile
? RefreshIndicator(
onRefresh: () async {
setState(() {});
},
child: _sortType.listen(_buildBody),
)
: _sortType.listen(_buildBody),
);
}

View File

@@ -537,7 +537,7 @@ extension _Actions on _SftpPageState {
/// Local file dir + server id + remote path
String _getLocalPath(String remotePath) {
return Paths.file.joinPath(widget.args.spi.id).joinPath(remotePath);
return Paths.file.joinPath(widget.args.spi.oldId).joinPath(remotePath);
}
/// Only return true if the path is changed