From: Eran I. <no...@so...> - 2014-01-11 17:11:34
|
This is an automated email from the git hooks/post-receive script. It was generated because a ref change was pushed to the repository containing the project "codelite". The branch, master has been updated via 845aa45ee594c4a27ed847fabfe452e6bd650add (commit) via d4cf5423346b83086fc0cfe04b7f0899e1760bfc (commit) via 83a202c0e1eda036b6298fb43a2b92670987e9df (commit) via a1b7603c08c39c9d84be8bf229af4969fb7721ba (commit) from 0bab0c1d608ad91c6290e8f39c82c4f22ccdb15f (commit) Those revisions listed above that are new to this repository have not appeared on any other notification email; so we list those revisions in full, below. - Log ----------------------------------------------------------------- https://sourceforge.net/p/codelite/codelitegit/ci/845aa45ee594c4a27ed847fabfe452e6bd650add commit 845aa45ee594c4a27ed847fabfe452e6bd650add Author: Eran <era...@gm...> Date: Sat Jan 11 19:10:31 2014 +0200 updated TODO list diff --git a/TODO.TXT b/TODO.TXT index 93b27b7..335b0f5 100644 --- a/TODO.TXT +++ b/TODO.TXT @@ -1,3 +1,2 @@ -- Add events for all debugger UI actions so plugins code implement it instead of the default debugger - Allow multiple file open in open-resource dialog - New 'Find Bar' https://sourceforge.net/p/codelite/codelitegit/ci/d4cf5423346b83086fc0cfe04b7f0899e1760bfc commit d4cf5423346b83086fc0cfe04b7f0899e1760bfc Author: Eran <era...@gm...> Date: Sat Jan 11 19:06:37 2014 +0200 Compilation error diff --git a/LiteEditor/frame.cpp b/LiteEditor/frame.cpp index cf1781e..c9393ae 100644 --- a/LiteEditor/frame.cpp +++ b/LiteEditor/frame.cpp @@ -3157,7 +3157,7 @@ void clMainFrame::OnDebugRestartUI(wxUpdateUIEvent &e) CHECK_SHUTDOWN(); clDebugEvent event(wxEVT_DBG_IS_RUNNING); - EventNotifier::Get()->ProcessEvent( event ) + EventNotifier::Get()->ProcessEvent( event ); IDebugger *dbgr = DebuggerMgr::Get().GetActiveDebugger(); e.Enable(event.IsAnswer() || (dbgr && dbgr->IsRunning() && ManagerST::Get()->DbgCanInteract()) ); https://sourceforge.net/p/codelite/codelitegit/ci/83a202c0e1eda036b6298fb43a2b92670987e9df commit 83a202c0e1eda036b6298fb43a2b92670987e9df Author: Eran <era...@gm...> Date: Sat Jan 11 19:04:39 2014 +0200 Make all debugger UI buttons available to plugins via special event type (clDebugEvent). With this change, a plugin can implement a full working debugger diff --git a/Interfaces/plugin.h b/Interfaces/plugin.h index 0a9fc97..5d7c8c5 100644 --- a/Interfaces/plugin.h +++ b/Interfaces/plugin.h @@ -574,7 +574,9 @@ enum MenuType { #define wxEVT_DBG_UI_NEXT 3552 // Next line #define wxEVT_DBG_UI_NEXT_INST 3553 // Next instruction #define wxEVT_DBG_UI_INTERRUPT 3554 // Interrupt the debugger execution -#define wxEVT_DBG_IS_RUNNING 3555 // Use evet.SetAnswer() method to reply +#define wxEVT_DBG_UI_SHOW_CURSOR 3555 // Set the focus to the current debugger file/line +#define wxEVT_DBG_UI_RESTART 3556 // Restart the debug session +#define wxEVT_DBG_IS_RUNNING 3557 // Use evet.SetAnswer() method to reply //------------------------------------------------------------------ //each plugin must implement this interface diff --git a/LiteEditor/frame.cpp b/LiteEditor/frame.cpp index aa85bf9..cf1781e 100644 --- a/LiteEditor/frame.cpp +++ b/LiteEditor/frame.cpp @@ -3141,6 +3141,10 @@ void clMainFrame::OnDebugUI(wxUpdateUIEvent &e) void clMainFrame::OnDebugRestart(wxCommandEvent &e) { + clDebugEvent event(wxEVT_DBG_UI_RESTART); + if ( EventNotifier::Get()->ProcessEvent( event ) ) + return; + IDebugger *dbgr = DebuggerMgr::Get().GetActiveDebugger(); if(dbgr && dbgr->IsRunning() && ManagerST::Get()->DbgCanInteract()) { GetDebuggerPane()->GetLocalsTable()->Clear(); @@ -3151,8 +3155,12 @@ void clMainFrame::OnDebugRestart(wxCommandEvent &e) void clMainFrame::OnDebugRestartUI(wxUpdateUIEvent &e) { CHECK_SHUTDOWN(); + + clDebugEvent event(wxEVT_DBG_IS_RUNNING); + EventNotifier::Get()->ProcessEvent( event ) + IDebugger *dbgr = DebuggerMgr::Get().GetActiveDebugger(); - e.Enable(dbgr && dbgr->IsRunning() && ManagerST::Get()->DbgCanInteract()); + e.Enable(event.IsAnswer() || (dbgr && dbgr->IsRunning() && ManagerST::Get()->DbgCanInteract()) ); } void clMainFrame::OnDebugStop(wxCommandEvent &e) @@ -3168,8 +3176,12 @@ void clMainFrame::OnDebugStop(wxCommandEvent &e) void clMainFrame::OnDebugStopUI(wxUpdateUIEvent &e) { CHECK_SHUTDOWN(); + + clDebugEvent eventIsRunning(wxEVT_DBG_IS_RUNNING); + EventNotifier::Get()->ProcessEvent( eventIsRunning ); + IDebugger *dbgr = DebuggerMgr::Get().GetActiveDebugger(); - e.Enable(dbgr && dbgr->IsRunning()); + e.Enable( eventIsRunning.IsAnswer() || (dbgr && dbgr->IsRunning()) ); } void clMainFrame::OnDebugManageBreakpointsUI(wxUpdateUIEvent &e) @@ -3191,20 +3203,40 @@ void clMainFrame::OnDebugManageBreakpointsUI(wxUpdateUIEvent &e) void clMainFrame::OnDebugCmd(wxCommandEvent &e) { int cmd(wxNOT_FOUND); + int eventId(wxNOT_FOUND); + if (e.GetId() == XRCID("pause_debugger")) { cmd = DBG_PAUSE; + eventId = wxEVT_DBG_UI_INTERRUPT; + } else if (e.GetId() == XRCID("dbg_stepin")) { cmd = DBG_STEPIN; + eventId = wxEVT_DBG_UI_STEP_IN; + } else if (e.GetId() == XRCID("dbg_stepout")) { cmd = DBG_STEPOUT; + eventId = wxEVT_DBG_UI_STEP_OUT; + } else if (e.GetId() == XRCID("dbg_next")) { cmd = DBG_NEXT; + eventId = wxEVT_DBG_UI_NEXT; + } else if (e.GetId() == XRCID("show_cursor")) { cmd = DBG_SHOW_CURSOR; + eventId = wxEVT_DBG_UI_SHOW_CURSOR; + } else if ( e.GetId() == XRCID("dbg_nexti")) { cmd = DBG_NEXTI; + eventId = wxEVT_DBG_UI_NEXT_INST; + } - + + // ALlow the plugins to handle this command first + clDebugEvent evnt(eventId); + if ( EventNotifier::Get()->ProcessEvent( evnt ) ) { + return; + } + if (cmd != wxNOT_FOUND) { ManagerST::Get()->DbgDoSimpleCommand(cmd); } @@ -3213,6 +3245,10 @@ void clMainFrame::OnDebugCmd(wxCommandEvent &e) void clMainFrame::OnDebugCmdUI(wxUpdateUIEvent &e) { CHECK_SHUTDOWN(); + + clDebugEvent eventIsRunning(wxEVT_DBG_IS_RUNNING); + EventNotifier::Get()->ProcessEvent( eventIsRunning ); + if (e.GetId() == XRCID("pause_debugger") || e.GetId() == XRCID("dbg_stepin") || e.GetId() == XRCID("dbg_stepout") || @@ -3220,7 +3256,7 @@ void clMainFrame::OnDebugCmdUI(wxUpdateUIEvent &e) e.GetId() == XRCID("dbg_nexti") || e.GetId() == XRCID("show_cursor")) { IDebugger *dbgr = DebuggerMgr::Get().GetActiveDebugger(); - e.Enable(dbgr && dbgr->IsRunning()); + e.Enable(eventIsRunning.IsAnswer() || (dbgr && dbgr->IsRunning()) ); } } https://sourceforge.net/p/codelite/codelitegit/ci/a1b7603c08c39c9d84be8bf229af4969fb7721ba commit a1b7603c08c39c9d84be8bf229af4969fb7721ba Author: Eran <era...@gm...> Date: Sat Jan 11 18:49:14 2014 +0200 Removed debugger startup commands from Mac OSX diff --git a/LiteEditor/frame.cpp b/LiteEditor/frame.cpp index 3823fc9..aa85bf9 100644 --- a/LiteEditor/frame.cpp +++ b/LiteEditor/frame.cpp @@ -856,7 +856,7 @@ void clMainFrame::CreateGUIControls(void) m_mgr.GetArtProvider()->SetColor(wxAUI_DOCKART_BACKGROUND_COLOUR, DrawingUtils::GetPanelBgColour()); //initialize debugger configuration tool - DebuggerConfigTool::Get()->Load(wxT("config/debuggers.xml"), wxT("5.11")); + DebuggerConfigTool::Get()->Load(wxT("config/debuggers.xml"), wxT("5.4")); WorkspaceST::Get()->SetStartupDir(ManagerST::Get()->GetStarupDirectory()); #if wxCHECK_VERSION(2, 9, 5) diff --git a/Runtime/config/debuggers.xml.gtk b/Runtime/config/debuggers.xml.gtk index 77d73c5..17f1e2d 100644 --- a/Runtime/config/debuggers.xml.gtk +++ b/Runtime/config/debuggers.xml.gtk @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8"?> -<Debuggers Version="5.11"> +<Debuggers Version="5.4"> <ArchiveObject Name="GNU gdb debugger"> <wxString Value="GNU gdb debugger" Name="name"/> <wxString Value="" Name="path"/> @@ -33,23 +33,6 @@ register_wx_printers (None) end]]> </CData> </ArchiveObject> - <ArchiveObject Name="DebuggerCommands"> - <long Value="1" Name="size"/> - <SerializedObject Name="PreDefinedSet0"> - <wxString Value="Default" Name="m_name"/> - <bool Value="1" Name="m_active"/> - <long Value="2" Name="size"/> - <SerializedObject Name="DebuggerCmd0"> - <wxString Value="std::string" Name="m_name"/> - <wxString Value="($(Variable))._M_dataplus._M_p" Name="m_command"/> - <wxString Value="print" Name="m_dbgCommand"/> - </SerializedObject> - <SerializedObject Name="DebuggerCmd1"> - <wxString Value="wxString" Name="m_name"/> - <wxString Value="($(Variable)).m_impl._M_dataplus._M_p" Name="m_command"/> - <wxString Value="print" Name="m_dbgCommand"/> - </SerializedObject> - </SerializedObject> - </ArchiveObject> + <ArchiveObject Name="DebuggerCommands"/> </Debuggers> diff --git a/Runtime/config/debuggers.xml.mac b/Runtime/config/debuggers.xml.mac new file mode 100644 index 0000000..c53f233 --- /dev/null +++ b/Runtime/config/debuggers.xml.mac @@ -0,0 +1,24 @@ +<?xml version="1.0" encoding="UTF-8"?> +<Debuggers Version="5.4"> + <ArchiveObject Name="GNU gdb debugger"> + <wxString Value="GNU gdb debugger" Name="name"/> + <wxString Value="" Name="path"/> + <bool Value="0" Name="enableDebugLog"/> + <bool Value="1" Name="enablePendingBreakpoints"/> + <bool Value="0" Name="breakAtWinMain"/> + <bool Value="0" Name="showTerminal"/> + <wxString Value="" Name="consoleCommand"/> + <bool Value="0" Name="useRelativeFilePaths"/> + <bool Value="0" Name="catchThrow"/> + <bool Value="1" Name="showTooltips"/> + <bool Value="0" Name="debugAsserts"/> + <int Value="200" Name="maxDisplayStringSize"/> + <bool Value="0" Name="resolveLocals"/> + <bool Value="0" Name="autoExpandTipItems"/> + <bool Value="1" Name="applyBreakpointsAfterProgramStarted"/> + <CData Name="startupCommands"> + <![CDATA[]]> + </CData> + </ArchiveObject> + <ArchiveObject Name="DebuggerCommands"/> +</Debuggers> diff --git a/Runtime/make_mac_bundle.sh b/Runtime/make_mac_bundle.sh index fbe5143..057ffc5 100755 --- a/Runtime/make_mac_bundle.sh +++ b/Runtime/make_mac_bundle.sh @@ -194,7 +194,7 @@ cp ../../Runtime/config/codelite.xml.default.mac ./codelite.app/Contents/SharedS ## replace the executable name according to the configuration used in the build cat ../../Runtime/Info.plist.template | sed s/EXE_NAME/codelite/g >> ./codelite.app/Contents/Info.plist -cp ../../Runtime/config/debuggers.xml.default ./codelite.app/Contents/SharedSupport/config +cp ../../Runtime/config/debuggers.xml.mac ./codelite.app/Contents/SharedSupport/config/debuggers.xml.default ## License cp ../../Runtime/../LICENSE ./codelite.app/Contents/SharedSupport/ diff --git a/TODO.TXT b/TODO.TXT index e5c87fa..93b27b7 100644 --- a/TODO.TXT +++ b/TODO.TXT @@ -1,2 +1,3 @@ - Add events for all debugger UI actions so plugins code implement it instead of the default debugger - Allow multiple file open in open-resource dialog +- New 'Find Bar' ----------------------------------------------------------------------- Summary of changes: Interfaces/plugin.h | 4 ++- LiteEditor/frame.cpp | 46 +++++++++++++++++++++++++++++++++---- Runtime/config/debuggers.xml.gtk | 21 +--------------- Runtime/config/debuggers.xml.mac | 24 +++++++++++++++++++ Runtime/make_mac_bundle.sh | 2 +- TODO.TXT | 2 +- 6 files changed, 72 insertions(+), 27 deletions(-) create mode 100644 Runtime/config/debuggers.xml.mac hooks/post-receive -- codelite |