#morevna #board Switch scenes with single click.

This commit is contained in:
Konstantin Dmitriev 2020-07-26 19:51:52 +07:00 committed by manongjohn
parent a51ff84d4d
commit 0b171db8d3
3 changed files with 9 additions and 1 deletions

View file

@ -2171,6 +2171,12 @@ void SceneBrowser::enableDoubleClickToOpenScenes() {
SLOT(tryToOpenScene(const TFilePath &)));
}
void SceneBrowser::enableSingleClickToOpenScenes() {
// perhaps this should disconnect existing signal handlers first
connect(this, SIGNAL(filePathClicked(const TFilePath &)), this,
SLOT(tryToOpenScene(const TFilePath &)));
}
//-----------------------------------------------------------------------------
void SceneBrowser::tryToOpenScene(const TFilePath &filePath) {

View file

@ -101,6 +101,8 @@ types to be displayed in the file browser.
// So it is disabled by default.
void enableDoubleClickToOpenScenes();
void enableSingleClickToOpenScenes();
protected:
int findIndexWithPath(TFilePath path);
void getExpandedFolders(DvDirModelNode *node,

View file

@ -1249,7 +1249,7 @@ public:
TFilePath scenesFolder =
TProjectManager::instance()->getCurrentProject()->getScenesPath();
browser->setFolder(scenesFolder, true);
browser->enableDoubleClickToOpenScenes();
browser->enableSingleClickToOpenScenes();
}
} PreproductionBoardFactory;