KMessageBox::information(worksheetView(), i18n("In read-only mode Cantor couldn't guarantee, that the export will be valid for %1", m_backendName), i18n("Cantor"));
KMessageBox::information(worksheetView(), i18n("%1 backend was not found. Editing and executing entries is not possible.", m_backendName), i18n("Open File"));
m_readOnly = true;
}
else
m_readOnly = false;
if(!m_readOnly && !b->isEnabled())
{
QApplication::restoreOverrideCursor();
KMessageBox::information(worksheetView(), i18n("There are some problems with the %1 backend,\n"\
"please check your configuration or install the needed packages.\n"
"You will only be able to view this worksheet.", m_backendName), i18n("Open File"));
m_readOnly = true;
}
if (m_readOnly)
{
// TODO: Handle this here?
for (QAction* action : m_richTextActionList)
action->setEnabled(false);
}
m_isLoadingFromFile = true;
//cleanup the worksheet and all it contains
delete m_session;
m_session=nullptr;
//file can only be loaded in a worksheet that was not edited/modified yet (s.a. CantorShell::load())
//in this case on the default "first entry" is available -> delete it.