Deprecated: trim(): Passing null to parameter #1 ($string) of type string is deprecated in /var/www/html/extensions/Variables/includes/ExtVariables.php on line 198
CALayerHost: Difference between revisions - iPhone Development Wiki

CALayerHost: Difference between revisions

From iPhone Development Wiki
m (Very minor typo)
(Added info on how touches are delivered)
Line 1: Line 1:
[[CALayerHost]] is a [[CALayer]] subclass which renders another layer's render context. Another thing it does is to allow touches to be passed directly to the process which is running the layer it is showing. The touches aren't forwarded, they never get registered in the process running the [[CALayerHost]].
[[CALayerHost]] is a [[CALayer]] subclass which renders another layer's render context. It allows touches to be passed directly to the process in which the layer is displaying. Touches are delivered to [[backboardd]] by [[IOKit]], which then calls the current '''CAWindowDisplayServer''''s ''-contextIdAtPosition:'' method to retrieve the context ID that the touches should be sent to.


{{function signature
{{function signature

Revision as of 12:29, 4 November 2013

CALayerHost is a CALayer subclass which renders another layer's render context. It allows touches to be passed directly to the process in which the layer is displaying. Touches are delivered to backboardd by IOKit, which then calls the current CAWindowDisplayServer's -contextIdAtPosition: method to retrieve the context ID that the touches should be sent to.

Signature @property(assign) unsigned contextId;
Available in 2.0 –

Setting this property makes the CALayerHost display the context of the layer that has that contextId.

References