mirror of
				https://github.com/davatorium/rofi.git
				synced 2025-10-30 23:47:19 -04:00 
			
		
		
		
	[Theme] Allow default enabled state of widget to be set in theme
This commit is contained in:
		
							parent
							
								
									8c11b48532
								
							
						
					
					
						commit
						4157b5d825
					
				
					 5 changed files with 5 additions and 5 deletions
				
			
		| 
						 | 
				
			
			@ -325,7 +325,7 @@ box * box_create ( const char *name, boxType type )
 | 
			
		|||
    b->widget.clicked            = box_clicked;
 | 
			
		||||
    b->widget.motion_notify      = box_motion_notify;
 | 
			
		||||
    b->widget.get_desired_height = box_get_desired_height;
 | 
			
		||||
    b->widget.enabled            = TRUE;
 | 
			
		||||
    b->widget.enabled = rofi_theme_get_boolean ( WIDGET ( b ), "enabled", TRUE );
 | 
			
		||||
 | 
			
		||||
    b->spacing = rofi_theme_get_distance ( WIDGET ( b ), "spacing", DEFAULT_SPACING );
 | 
			
		||||
    return b;
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -123,7 +123,7 @@ container * container_create ( const char *name )
 | 
			
		|||
    b->widget.clicked            = container_clicked;
 | 
			
		||||
    b->widget.motion_notify      = container_motion_notify;
 | 
			
		||||
    b->widget.get_desired_height = container_get_desired_height;
 | 
			
		||||
    b->widget.enabled            = TRUE;
 | 
			
		||||
    b->widget.enabled = rofi_theme_get_boolean ( WIDGET ( b ), "enabled", TRUE );
 | 
			
		||||
    return b;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -370,7 +370,7 @@ listview *listview_create ( const char *name, listview_update_callback cb, void
 | 
			
		|||
    lv->widget.clicked            = listview_clicked;
 | 
			
		||||
    lv->widget.motion_notify      = listview_motion_notify;
 | 
			
		||||
    lv->widget.get_desired_height = listview_get_desired_height;
 | 
			
		||||
    lv->widget.enabled            = TRUE;
 | 
			
		||||
    lv->widget.enabled = rofi_theme_get_boolean ( WIDGET ( lv ), "enabled", TRUE );
 | 
			
		||||
    lv->eh                        = eh;
 | 
			
		||||
 | 
			
		||||
    char *n = g_strjoin ( ".", lv->listview_name, "scrollbar", NULL );
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -66,7 +66,7 @@ scrollbar *scrollbar_create ( const char *name )
 | 
			
		|||
    sb->pos_length = 4;
 | 
			
		||||
 | 
			
		||||
    // Enabled by default
 | 
			
		||||
    sb->widget.enabled = TRUE;
 | 
			
		||||
    sb->widget.enabled = rofi_theme_get_boolean ( WIDGET ( sb ), "enabled", TRUE );
 | 
			
		||||
    return sb;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -165,7 +165,7 @@ textbox* textbox_create ( const char *name, TextboxFlags flags, TextBoxFontType
 | 
			
		|||
    }
 | 
			
		||||
 | 
			
		||||
    // Enabled by default
 | 
			
		||||
    tb->widget.enabled = TRUE;
 | 
			
		||||
    tb->widget.enabled = rofi_theme_get_boolean ( WIDGET ( tb ), "enabled", TRUE );
 | 
			
		||||
    return tb;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue