| 869 | |
| 870 | |
| 871 | void MainWindow::openProject() |
| 872 | { |
| 873 | if( mayChangeProject(false) ) |
| 874 | { |
| 875 | FileDialog ofd( this, tr( "Open Project" ), "", tr( "LMMS (*.mmp *.mmpz)" ) ); |
| 876 | |
| 877 | ofd.setDirectory( ConfigManager::inst()->userProjectsDir() ); |
| 878 | ofd.setFileMode( FileDialog::ExistingFiles ); |
| 879 | if( ofd.exec () == QDialog::Accepted && |
| 880 | !ofd.selectedFiles().isEmpty() ) |
| 881 | { |
| 882 | Song *song = Engine::getSong(); |
| 883 | |
| 884 | song->stop(); |
| 885 | setCursor( Qt::WaitCursor ); |
| 886 | song->loadProject( ofd.selectedFiles()[0] ); |
| 887 | setCursor( Qt::ArrowCursor ); |
| 888 | } |
| 889 | } |
| 890 | } |
| 891 | |
| 892 | |
| 893 |
nothing calls this directly
no test coverage detected