mirror of
https://github.com/Such-Software/hash-wallet.git
synced 2026-10-18 05:51:34 +02:00
Mweb fixes (#1972)
* quick fix [still investigating] * cleaner quick fix * cleaner quick fix * log fix * save to downloads would require an additional permission * change address handling updates [skip ci] * should change address not updating * change address handling updates * remove unnecessary code + don't reset change address index to 0
This commit is contained in:
@@ -77,15 +77,12 @@ class MwebLogsPage extends BasePage {
|
||||
return AlertWithTwoActions(
|
||||
alertTitle: S.of(context).export_backup,
|
||||
alertContent: S.of(context).select_destination,
|
||||
rightButtonText: S.of(context).save_to_downloads,
|
||||
leftButtonText: S.of(context).share,
|
||||
actionRightButton: () async {
|
||||
const downloadDirPath = "/storage/emulated/0/Download";
|
||||
final filePath = downloadDirPath + "/debug.log";
|
||||
await mwebSettingsViewModelBase.saveLogsLocally(filePath);
|
||||
rightButtonText: S.of(context).save,
|
||||
leftButtonText: S.of(context).cancel,
|
||||
actionLeftButton: () async {
|
||||
Navigator.of(dialogContext).pop();
|
||||
},
|
||||
actionLeftButton: () async {
|
||||
actionRightButton: () async {
|
||||
Navigator.of(dialogContext).pop();
|
||||
try {
|
||||
await share(context);
|
||||
@@ -101,11 +98,8 @@ class MwebLogsPage extends BasePage {
|
||||
}
|
||||
|
||||
Future<void> share(BuildContext context) async {
|
||||
final filePath = (await getAppDir()).path + "/debug.log";
|
||||
bool success = await mwebSettingsViewModelBase.saveLogsLocally(filePath);
|
||||
if (!success) return;
|
||||
await ShareUtil.shareFile(filePath: filePath, fileName: "debug.log", context: context);
|
||||
await mwebSettingsViewModelBase.removeLogsLocally(filePath);
|
||||
final inAppPath = "${(await getApplicationSupportDirectory()).path}/logs/debug.log";
|
||||
await ShareUtil.shareFile(filePath: inAppPath, fileName: "debug.log", context: context);
|
||||
}
|
||||
|
||||
Future<void> _saveFile() async {
|
||||
|
||||
Reference in New Issue
Block a user