QTfrontend/ui/page/pagevideos.cpp
changeset 15255 8dd3602a4500
parent 14947 05cde9ba4183
--- a/QTfrontend/ui/page/pagevideos.cpp	Thu Jul 18 00:45:39 2019 +0200
+++ b/QTfrontend/ui/page/pagevideos.cpp	Thu Jul 18 01:46:40 2019 +0200
@@ -128,12 +128,14 @@
         filesTable->verticalHeader()->hide();
         filesTable->setMinimumWidth(400);
 
-        QHeaderView * header = filesTable->horizontalHeader();
+        QHeaderView * header = new QHeaderView(Qt::Horizontal, filesTable);
+        filesTable->setHorizontalHeader(header);
+        header = filesTable->horizontalHeader();
+        header->setStretchLastSection(true);
+        header->setSectionsClickable(false);
         header->setSectionResizeMode(vcName, QHeaderView::ResizeToContents);
         header->setSectionResizeMode(vcSize, QHeaderView::Fixed);
         header->resizeSection(vcSize, 100);
-        header->setStretchLastSection(true);
-        header->setSectionsClickable(false);
 
         btnOpenDir = new QPushButton(QPushButton::tr("Open videos directory"), pTableGroup);
         btnOpenDir->setWhatsThis(QPushButton::tr("Open the video directory in your system"));