2323 AlertDialog ,
2424 alignment ,
2525 Checkbox ,
26+ Switch ,
2627 Column ,
2728 Container ,
2829 Divider ,
@@ -251,10 +252,10 @@ def build(self):
251252 ],
252253 actions_alignment = "end" ,
253254 )
254- # checkbox to allow skipping unlocking the bootloader
255+ # toggleswitch to allow skipping unlocking the bootloader
255256 def check_bootloader_unlocked (e ):
256257 """Enable skipping unlocking the bootloader if selected."""
257- if self .bootloader_checkbox .value :
258+ if self .bootloader_switch .value :
258259 logger .info ("Skipping bootloader unlocking." )
259260 self .state .steps = (
260261 self .state .config .flash_recovery + self .state .config .install_os
@@ -269,25 +270,25 @@ def check_bootloader_unlocked(e):
269270 )
270271 self .state .num_total_steps = len (self .state .steps )
271272
272- self .bootloader_checkbox = Checkbox (
273+ self .bootloader_switch = Switch (
273274 label = "Bootloader is already unlocked." ,
274275 on_change = check_bootloader_unlocked ,
275276 disabled = True ,
276277 )
277278
278- # checkbox to enable advanced output - here it means show terminal input/output in tool
279- def check_advanced_box (e ):
279+ # switch to enable advanced output - here it means show terminal input/output in tool
280+ def check_advanced_switch (e ):
280281 """Check the box to enable advanced output."""
281- if self .advanced_checkbox .value :
282+ if self .advanced_switch .value :
282283 logger .info ("Enable advanced output." )
283284 self .state .advanced = True
284285 else :
285286 logger .info ("Disable advanced output." )
286287 self .state .advanced = False
287288
288- self .advanced_checkbox = Checkbox (
289+ self .advanced_switch = Switch (
289290 label = "Advanced output" ,
290- on_change = check_advanced_box ,
291+ on_change = check_advanced_switch ,
291292 disabled = False ,
292293 )
293294
@@ -347,7 +348,7 @@ def check_advanced_box(e):
347348 Column (
348349 [
349350 self .device_detection_infobox ,
350- Row ([self .bootloader_checkbox , self .advanced_checkbox ]),
351+ Row ([self .bootloader_switch , self .advanced_switch ]),
351352 ]
352353 ),
353354 Row (
@@ -421,7 +422,7 @@ def search_devices(self, e):
421422 # display success in the application
422423 if device_name :
423424 self .continue_button .disabled = False
424- self .bootloader_checkbox .disabled = False
425+ self .bootloader_switch .disabled = False
425426 # overwrite the text field with the real name from the config
426427 self .device_name .value = f"{ device_name } (code: { device_code } )"
427428 self .device_name .color = colors .GREEN
0 commit comments