MSFCelestialEventListener

Objective-C


@interface MSFCelestialEventListener : NSObject {
  void *swigCPtr;
  BOOL swigCMemOwn;
}

Swift

class MSFCelestialEventListener : NSObject

Reports clicks on the objects of a CelestialLayer, and on the empty sky around them.

  • Called when an object of the layer is clicked. Objects are tested against the touch ray together with every other layer’s content, so an object behind terrain is not reported.

    Declaration

    Objective-C

    - (BOOL)onCelestialObjectClicked:(MSFClickInfo *)clickInfo
                     celestialObject:(MSFCelestialObject *)celestialObject;

    Swift

    func onCelestialObjectClicked(_ clickInfo: MSFClickInfo!, celestialObject: MSFCelestialObject!) -> Bool

    Parameters

    clickInfo

    The click that hit the object.

    celestialObject

    The object that was clicked.

    Return Value

    True if the click was handled and must not be passed on, false otherwise.

  • Called when an object of the layer is clicked. Objects are tested against the touch ray together with every other layer’s content, so an object behind terrain is not reported.

    Declaration

    Objective-C

    - (BOOL)onCelestialObjectClickedSwigExplicitMSFCelestialEventListener:
                (MSFClickInfo *)clickInfo
                                                          celestialObject:
                                                              (MSFCelestialObject *)
                                                                  celestialObject;

    Swift

    func onCelestialObjectClickedSwigExplicitMSFCelestialEventListener(_ clickInfo: MSFClickInfo!, celestialObject: MSFCelestialObject!) -> Bool

    Parameters

    clickInfo

    The click that hit the object.

    celestialObject

    The object that was clicked.

    Return Value

    True if the click was handled and must not be passed on, false otherwise.

  • Called when a click aims at the sky and hits nothing, on no layer: the map listener is not called then, as there is no ground position to report. E.g. to clear a selection.

    Declaration

    Objective-C

    - (BOOL)onSkyClicked:(MSFClickInfo *)clickInfo
                 azimuth:(float)azimuth
                altitude:(float)altitude;

    Swift

    func onSkyClicked(_ clickInfo: MSFClickInfo!, azimuth: Float, altitude: Float) -> Bool

    Parameters

    clickInfo

    The click.

    azimuth

    The azimuth the click aimed at, in degrees clockwise from north.

    altitude

    The altitude the click aimed at, in degrees above the horizon.

    Return Value

    True if the click was handled and must not be passed on to the other celestial layers.

  • Called when a click aims at the sky and hits nothing, on no layer: the map listener is not called then, as there is no ground position to report. E.g. to clear a selection.

    Declaration

    Objective-C

    - (BOOL)onSkyClickedSwigExplicitMSFCelestialEventListener:
                (MSFClickInfo *)clickInfo
                                                      azimuth:(float)azimuth
                                                     altitude:(float)altitude;

    Swift

    func onSkyClickedSwigExplicitMSFCelestialEventListener(_ clickInfo: MSFClickInfo!, azimuth: Float, altitude: Float) -> Bool

    Parameters

    clickInfo

    The click.

    azimuth

    The azimuth the click aimed at, in degrees clockwise from north.

    altitude

    The altitude the click aimed at, in degrees above the horizon.

    Return Value

    True if the click was handled and must not be passed on to the other celestial layers.

  • Undocumented

    Declaration

    Objective-C

    -(id)init;

    Swift

    init!()
  • Undocumented

    Declaration

    Objective-C

    -(void)dealloc;

    Swift

    func dealloc()