#include <DisasmTopCountAttrProvider.hh>
Simple list window for displaying list of top execution counts.
Definition at line 85 of file DisasmTopCountAttrProvider.hh.
◆ DisasmExecCountFrame()
The Constructor.
- Parameters
-
parent | Parent window of the miniframe. |
id | Window identifier for the frame. |
topCountTable | Table of top execution counts to display. |
Definition at line 60 of file DisasmTopCountAttrProvider.cc.
63 wxMiniFrame(parent,
id, _T(
"Top Execution Counts")),
66 wxSizer* sizer =
new wxBoxSizer(wxVERTICAL);
67 list_ =
new wxListCtrl(
68 this, -1, wxDefaultPosition, wxDefaultSize,
69 wxLC_REPORT | wxLC_SINGLE_SEL);
71 list_->InsertColumn(0, _T(
"Exec Count"), wxLIST_FORMAT_LEFT, 100);
72 list_->InsertColumn(1, _T(
"Address range"), wxLIST_FORMAT_LEFT, 200);
73 sizer->Add(
list_, 1, wxEXPAND|wxALL, 5);
◆ ~DisasmExecCountFrame()
DisasmExecCountFrame::~DisasmExecCountFrame |
( |
| ) |
|
|
virtual |
◆ addExecCount()
void DisasmExecCountFrame::addExecCount |
( |
unsigned |
execCount, |
|
|
unsigned |
start, |
|
|
unsigned |
end, |
|
|
const wxColour & |
colour |
|
) |
| |
◆ onClose()
void DisasmExecCountFrame::onClose |
( |
wxCloseEvent & |
event | ) |
|
|
private |
◆ onSelection()
void DisasmExecCountFrame::onSelection |
( |
wxListEvent & |
event | ) |
|
|
private |
◆ update()
void DisasmExecCountFrame::update |
( |
| ) |
|
Updates the execution count list.
Definition at line 87 of file DisasmTopCountAttrProvider.cc.
89 list_->DeleteAllItems();
91 DisasmTopCountAttrProvider::ExecutionCountTable::const_iterator iter =
99 unsigned count = (*iter).first;
103 DisasmTopCountAttrProvider::AddressSet::const_iterator citer =
108 while (citer != addressSet.end()) {
109 unsigned rangeFirst = *citer;
110 unsigned rangeLast = *citer;
111 while (citer != addressSet.end() && (*citer == rangeLast)) {
119 if (rangeFirst != rangeLast) {
120 range.Append(_T(
" - "));
125 list_->SetItem(0, 1, range);
126 list_->SetItemData(0, rangeFirst);
131 list_->SetItemBackgroundColour(
132 0, wxColour(255 , pos * 50, 0));
134 list_->SetItemBackgroundColour(
135 0, wxColour(255 - (2 * (pos * 25 - 128)), 255, 0));
139 if (citer != addressSet.end()) {
References list_, topCountTable_, and WxConversion::toWxString().
Referenced by DisasmTopCountAttrProvider::update().
◆ list_
wxListCtrl* DisasmExecCountFrame::list_ |
|
private |
◆ topCountTable_
The documentation for this class was generated from the following files: