当前位置: 首页>>代码示例>>C++>>正文


C++ LLDBEvent类代码示例

本文整理汇总了C++中LLDBEvent的典型用法代码示例。如果您正苦于以下问题:C++ LLDBEvent类的具体用法?C++ LLDBEvent怎么用?C++ LLDBEvent使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。


在下文中一共展示了LLDBEvent类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。

示例1: OnLLDBStarted

void LLDBPlugin::OnLLDBStarted(LLDBEvent& event)
{
    event.Skip();
    InitializeUI();
    LoadLLDBPerspective();

    // If this is a normal debug session, a start notification
    // should follow a 'Run' command
    switch(event.GetSessionType()) {
    case kDebugSessionTypeCore:
        CL_DEBUG("CODELITE>> LLDB started (core file)");
        break;

    case kDebugSessionTypeAttach: {
        LLDBSettings settings;
        m_raisOnBpHit = settings.Load().IsRaiseWhenBreakpointHit();
        CL_DEBUG("CODELITE>> LLDB started (attached)");
        m_connector.SetAttachedToProcess(event.GetSessionType() == kDebugSessionTypeAttach);
        // m_connector.Continue();
        break;
    }
    case kDebugSessionTypeNormal: {
        LLDBSettings settings;
        m_raisOnBpHit = settings.Load().IsRaiseWhenBreakpointHit();
        CL_DEBUG("CODELITE>> LLDB started (normal)");
        m_connector.Run();
        break;
    }
    }

    wxCommandEvent e2(wxEVT_DEBUG_STARTED);
    EventNotifier::Get()->AddPendingEvent(e2);
}
开发者ID:raresp,项目名称:codelite,代码行数:33,代码来源:LLDBPlugin.cpp

示例2: OnLLDBBreakpointsUpdated

void LLDBPlugin::OnLLDBBreakpointsUpdated(LLDBEvent& event)
{
    event.Skip();
    // update the ui (mainly editors)
    // this is done by replacing the breakpoints list with a new one (the updated one we take from LLDB)
    m_mgr->SetBreakpoints(LLDBBreakpoint::ToBreakpointInfoVector(event.GetBreakpoints()));
}
开发者ID:eranif,项目名称:codelite,代码行数:7,代码来源:LLDBPlugin.cpp

示例3: OnLLDBVariableExpanded

void LLDBTooltip::OnLLDBVariableExpanded(LLDBEvent& event)
{
    int variableId = event.GetVariableId();
	wxUnusedVar(variableId);
    std::map<int, wxTreeItemId>::iterator iter = m_itemsPendingExpansion.find(event.GetVariableId());
    if(iter == m_itemsPendingExpansion.end()) {
        // does not belong to us
        event.Skip();
        return;
    }

    wxTreeItemId parentItem = iter->second;

    // add the variables to the tree
    for(size_t i = 0; i < event.GetVariables().size(); ++i) {
        DoAddVariable(parentItem, event.GetVariables().at(i));
    }

    // Expand the parent item
    if(m_treeCtrl->HasChildren(parentItem)) {
        m_treeCtrl->Expand(parentItem);
    }

    // remove it
    m_itemsPendingExpansion.erase(iter);
}
开发者ID:05storm26,项目名称:codelite,代码行数:26,代码来源:LLDBTooltip.cpp

示例4: OnLLDBExpressionEvaluated

void LLDBPlugin::OnLLDBExpressionEvaluated(LLDBEvent& event)
{
    CHECK_IS_LLDB_SESSION();

    // hide any tooltip
    if(!event.GetVariables().empty() && m_mgr->GetActiveEditor()) {
        if(!m_tooltip) { m_tooltip = new LLDBTooltip(this); }
        m_tooltip->Show(event.GetExpression(), event.GetVariables().at(0));
    }
}
开发者ID:eranif,项目名称:codelite,代码行数:10,代码来源:LLDBPlugin.cpp

示例5: OnLLDBLocalsUpdated

void LLDBLocalsView::OnLLDBLocalsUpdated(LLDBEvent& event)
{
    // FIXME: optimize this to only retrieve the top levle variables
    // the children should be obtained in the 'OnItemExpading' event handler
    event.Skip();
    wxWindowUpdateLocker locker(m_treeList);
    Enable(true);

    m_treeList->DeleteChildren(m_treeList->GetRootItem());
    CL_DEBUG("Updating locals view");
    DoAddVariableToView(event.GetVariables(), m_treeList->GetRootItem());
}
开发者ID:292388900,项目名称:codelite,代码行数:12,代码来源:LLDBLocalsView.cpp

示例6: OnLLDBBreakpointsUpdated

void MainDialog::OnLLDBBreakpointsUpdated(LLDBEvent& e)
{
    e.Skip();
    
    wxString msg;
    const LLDBBreakpoint::Vec_t &bps = e.GetBreakpoints();
    for(size_t i=0; i<bps.size(); ++i) {
        msg << bps.at(i)->ToString() << "\n";
    }
    
    m_textCtrlLog->AppendText("Breakpoints updated:\n");
    m_textCtrlLog->AppendText( msg );
}
开发者ID:qioixiy,项目名称:codelite,代码行数:13,代码来源:MainDialog.cpp

示例7: OnLLDBStopped

void LLDBDebuggerPlugin::OnLLDBStopped(LLDBEvent& event)
{
    event.Skip();
    wxFileName fn( event.GetFileName() );
    CL_DEBUG(wxString() << "CODELITE>> LLDB stopped at " << event.GetFileName() << ":" << event.GetLinenumber() );
    if ( fn.FileExists() ) {
        if ( m_mgr->OpenFile( fn.GetFullPath(), "", event.GetLinenumber() ) ) {
            IEditor* editor = m_mgr->GetActiveEditor();
            if ( editor ) {
                editor->GetSTC()->ScrollToLine( event.GetLinenumber() );
            }
        }
    }
}
开发者ID:idkqh7,项目名称:codelite,代码行数:14,代码来源:lldbdebugger-plugin.cpp

示例8: OnLLDBVariableExpanded

void LLDBLocalsView::OnLLDBVariableExpanded(LLDBEvent& event)
{
    int variableId = event.GetVariableId();
    // try to locate this item in our map
    LLDBLocalsView::IntItemMap_t::iterator iter = m_pendingExpandItems.find(variableId);
    if(iter == m_pendingExpandItems.end()) {
        // does not belong to us - skip it
        event.Skip();
        return;
    }

    // add the variables
    DoAddVariableToView(event.GetVariables(), iter->second);
    m_pendingExpandItems.erase(iter);
}
开发者ID:292388900,项目名称:codelite,代码行数:15,代码来源:LLDBLocalsView.cpp

示例9: OnLLDBExited

void LLDBPlugin::OnLLDBExited(LLDBEvent& event)
{
    event.Skip();
    m_connector.SetGoingDown(true);

    // Stop the debugger ( do not notify about it, since we are in the handler...)
    m_connector.Cleanup();

    // Save current perspective before destroying the session
    if(m_isPerspectiveLoaded) {
        m_mgr->SavePerspective("LLDB-debugger");

        // Restore the old perspective
        m_mgr->LoadPerspective("Default");
        m_isPerspectiveLoaded = false;
    }

    DestroyUI();

    // Reset various state variables
    DoCleanup();

    CL_DEBUG("CODELITE>> LLDB exited");

    // Also notify codelite's event
    clDebugEvent e2(wxEVT_DEBUG_ENDED);
    EventNotifier::Get()->AddPendingEvent(e2);

    {
        clDebugEvent e(wxEVT_DEBUG_ENDED);
        EventNotifier::Get()->AddPendingEvent(e);
    }
}
开发者ID:eranif,项目名称:codelite,代码行数:33,代码来源:LLDBPlugin.cpp

示例10: OnLLDBRunning

void LLDBPlugin::OnLLDBRunning(LLDBEvent& event)
{
    event.Skip();
    m_connector.SetCanInteract(false);

    // When the IDE loses the focus - clear the debugger marker
    ClearDebuggerMarker();
}
开发者ID:eranif,项目名称:codelite,代码行数:8,代码来源:LLDBPlugin.cpp

示例11: OnLLDBCrashed

void LLDBPlugin::OnLLDBCrashed(LLDBEvent& event)
{
    event.Skip();
    // Report it as crash only if not going down (i.e. we got an LLDBExit event)
    if(!m_connector.IsGoingDown()) {
        ::wxMessageBox(_("LLDB crashed! Terminating debug session"), "CodeLite", wxOK | wxICON_ERROR | wxCENTER);
    }
    OnLLDBExited(event);
}
开发者ID:GaganJotSingh,项目名称:codelite,代码行数:9,代码来源:LLDBPlugin.cpp

示例12: OnLLDBStarted

void LLDBDebuggerPlugin::OnLLDBStarted(LLDBEvent& event)
{
    event.Skip();
    m_isRunning = true;
    
    CL_DEBUG("CODELITE>> LLDB started");
    wxCommandEvent e2(wxEVT_DEBUG_STARTED);
    EventNotifier::Get()->AddPendingEvent( e2 );
}
开发者ID:idkqh7,项目名称:codelite,代码行数:9,代码来源:lldbdebugger-plugin.cpp

示例13: OnLLDBExited

void LLDBDebuggerPlugin::OnLLDBExited(LLDBEvent& event)
{
    event.Skip();
    m_isRunning = false;
    CL_DEBUG("CODELITE>> LLDB exited");
    // Also notify codelite's event
    wxCommandEvent e2(wxEVT_DEBUG_ENDED);
    EventNotifier::Get()->AddPendingEvent( e2 );
}
开发者ID:idkqh7,项目名称:codelite,代码行数:9,代码来源:lldbdebugger-plugin.cpp

示例14: OnLLDBLaunchSuccess

void LLDBPlugin::OnLLDBLaunchSuccess(LLDBEvent& event)
{
    event.Skip();
    m_connector.SetCanInteract(true);
    m_connector.SetIsRunning(true);

    CL_DEBUG("CODELITE>> Applying breakpoints...");
    m_connector.ApplyBreakpoints();
    m_connector.Next();
}
开发者ID:eranif,项目名称:codelite,代码行数:10,代码来源:LLDBPlugin.cpp

示例15: OnLLDBStoppedOnEntry

void LLDBPlugin::OnLLDBStoppedOnEntry(LLDBEvent& event)
{
    event.Skip();
    m_connector.SetCanInteract(true);
    m_connector.SetIsRunning(true);

    CL_DEBUG("CODELITE>> Applying breakpoints...");
    m_connector.ApplyBreakpoints();
    CL_DEBUG("CODELITE>> continue...");
    m_connector.Continue();
}
开发者ID:eranif,项目名称:codelite,代码行数:11,代码来源:LLDBPlugin.cpp


注:本文中的LLDBEvent类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。