Commit 763a4fcf authored by shibakaneki's avatar shibakaneki

Fixed the issue SANKORE-19: a crash occured while opening a page containing an application

parent fdd20200
...@@ -1132,11 +1132,11 @@ void UBBoardController::setActiveDocumentScene(UBDocumentProxy* pDocumentProxy, ...@@ -1132,11 +1132,11 @@ void UBBoardController::setActiveDocumentScene(UBDocumentProxy* pDocumentProxy,
UBGraphicsTextItem::lastUsedTextColor = QColor(); UBGraphicsTextItem::lastUsedTextColor = QColor();
} }
if (sceneChange)
emit activeSceneChanged();
// Notify the navigator palette that the document has changed // Notify the navigator palette that the document has changed
mPaletteManager->navigatorPalette()->setDocument(pDocumentProxy); mPaletteManager->navigatorPalette()->setDocument(pDocumentProxy);
if (sceneChange)
emit activeSceneChanged();
} }
......
...@@ -58,7 +58,8 @@ void UBGraphicsTextItemDelegate::contentsChanged() ...@@ -58,7 +58,8 @@ void UBGraphicsTextItemDelegate::contentsChanged()
delegated()->contentsChanged(); delegated()->contentsChanged();
} }
// This method is used to filter the available fonts. Only the web-compliant fonts
// will remain in the font list.
void UBGraphicsTextItemDelegate::customize(QFontDialog &fontDialog) void UBGraphicsTextItemDelegate::customize(QFontDialog &fontDialog)
{ {
fontDialog.setOption(QFontDialog::DontUseNativeDialog); fontDialog.setOption(QFontDialog::DontUseNativeDialog);
......
...@@ -7,20 +7,25 @@ ...@@ -7,20 +7,25 @@
UniboardSankoreTransition::UniboardSankoreTransition(QObject *parent) : UniboardSankoreTransition::UniboardSankoreTransition(QObject *parent) :
QObject(parent) QObject(parent)
, mTransitionDlg(NULL)
{ {
mOldSankoreDirectory = UBFileSystemUtils::normalizeFilePath(UBDesktopServices::storageLocation(QDesktopServices::DataLocation)); // mOldSankoreDirectory = UBFileSystemUtils::normalizeFilePath(UBDesktopServices::storageLocation(QDesktopServices::DataLocation));
mUniboardSourceDirectory = UBFileSystemUtils::normalizeFilePath(UBDesktopServices::storageLocation(QDesktopServices::DataLocation)); // mUniboardSourceDirectory = UBFileSystemUtils::normalizeFilePath(UBDesktopServices::storageLocation(QDesktopServices::DataLocation));
#if defined(Q_WS_MACX) //#if defined(Q_WS_MACX)
mUniboardSourceDirectory.replace("Sankore/Sankore 3.1", "Uniboard"); // mUniboardSourceDirectory.replace("Sankore/Sankore 3.1", "Uniboard");
#else //#else
mUniboardSourceDirectory.replace("Sankore/Sankore 3.1", "Mnemis/Uniboard"); // mUniboardSourceDirectory.replace("Sankore/Sankore 3.1", "Mnemis/Uniboard");
#endif //#endif
connect(this, SIGNAL(docAdded(UBDocumentProxy*)), UBPersistenceManager::persistenceManager(), SIGNAL(documentCreated(UBDocumentProxy*))); // connect(this, SIGNAL(docAdded(UBDocumentProxy*)), UBPersistenceManager::persistenceManager(), SIGNAL(documentCreated(UBDocumentProxy*)));
} }
UniboardSankoreTransition::~UniboardSankoreTransition() UniboardSankoreTransition::~UniboardSankoreTransition()
{ {
if(NULL != mTransitionDlg)
{
delete mTransitionDlg; delete mTransitionDlg;
mTransitionDlg = NULL;
}
} }
void UniboardSankoreTransition::rollbackDocumentsTransition(QFileInfoList& fileInfoList) void UniboardSankoreTransition::rollbackDocumentsTransition(QFileInfoList& fileInfoList)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment