mirror of
https://github.com/LMMS/lmms.git
synced 2026-04-01 21:04:18 -04:00
Fix invisible editors on project load by validating size (#4502)
This commit is contained in:
@@ -802,7 +802,10 @@ void MainWindow::restoreWidgetState( QWidget * _w, const QDomElement & _de )
|
||||
// first restore the window, as attempting to resize a maximized window causes graphics glitching
|
||||
_w->setWindowState( _w->windowState() & ~(Qt::WindowMaximized | Qt::WindowMinimized) );
|
||||
|
||||
_w->resize( r.size() );
|
||||
// Check isEmpty() to work around corrupt project files with empty size
|
||||
if ( ! r.size().isEmpty() ) {
|
||||
_w->resize( r.size() );
|
||||
}
|
||||
_w->move( r.topLeft() );
|
||||
|
||||
// set the window to its correct minimized/maximized/restored state
|
||||
|
||||
Reference in New Issue
Block a user