MCPcopy Create free account
hub / github.com/Vector35/binaryninja-api / mousePressEvent

Method mousePressEvent

examples/triage/entropy.cpp:111–118  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

109
110
111void EntropyWidget::mousePressEvent(QMouseEvent* event)
112{
113 if (event->button() != Qt::LeftButton)
114 return;
115 float frac = (float)event->pos().x() / (float)rect().width();
116 uint64_t offset = (uint64_t)(frac * m_width * m_blockSize);
117 m_view->navigateToFileOffset(offset);
118}

Callers

nothing calls this directly

Calls 3

xMethod · 0.80
widthMethod · 0.45
navigateToFileOffsetMethod · 0.45

Tested by

no test coverage detected