mirror of
				https://github.com/RGBCube/serenity
				synced 2025-10-31 09:42:45 +00:00 
			
		
		
		
	LibGUI+Userland: Stop returning Layout from Widget::(try_)set_layout()
				
					
				
			Nobody uses this return value any more. It also lets us remove a whole bunch of `(void)` casts. :^)
This commit is contained in:
		
							parent
							
								
									77ad0fdb07
								
							
						
					
					
						commit
						6b66e39df4
					
				
					 20 changed files with 47 additions and 48 deletions
				
			
		|  | @ -23,7 +23,7 @@ ErrorOr<int> serenity_main(Main::Arguments arguments) | |||
|     auto main_widget = TRY(window->set_main_widget<GUI::Widget>()); | ||||
|     main_widget->set_fill_with_background_color(true); | ||||
| 
 | ||||
|     (void)TRY(main_widget->try_set_layout<GUI::VerticalBoxLayout>(16)); | ||||
|     TRY(main_widget->try_set_layout<GUI::VerticalBoxLayout>(16)); | ||||
| 
 | ||||
|     auto button = TRY(main_widget->try_add<GUI::Button>("Click me!")); | ||||
|     button->on_click = [&](auto) { | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 Sam Atkins
						Sam Atkins