Package ghidra.app.util.viewer.field
Class XRefFieldMouseHandler
- java.lang.Object
-
- ghidra.app.util.viewer.field.XRefFieldMouseHandler
-
- All Implemented Interfaces:
FieldMouseHandler
,FieldMouseHandlerExtension
,ExtensionPoint
- Direct Known Subclasses:
VariableXRefFieldMouseHandler
public class XRefFieldMouseHandler extends java.lang.Object implements FieldMouseHandlerExtension
A handler to processXRefFieldMouseHandler
clicks.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface ghidra.util.classfinder.ExtensionPoint
ExtensionPoint.Exclude, ExtensionPoint.Util
-
-
Constructor Summary
Constructors Constructor Description XRefFieldMouseHandler()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
fieldElementClicked(java.lang.Object clickedObject, Navigatable sourceNavigatable, ProgramLocation location, java.awt.event.MouseEvent mouseEvent, ServiceProvider serviceProvider)
Called when a fieldField
has been clicked.protected Address
getFromReferenceAddress(ProgramLocation programLocation)
protected int
getIndex(ProgramLocation programLocation)
protected ProgramLocation
getReferredToLocation(Navigatable sourceNavigatable, ProgramLocation location)
java.lang.Class<?>[]
getSupportedProgramLocations()
Returns an array of types that this handler wishes to handle.protected Address
getToReferenceAddress(ProgramLocation programLocation, Program program)
protected boolean
isXREFHeaderLocation(ProgramLocation location)
protected void
showReferenceTable(Navigatable navigatable, ServiceProvider serviceProvider, TableService service, Address toAddress, Program program, java.util.List<Reference> refs)
protected void
showXRefDialog(Navigatable navigatable, ProgramLocation location, ServiceProvider serviceProvider)
-
-
-
Method Detail
-
fieldElementClicked
public boolean fieldElementClicked(java.lang.Object clickedObject, Navigatable sourceNavigatable, ProgramLocation location, java.awt.event.MouseEvent mouseEvent, ServiceProvider serviceProvider)
Description copied from interface:FieldMouseHandler
Called when a fieldField
has been clicked. The object being passed in may be of any type, as returned by the clicked field. The type is guaranteed to be one of the types returned in the call toFieldMouseHandler.getSupportedProgramLocations()
.- Specified by:
fieldElementClicked
in interfaceFieldMouseHandler
- Parameters:
clickedObject
- The object that was clickedsourceNavigatable
- The source navigatable that was clicked upon.location
- The location at the time the click was made. Due to swing delay, this location may not be the same as you would get if you asked the navagatable for the current location.SCmouseEvent
- The mouse event that triggered the clickserviceProvider
- A service provider used to access system resources.- Returns:
- true if this handler wishes to have exclusive handling rights to processing the clickedObject
- See Also:
FieldMouseHandlerExtension#fieldElementClicked(Object, Navigatable, MouseEvent, ServiceProvider)
-
isXREFHeaderLocation
protected boolean isXREFHeaderLocation(ProgramLocation location)
-
getToReferenceAddress
protected Address getToReferenceAddress(ProgramLocation programLocation, Program program)
-
getFromReferenceAddress
protected Address getFromReferenceAddress(ProgramLocation programLocation)
-
getIndex
protected int getIndex(ProgramLocation programLocation)
-
showXRefDialog
protected void showXRefDialog(Navigatable navigatable, ProgramLocation location, ServiceProvider serviceProvider)
-
showReferenceTable
protected void showReferenceTable(Navigatable navigatable, ServiceProvider serviceProvider, TableService service, Address toAddress, Program program, java.util.List<Reference> refs)
-
getReferredToLocation
protected ProgramLocation getReferredToLocation(Navigatable sourceNavigatable, ProgramLocation location)
-
getSupportedProgramLocations
public java.lang.Class<?>[] getSupportedProgramLocations()
Description copied from interface:FieldMouseHandler
Returns an array of types that this handler wishes to handle.- Specified by:
getSupportedProgramLocations
in interfaceFieldMouseHandler
- Returns:
- an array of types that this handler wishes to handle.
-
-