GCKUIMiniMediaControlsViewController 類別

GCKUIMiniMediaControlsViewController 類別參考資料

總覽

導入「現正播放」控制列的檢視畫面控制器。

在預設設定中,畫面會顯示目前媒體項目的縮圖、標題和字幕、串流進度列,以及播放/暫停切換鈕。

如需委派通訊協定,請參閱 GCKUIMiniMediaControlsViewControllerDelegate

開始時間
3.0

繼承 UIViewController。實作 <GCKUIMediaButtonBarProtocol>

執行個體方法摘要

(NSUInteger) - buttonCount
 接收端可自訂的按鈕數量上限。更多...
 
(void) - setButtonType:atIndex:
 設定位置 index 的按鈕按鈕類型。更多...
 
(GCKUIMediaButtonType- buttonTypeAtIndex:
 傳回指定位置目前的按鈕類型。更多...
 
(void) - setCustomButton:atIndex:
 設定應在特定按鈕位置顯示的 UIButton 例項。更多...
 
(nullable UIButton *) - customButtonAtIndex:
 傳回指定位置的自訂按鈕參照。更多...
 

資源摘要

id
< GCKUIMiniMediaControlsViewControllerDelegate
delegate
 檢視控制器的控制列,通常是全螢幕檢視控制器,負責顯示及隱藏此控制列。更多...
 
BOOL thumbnailEnabled
 是否應顯示縮圖。更多...
 
BOOL active
 指出控制列的顯示狀態。更多...
 
CGFloat minHeight
 應呈現此檢視畫面的最小高度 (建議高度)。更多...
 

方法詳細資料

- (NSUInteger) buttonCount

接收端可自訂的按鈕數量上限。

傳回
按鈕數量。
- (void) setButtonType: (GCKUIMediaButtonType buttonType
atIndex: (NSUInteger)  index 

設定位置 index 的按鈕按鈕類型。

Parameters
buttonTypeThe type of the button. If the type is GCKUIMediaButtonTypeCustom, a UIButton instance should be passed for the same index using setCustomButton:atIndex:. Otherwise a default button is created and presented in that position.
indexThe position in which the button should be presented. 0 is the left-most position. Indices should be smaller than the value returned by buttonCount.
- (GCKUIMediaButtonType) buttonTypeAtIndex: (NSUInteger)  index

傳回指定位置目前的按鈕類型。

Parameters
indexThe button's position, where 0 is the left-most position.
傳回
所選位置的按鈕類型。
- (void) setCustomButton: (nullable UIButton *)  customButton
atIndex: (NSUInteger)  index 

設定應在特定按鈕位置顯示的 UIButton 例項。

Parameters
customButtonThe button instance to be presented in the control bar.
indexThe position in which the button should be presented. 0 is the left-most position. Indices should be smaller than the value returned by buttonCount.
- (nullable UIButton *) customButtonAtIndex: (NSUInteger)  index

傳回指定位置的自訂按鈕參照。

Parameters
indexThe button's position, where 0 is the right-most position.
傳回
在所選位置的按鈕參照;如果所選位置沒有自訂按鈕,或該位置無效,則為 nil

資源詳情

- (id<GCKUIMiniMediaControlsViewControllerDelegate>) delegate
readwritenonatomicweak

檢視控制器的控制列,通常是全螢幕檢視控制器,負責顯示及隱藏此控制列。

- (BOOL) thumbnailEnabled
readwritenonatomicassign

是否應顯示縮圖。

此屬性的預設值為 YES

- (BOOL) active
readnonatomicassign

指出控制列的顯示狀態。

如果為 YES,代表正在投放媒體,可透過控制列控制並顯示該媒體。NO 時,控制列應處於隱藏狀態。

- (CGFloat) minHeight
readnonatomicassign

應呈現此檢視畫面的最小高度 (建議高度)。