Skip to content

Commit 8d17e9c

Browse files
committed
address feedback
1 parent 124e966 commit 8d17e9c

File tree

2 files changed

+9
-47
lines changed

2 files changed

+9
-47
lines changed

i18n/en/cosmic_store.ftl

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -56,12 +56,8 @@ removing = Removing...
5656
# Uninstall Dialog
5757
uninstall-app = Uninstall {$name}?
5858
uninstall-app-warning = Uninstalling {$name} will delete its data.
59-
uninstall-app-flatpak-warning = This will remove the app from your system.
60-
app-settings-data = App settings & data
61-
keep-app-data = Keep
62-
keep-app-data-description = App data and settings will remain on your system.
63-
delete-app-data = Delete
64-
delete-app-data-description = All app data, settings, and cache will be permanently removed.
59+
uninstall-app-flatpak-warning = Uninstalling {$name} will keep its documents and data.
60+
delete-app-data = Permanently delete app data
6561
6662
# Nav Pages
6763
explore = Explore

src/main.rs

Lines changed: 7 additions & 41 deletions
Original file line numberDiff line numberDiff line change
@@ -4063,54 +4063,20 @@ impl Application for App {
40634063
let mut dialog = widget::dialog()
40644064
.title(fl!("uninstall-app", name = info.name.as_str()))
40654065
.body(if is_flatpak {
4066-
fl!("uninstall-app-flatpak-warning")
4066+
fl!("uninstall-app-flatpak-warning", name = info.name.as_str())
40674067
} else {
40684068
fl!("uninstall-app-warning", name = info.name.as_str())
40694069
})
40704070
.icon(widget::icon::from_name(Self::APP_ID).size(64));
40714071

4072-
// Only show data options for Flatpak apps
4072+
// Only show data deletion option for Flatpak apps
40734073
if is_flatpak {
40744074
dialog = dialog.control(
4075-
widget::column::with_capacity(4)
4076-
.spacing(12)
4077-
.push(widget::text::heading(fl!("app-settings-data")))
4078-
.push(
4079-
widget::column::with_capacity(2)
4080-
.spacing(4)
4081-
.push(
4082-
widget::radio(
4083-
widget::text::body(fl!("keep-app-data")),
4084-
false,
4085-
Some(self.uninstall_purge_data),
4086-
Message::ToggleUninstallPurgeData,
4087-
)
4088-
)
4089-
.push(
4090-
widget::container(
4091-
widget::text::caption(fl!("keep-app-data-description"))
4092-
)
4093-
.padding([0, 0, 0, 24])
4094-
)
4095-
)
4096-
.push(
4097-
widget::column::with_capacity(2)
4098-
.spacing(4)
4099-
.push(
4100-
widget::radio(
4101-
widget::text::body(fl!("delete-app-data")),
4102-
true,
4103-
Some(self.uninstall_purge_data),
4104-
Message::ToggleUninstallPurgeData,
4105-
)
4106-
)
4107-
.push(
4108-
widget::container(
4109-
widget::text::caption(fl!("delete-app-data-description"))
4110-
)
4111-
.padding([0, 0, 0, 24])
4112-
)
4113-
)
4075+
widget::checkbox(
4076+
fl!("delete-app-data"),
4077+
self.uninstall_purge_data,
4078+
)
4079+
.on_toggle(Message::ToggleUninstallPurgeData)
41144080
);
41154081
}
41164082

0 commit comments

Comments
 (0)