Skip to content

Commit

Permalink
Fix song editor visualization after maximizing
Browse files Browse the repository at this point in the history
  • Loading branch information
PhysSong committed Nov 4, 2018
1 parent d8fb07f commit d09b0c9
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 0 deletions.
1 change: 1 addition & 0 deletions include/SongEditor.h
Original file line number Diff line number Diff line change
Expand Up @@ -155,6 +155,7 @@ class SongEditorWindow : public Editor

protected:
virtual void resizeEvent( QResizeEvent * event );
virtual void changeEvent( QEvent * );

protected slots:
void play();
Expand Down
10 changes: 10 additions & 0 deletions src/gui/editors/SongEditor.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -723,6 +723,16 @@ void SongEditorWindow::resizeEvent(QResizeEvent *event)
}


void SongEditorWindow::changeEvent(QEvent *event)
{
QWidget::changeEvent(event);
if (event->type() == QEvent::WindowStateChange)
{
m_editor->realignTracks();
}
}


void SongEditorWindow::play()
{
emit playTriggered();
Expand Down

0 comments on commit d09b0c9

Please sign in to comment.