Skip to content

Commit

Permalink
fix(installer): open the patched app after install
Browse files Browse the repository at this point in the history
Fix #1170 (bug: No way to open the patched app right after installation)
  • Loading branch information
validcube committed Sep 3, 2023
1 parent e45a782 commit e8710f0
Showing 1 changed file with 15 additions and 3 deletions.
18 changes: 15 additions & 3 deletions lib/ui/views/installer/installer_view.dart
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,21 @@ class InstallerView extends StatelessWidget {
floatingActionButton: Visibility(
visible: !model.isPatching,
child: FloatingActionButton.extended(
label: I18nText('installerView.installButton'),
icon: const Icon(Icons.file_download_outlined),
onPressed: () => model.installTypeDialog(context),
label: I18nText(
model.isInstalled
? 'installerView.openButton'
: 'installerView.installButton',
),
icon: model.isInstalled
? const Icon(Icons.open_in_new)
: const Icon(Icons.file_download_outlined),
onPressed: model.isInstalled
? () => (
model.openApp(),
model.cleanPatcher(),
Navigator.of(context).pop()
)
: () => model.installTypeDialog(context),
elevation: 0,
),
),
Expand Down

0 comments on commit e8710f0

Please sign in to comment.