Make floating gdb views possible. Hiding when mode is switched.

This commit is contained in:
con
2009-05-15 16:54:54 +02:00
parent d46a1447f1
commit 564f7b9eb5
4 changed files with 44 additions and 13 deletions

View File

@@ -756,7 +756,7 @@ bool DebuggerPlugin::initialize(const QStringList &arguments, QString *errorMess
readSettings();
connect(ModeManager::instance(), SIGNAL(currentModeChanged(Core::IMode*)),
this, SLOT(focusCurrentEditor(Core::IMode*)));
this, SLOT(onModeChanged(Core::IMode*)));
m_debugMode->widget()->setFocusProxy(EditorManager::instance());
addObject(m_debugMode);
@@ -1040,10 +1040,13 @@ void DebuggerPlugin::readSettings()
m_manager->mainWindow()->restoreState(ba);
}
void DebuggerPlugin::focusCurrentEditor(IMode *mode)
void DebuggerPlugin::onModeChanged(IMode *mode)
{
if (mode != m_debugMode)
if (mode != m_debugMode) {
m_manager->setFloatingDockWidgetsVisible(false);
return;
}
m_manager->setFloatingDockWidgetsVisible(true);
EditorManager *editorManager = EditorManager::instance();