forked from qt-creator/qt-creator
Fixes: Session loading does not restore form files
RevBy: Eike Details: Make form editor factory and form editor return the same editor kind.
This commit is contained in:
@@ -42,7 +42,6 @@ const char * const C_FORMEDITOR = "Formeditor";
|
||||
const char * const T_FORMEDITOR = "Formeditor.Toolbar";
|
||||
const char * const M_FORMEDITOR = "Formeditor.Menu";
|
||||
const char * const M_FORMEDITOR_PREVIEW = "Formeditor.Menu.Preview";
|
||||
const char * const C_FORMWINDOW = "Formwindow";
|
||||
|
||||
// Wizard type
|
||||
const char * const FORM_FILE_TYPE = "Qt4FormFiles";
|
||||
|
||||
@@ -546,7 +546,7 @@ void FormEditorW::currentEditorChanged(Core::IEditor *editor)
|
||||
qDebug() << Q_FUNC_INFO << editor << " of " << m_fwm->formWindowCount();
|
||||
|
||||
// Deactivate Designer if a non-form is being edited
|
||||
if (editor && !qstrcmp(editor->kind(), Constants::C_FORMWINDOW)) {
|
||||
if (editor && !qstrcmp(editor->kind(), Constants::C_FORMEDITOR)) {
|
||||
FormWindowEditor *fw = qobject_cast<FormWindowEditor *>(editor);
|
||||
QTC_ASSERT(fw, return);
|
||||
fw->activate();
|
||||
|
||||
@@ -260,7 +260,7 @@ Core::IFile *FormWindowEditor::file()
|
||||
|
||||
const char *FormWindowEditor::kind() const
|
||||
{
|
||||
return C_FORMWINDOW;
|
||||
return C_FORMEDITOR;
|
||||
}
|
||||
|
||||
QString FormWindowEditor::displayName() const
|
||||
|
||||
Reference in New Issue
Block a user