@ -1854,6 +1854,8 @@ void UBDocumentController::selectDocument(UBDocumentProxy* proxy, bool setAsCurr
if ( setAsCurrentDocument ) {
if ( setAsCurrentDocument ) {
UBPersistenceManager : : persistenceManager ( ) - > mDocumentTreeStructureModel - > setCurrentDocument ( proxy ) ;
UBPersistenceManager : : persistenceManager ( ) - > mDocumentTreeStructureModel - > setCurrentDocument ( proxy ) ;
QModelIndex indexCurrentDoc = UBPersistenceManager : : persistenceManager ( ) - > mDocumentTreeStructureModel - > indexForProxy ( proxy ) ;
QModelIndex indexCurrentDoc = UBPersistenceManager : : persistenceManager ( ) - > mDocumentTreeStructureModel - > indexForProxy ( proxy ) ;
if ( indexCurrentDoc . isValid ( ) )
{
mDocumentUI - > documentTreeView - > setSelectedAndExpanded ( indexCurrentDoc , true , editMode ) ;
mDocumentUI - > documentTreeView - > setSelectedAndExpanded ( indexCurrentDoc , true , editMode ) ;
if ( proxy ! = mBoardController - > selectedDocument ( ) ) // only if wanted Document is different from document actually on Board, // ALTI/AOU - 20140217
if ( proxy ! = mBoardController - > selectedDocument ( ) ) // only if wanted Document is different from document actually on Board, // ALTI/AOU - 20140217
@ -1862,6 +1864,7 @@ void UBDocumentController::selectDocument(UBDocumentProxy* proxy, bool setAsCurr
mBoardController - > setActiveDocumentScene ( proxy , 0 , true , onImport ) ;
mBoardController - > setActiveDocumentScene ( proxy , 0 , true , onImport ) ;
}
}
}
}
}
mSelectionType = Document ;
mSelectionType = Document ;
setDocument ( proxy ) ;
setDocument ( proxy ) ;