summaryrefslogtreecommitdiff
path: root/src/mainwindow.cpp
diff options
context:
space:
mode:
authorLostDragonist <lost.dragonist@gmail.com>2019-02-07 21:39:59 -0600
committerLostDragonist <lost.dragonist@gmail.com>2019-02-07 21:42:14 -0600
commit98683eca6f4b2668de875c14986657764e1123c7 (patch)
treee18947494d0040fe4dabcd8a75fb4b006a5ba6e4 /src/mainwindow.cpp
parent10336caf9edca2204a64955903f865de6e2b6cb2 (diff)
Enable compact mode for mod list flags when column is smaller than 6 icons
Diffstat (limited to 'src/mainwindow.cpp')
-rw-r--r--src/mainwindow.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/mainwindow.cpp b/src/mainwindow.cpp
index e4fe8769..fe39e023 100644
--- a/src/mainwindow.cpp
+++ b/src/mainwindow.cpp
@@ -283,7 +283,9 @@ MainWindow::MainWindow(QSettings &initSettings
GenericIconDelegate *contentDelegate = new GenericIconDelegate(ui->modList, Qt::UserRole + 3, ModList::COL_CONTENT, 150);
connect(ui->modList->header(), SIGNAL(sectionResized(int,int,int)), contentDelegate, SLOT(columnResized(int,int,int)));
ui->modList->sortByColumn(ModList::COL_PRIORITY, Qt::AscendingOrder);
- ui->modList->setItemDelegateForColumn(ModList::COL_FLAGS, new ModFlagIconDelegate(ui->modList));
+ ModFlagIconDelegate *flagDelegate = new ModFlagIconDelegate(ui->modList, ModList::COL_FLAGS, 120);
+ connect(ui->modList->header(), SIGNAL(sectionResized(int,int,int)), flagDelegate, SLOT(columnResized(int,int,int)));
+ ui->modList->setItemDelegateForColumn(ModList::COL_FLAGS, flagDelegate);
ui->modList->setItemDelegateForColumn(ModList::COL_CONTENT, contentDelegate);
ui->modList->header()->installEventFilter(m_OrganizerCore.modList());
connect(ui->modList->header(), SIGNAL(sectionResized(int, int, int)), this, SLOT(modListSectionResized(int, int, int)));