|  |  | @ -1,7 +1,8 @@ | 
			
		
	
		
		
			
				
					
					|  |  |  | #!/usr/bin/env python3 |  |  |  | #!/usr/bin/env python3 | 
			
		
	
		
		
			
				
					
					|  |  |  | import re |  |  |  | import re | 
			
		
	
		
		
			
				
					
					|  |  |  |  |  |  |  | import sys | 
			
		
	
		
		
			
				
					
					|  |  |  | import pyray as rl |  |  |  | import pyray as rl | 
			
		
	
		
		
			
				
					
					|  |  |  | from openpilot.system.hardware import HARDWARE |  |  |  | from openpilot.system.hardware import HARDWARE, PC | 
			
				
				
			
		
	
		
		
	
		
		
			
				
					
					|  |  |  | from openpilot.system.ui.lib.button import gui_button, ButtonStyle |  |  |  | from openpilot.system.ui.lib.button import gui_button, ButtonStyle | 
			
		
	
		
		
			
				
					
					|  |  |  | from openpilot.system.ui.lib.scroll_panel import GuiScrollPanel |  |  |  | from openpilot.system.ui.lib.scroll_panel import GuiScrollPanel | 
			
		
	
		
		
			
				
					
					|  |  |  | from openpilot.system.ui.lib.application import gui_app |  |  |  | from openpilot.system.ui.lib.application import gui_app | 
			
		
	
	
		
		
			
				
					|  |  | @ -58,8 +59,11 @@ class TextWindow: | 
			
		
	
		
		
			
				
					
					|  |  |  |     rl.end_scissor_mode() |  |  |  |     rl.end_scissor_mode() | 
			
		
	
		
		
			
				
					
					|  |  |  | 
 |  |  |  | 
 | 
			
		
	
		
		
			
				
					
					|  |  |  |     button_bounds = rl.Rectangle(gui_app.width - MARGIN - BUTTON_SIZE.x, gui_app.height - MARGIN - BUTTON_SIZE.y, BUTTON_SIZE.x, BUTTON_SIZE.y) |  |  |  |     button_bounds = rl.Rectangle(gui_app.width - MARGIN - BUTTON_SIZE.x, gui_app.height - MARGIN - BUTTON_SIZE.y, BUTTON_SIZE.x, BUTTON_SIZE.y) | 
			
		
	
		
		
			
				
					
					|  |  |  |     ret = gui_button(button_bounds, "Reboot", button_style=ButtonStyle.TRANSPARENT) |  |  |  |     ret = gui_button(button_bounds, "Exit" if PC else "Reboot", button_style=ButtonStyle.TRANSPARENT) | 
			
				
				
			
		
	
		
		
	
		
		
			
				
					
					|  |  |  |     if ret: |  |  |  |     if ret: | 
			
		
	
		
		
			
				
					
					|  |  |  |  |  |  |  |       if PC: | 
			
		
	
		
		
			
				
					
					|  |  |  |  |  |  |  |         gui_app.close() | 
			
		
	
		
		
			
				
					
					|  |  |  |  |  |  |  |       else: | 
			
		
	
		
		
			
				
					
					|  |  |  |         HARDWARE.reboot() |  |  |  |         HARDWARE.reboot() | 
			
		
	
		
		
			
				
					
					|  |  |  |     return ret |  |  |  |     return ret | 
			
		
	
		
		
			
				
					
					|  |  |  | 
 |  |  |  | 
 | 
			
		
	
	
		
		
			
				
					|  |  | 
 |