mirror of
				https://github.com/yuzu-emu/yuzu.git
				synced 2025-11-04 08:53:43 +00:00 
			
		
		
		
	citra-qt/command list: Enable uniform row heights and automatically resize columns.
Uniform row heights enables some optimisations for a smoother scrolling. Resize columns to content so that we don't have to do it manually
This commit is contained in:
		
							parent
							
								
									129e3dedc3
								
							
						
					
					
						commit
						e286cfbadf
					
				@ -10,6 +10,7 @@
 | 
			
		||||
#include <QPushButton>
 | 
			
		||||
#include <QVBoxLayout>
 | 
			
		||||
#include <QTreeView>
 | 
			
		||||
#include <QHeaderView>
 | 
			
		||||
#include <QSpinBox>
 | 
			
		||||
#include <QComboBox>
 | 
			
		||||
 | 
			
		||||
@ -301,6 +302,13 @@ GPUCommandListWidget::GPUCommandListWidget(QWidget* parent) : QDockWidget(tr("Pi
 | 
			
		||||
    list_widget->setModel(model);
 | 
			
		||||
    list_widget->setFont(QFont("monospace"));
 | 
			
		||||
    list_widget->setRootIsDecorated(false);
 | 
			
		||||
    list_widget->setUniformRowHeights(true);
 | 
			
		||||
 | 
			
		||||
#if QT_VERSION >= QT_VERSION_CHECK(5,0,0)
 | 
			
		||||
    list_widget->header()->setSectionResizeMode(QHeaderView::ResizeToContents);
 | 
			
		||||
#else
 | 
			
		||||
    list_widget->header()->setResizeMode(QHeaderView::ResizeToContents);
 | 
			
		||||
#endif
 | 
			
		||||
 | 
			
		||||
    connect(list_widget->selectionModel(), SIGNAL(currentChanged(const QModelIndex&,const QModelIndex&)),
 | 
			
		||||
            this, SLOT(SetCommandInfo(const QModelIndex&)));
 | 
			
		||||
 | 
			
		||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user