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

Method navigateToFileOffset

python/examples/triage/view.py:145–166  ·  view source on GitHub ↗
(self, offset)

Source from the content-addressed store, hash-verified

143 self.fullAnalysisButton.hide()
144
145 def navigateToFileOffset(self, offset):
146 if self.byteView is None:
147 addr = self.data.get_address_for_data_offset(offset)
148 view_frame = ViewFrame.viewFrameForWidget(self)
149 if view_frame is None:
150 return
151 if addr is None:
152 view_frame.navigate("Hex:Raw", offset)
153 else:
154 view_frame.navigate("Linear:" + view_frame.getCurrentDataType(), addr)
155 else:
156 if self.data == self.data.file.raw:
157 addr = offset
158 else:
159 addr = self.data.get_address_for_data_offset(offset)
160 if addr is None:
161 view_frame = ViewFrame.viewFrameForWidget(self)
162 if view_frame is not None:
163 view_frame.navigate("Hex:Raw", offset)
164 else:
165 self.byteView.navigate(addr)
166 self.byteView.setFocus(Qt.OtherFocusReason)
167
168 def focusInEvent(self, event):
169 if self.byteView is not None:

Callers 1

mousePressEventMethod · 0.45

Calls 2

navigateMethod · 0.45

Tested by

no test coverage detected