AI-generated Key Takeaways
-
The GCKUICastButtonDelegate protocol allows you to present custom dialogs when the Cast button is tapped.
-
The
castButtonDidTapToPresentLocalNetworkAccessPermissionDialog:method is called the first time the Cast button is tapped on iOS 14+ if device discovery hasn't started. -
The
castButtonDidTap:toPresentDialogForCastState:method is called when the Cast button is tapped after device discovery has been initiated.
Overview
Use the methods of this protocol to present custom dialog in response to user action.
- Since
- 4.6.0
Inherits <UIButtonNSObject>.
Instance Method Summary | |
| (void) | - castButtonDidTapToPresentLocalNetworkAccessPermissionDialog: |
| Tells the delegate that the cast button is tapped by the user for the first time on iOS14 or above and cast devices discovery has not started in the current or previous app sessions. More... | |
| (void) | - castButtonDidTap:toPresentDialogForCastState: |
| Tells the delegate that the cast button is tapped by the user after the discovery has been initiated in current or previous app session. More... | |
Method Detail
|
optional |
Tells the delegate that the cast button is tapped by the user for the first time on iOS14 or above and cast devices discovery has not started in the current or previous app sessions.
Implement this method to present the custom dialog. If not implmemented, the default dialog is presented.
- Parameters
-
castButton Instance of GCKUICastButtontapped.
|
optional |
Tells the delegate that the cast button is tapped by the user after the discovery has been initiated in current or previous app session.
Implement this method to present the custom dialog as per the cast state. Observe GCKCastContext::castState to update the dialog dynamically as per changes in the cast state. If not implmemented, the default dialog is presented.
- Parameters
-
castButton Instance of GCKUICastButtontapped.castState Cast state when the cast button is tapped.