mirror of
https://github.com/githubuser0xFFFF/Qt-Advanced-Docking-System.git
synced 2024-12-24 23:31:32 +08:00
Fixed CDockWidget::setWidget function to test for QAbstractScrollArea instead of QScrollArea
Now setWidget properly supports ItemViews like QTreeView or QTableView
This commit is contained in:
parent
47029190dc
commit
cbd2fcb0d3
@ -263,7 +263,7 @@ void CDockWidget::setWidget(QWidget* widget, eInsertMode InsertMode)
|
||||
takeWidget();
|
||||
}
|
||||
|
||||
QScrollArea* ScrollAreaWidget = qobject_cast<QScrollArea*>(widget);
|
||||
auto ScrollAreaWidget = qobject_cast<QAbstractScrollArea*>(widget);
|
||||
if (ScrollAreaWidget || ForceNoScrollArea == InsertMode)
|
||||
{
|
||||
d->Layout->addWidget(widget);
|
||||
|
Loading…
Reference in New Issue
Block a user