Example #1
0
	def _register(self, handle):
		self._cb = core.BNNavigationHandler()
		self._cb.context = 0
		self._cb.getCurrentView = self._cb.getCurrentView.__class__(self._get_current_view)
		self._cb.getCurrentOffset = self._cb.getCurrentOffset.__class__(self._get_current_offset)
		self._cb.navigate = self._cb.navigate.__class__(self._navigate)
		core.BNSetFileMetadataNavigationHandler(handle, self._cb)
Example #2
0
 def __del__(self):
     if self.navigation is not None:
         core.BNSetFileMetadataNavigationHandler(self.handle, None)
     core.BNFreeFileMetadata(self.handle)