void LLDBPlugin::OnDebugQuickDebug(clDebugEvent& event) { #ifdef __WXMSW__ ::wxMessageBox( _("Quick Debug with LLDB is not supported under Windows"), "CodeLite", wxOK | wxCENTER | wxICON_WARNING); return; #endif if(!DoInitializeDebugger(event, true)) { return; } LLDBConnectReturnObject retObj; LLDBSettings settings; settings.Load(); if(m_connector.Connect(retObj, settings, 5)) { // Apply the environment EnvSetter env; // Get list of breakpoints and add them ( we will apply them later on ) BreakpointInfo::Vec_t gdbBps; m_mgr->GetAllBreakpoints(gdbBps); // remove all breakpoints from previous session m_connector.DeleteAllBreakpoints(); // apply the serialized breakpoints // In 'Quick Debug' we stop on main m_connector.AddBreakpoint("main"); m_connector.AddBreakpoints(gdbBps); LLDBCommand startCommand; startCommand.FillEnvFromMemory(); startCommand.SetExecutable(event.GetExecutableName()); startCommand.SetCommandArguments(event.GetArguments()); startCommand.SetWorkingDirectory(event.GetWorkingDirectory()); startCommand.SetStartupCommands(event.GetStartupCommands()); startCommand.SetRedirectTTY(m_terminalTTY); m_connector.Start(startCommand); } else { // Failed to connect, notify and perform cleanup DoCleanup(); wxString message; message << _("Could not connect to codelite-lldb at '") << m_connector.GetConnectString() << "'"; ::wxMessageBox(message, "CodeLite", wxICON_ERROR | wxOK | wxCENTER); return; } }