mirror of
https://github.com/githubuser0xFFFF/Qt-Advanced-Docking-System.git
synced 2025-03-16 02:59:51 +08:00
Changed root index of file system model to prevent lagging UI if network folders are missing
This commit is contained in:
parent
ae5a75bc3f
commit
1eaeed6c56
@ -216,6 +216,7 @@ struct MainWindowPrivate
|
|||||||
QFileSystemModel* m = new QFileSystemModel(w);
|
QFileSystemModel* m = new QFileSystemModel(w);
|
||||||
m->setRootPath(QDir::currentPath());
|
m->setRootPath(QDir::currentPath());
|
||||||
w->setModel(m);
|
w->setModel(m);
|
||||||
|
w->setRootIndex(m->index(QDir::currentPath()));
|
||||||
ads::CDockWidget* DockWidget = new ads::CDockWidget(QString("Filesystem %1")
|
ads::CDockWidget* DockWidget = new ads::CDockWidget(QString("Filesystem %1")
|
||||||
.arg(FileSystemCount++));
|
.arg(FileSystemCount++));
|
||||||
DockWidget->setWidget(w);
|
DockWidget->setWidget(w);
|
||||||
|
Loading…
Reference in New Issue
Block a user