summaryrefslogtreecommitdiffstats
path: root/bootloader/x1000/gui.c
diff options
context:
space:
mode:
Diffstat (limited to 'bootloader/x1000/gui.c')
-rw-r--r--bootloader/x1000/gui.c15
1 files changed, 11 insertions, 4 deletions
diff --git a/bootloader/x1000/gui.c b/bootloader/x1000/gui.c
index 513a3cb9cb..1208d3c161 100644
--- a/bootloader/x1000/gui.c
+++ b/bootloader/x1000/gui.c
@@ -122,10 +122,17 @@ void splashf(long delay, const char* msg, ...)
int get_button(int timeout)
{
int btn = button_get_w_tmo(timeout);
- if(btn == SYS_USB_CONNECTED)
- is_usb_connected = true;
- else if(btn == SYS_USB_DISCONNECTED)
- is_usb_connected = false;
+ switch(btn) {
+ case SYS_USB_CONNECTED:
+ case SYS_USB_DISCONNECTED:
+ is_usb_connected = (btn == SYS_USB_CONNECTED);
+ break;
+#ifdef HAVE_SCREENDUMP
+ case BL_SCREENSHOT:
+ screenshot();
+ break;
+#endif
+ }
return btn;
}