@@ -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