forked from qt-creator/qt-creator
UnconfiguredPanel: Ensure that "Return" on initial show accepts
Task-number: QTCREATORBUG-12827 Change-Id: Ie68228433b8c76f48361ed642f932ded0d7f2b72 Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
This commit is contained in:
@@ -72,10 +72,12 @@ public:
|
||||
m_createWidgetFunction = [icon, this](Project *project) -> QWidget * {
|
||||
PropertiesPanel *panel = new PropertiesPanel;
|
||||
panel->setDisplayName(this->displayName());
|
||||
panel->setWidget(new T(project)),
|
||||
QWidget *widget = new T(project);
|
||||
panel->setWidget(widget);
|
||||
panel->setIcon(icon);
|
||||
PanelsWidget *panelsWidget = new PanelsWidget();
|
||||
panelsWidget->addPropertiesPanel(panel);
|
||||
panelsWidget->setFocusProxy(widget);
|
||||
return panelsWidget;
|
||||
};
|
||||
}
|
||||
|
||||
@@ -235,7 +235,8 @@ void ProjectWindow::showProperties(int index, int subIndex)
|
||||
m_currentWidget = widget;
|
||||
m_centralWidget->addWidget(m_currentWidget);
|
||||
m_centralWidget->setCurrentWidget(m_currentWidget);
|
||||
|
||||
if (hasFocus()) // we get assigned focus from setFocusToCurrentMode, pass that on
|
||||
m_currentWidget->setFocus();
|
||||
}
|
||||
|
||||
SessionManager::setStartupProject(project);
|
||||
|
||||
Reference in New Issue
Block a user