66
66
#include <language/interfaces/editorcontext.h>
67
67
#include <interfaces/idebugcontroller.h>
68
68
#include <interfaces/iplugincontroller.h>
69
#include <execute/executepluginconstants.h>
69
#include <execute/iexecuteplugin.h>
70
70
#include <interfaces/launchconfigurationtype.h>
72
72
#include "variablewidget.h"
177
KDevelop::LaunchConfigurationType* type = core()->runController()->launchConfigurationTypeForId( ExecutePlugin::nativeAppConfigTypeId );
178
IExecutePlugin* iface = KDevelop::ICore::self()->pluginController()->pluginForExtension("org.kdevelop.IExecutePlugin")->extension<IExecutePlugin>();
180
KDevelop::LaunchConfigurationType* type = core()->runController()->launchConfigurationTypeForId( iface->nativeAppConfigTypeId() );
179
182
type->addLauncher( new GdbLauncher( this ) );
345
348
DebugSession* CppDebuggerPlugin::createSession()
350
m_session = new DebugSession(m_controller);
351
KDevelop::ICore::self()->debugController()->addSession(m_session);
352
connect(m_session, SIGNAL(showMessage(QString,int)), SLOT(controllerMessage(QString,int)));
353
connect(m_session, SIGNAL(reset()), SIGNAL(reset()));
354
connect(m_session, SIGNAL(finished()), SLOT(slotFinished()));
355
connect(m_session, SIGNAL(raiseOutputViews()), SIGNAL(raiseOutputViews()));
356
connect(m_session, SIGNAL(raiseVariableViews()), SIGNAL(raiseVariableViews()));
361
void CppDebuggerPlugin::projectClosed()
364
m_session->stopDebugger();
350
DebugSession *session = new DebugSession(m_controller);
351
KDevelop::ICore::self()->debugController()->addSession(session);
352
connect(session, SIGNAL(showMessage(QString,int)), SLOT(controllerMessage(QString,int)));
353
connect(session, SIGNAL(reset()), SIGNAL(reset()));
354
connect(session, SIGNAL(finished()), SLOT(slotFinished()));
355
connect(session, SIGNAL(raiseOutputViews()), SIGNAL(raiseOutputViews()));
356
connect(session, SIGNAL(raiseVariableViews()), SIGNAL(raiseVariableViews()));
368
360
void CppDebuggerPlugin::slotExamineCore()
370
362
emit showMessage(this, i18n("Choose a core file to examine..."), 1000);
372
KUrl coreFile = KFileDialog::getOpenUrl(QDir::homePath());
373
if (!coreFile.isValid())
364
SelectCoreDialog dlg(KDevelop::ICore::self()->uiController()->activeMainWindow());
365
if (dlg.exec() == KDialog::Rejected) {
376
emit showMessage(this, i18n("Examining core file %1", coreFile.url()), 1000);
378
createSession()->examineCoreFile(coreFile);
369
emit showMessage(this, i18n("Examining core file %1", dlg.core().toLocalFile()), 1000);
371
createSession()->examineCoreFile(dlg.binary(), dlg.core());