更新时间:2024-07-30 GMT+08:00

与会者列表菜单定制

buildParticipantToolBarMenuItems

接口描述

该接口用于构建与会者列表底部toolbar上的菜单。

图1 与会者列表菜单定制位置

注意事项

方法定义

1
- (NSArray <HWMConfToolBarMenuItem *> *)buildParticipantToolBarMenuItems;

参数描述

返回值

示例代码

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
/// 构建与会者列表底部toolbar上的菜单
- (NSArray <HWMConfToolBarMenuItem *> *)buildParticipantToolBarMenuItems{
    // 全场静音
    HWMConfToolBarMenuItem *muteAllItem = [HWMConfToolBarMenuItem defaultMuteAllItem];
    // 解除全场静音
    HWMConfToolBarMenuItem *unmuteAllItem = [HWMConfToolBarMenuItem defaultUnmuteAllItem];
    // 更多
    HWMConfToolBarMenuItem *moreItem = [HWMConfToolBarMenuItem defaultMemberListMoreItem];
    // 举手
    HWMConfToolBarMenuItem *handupItem = [HWMConfToolBarMenuItem defaultHandupItem];
    // 请求主持人
    HWMConfToolBarMenuItem *requestChairmanItem = [HWMConfToolBarMenuItem defaultRequestChairmanItem];
    
    return @[muteAllItem, unmuteAllItem, moreItem, handupItem, requestChairmanItem];
}

buildParticipantToolBarMoreMenuItems

接口描述

该接口用于构建与会者列表底部toolbar上的“更多”菜单。

图2 与会者列表更多定制位置

注意事项

方法定义

1
- (NSArray <HWMConfMenuItem *> *)buildParticipantToolBarMoreMenuItems;

参数描述

返回值

示例代码

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
/// 构建与会者列表底部toolbar上的“更多”菜单
- (NSArray <HWMConfMenuItem *> *)buildParticipantToolBarMoreMenuItems{
    // 释放支持人
    HWMConfMenuItem *releaseChairmanItem = [HWMConfMenuItem defaultReleaseChairmanItem];
    // 锁定会议
    HWMConfMenuItem *lockItem = [HWMConfMenuItem defaultLockItem];
    // 允许 or 禁止 与会者自己解除静音
    HWMConfMenuItem *allowUnmuteItem = [HWMConfMenuItem defaultAllowAttendeeUnmuteItem];
    
    return @[releaseChairmanItem, lockItem, allowUnmuteItem];
}

buildParticipantTitleBarMenuItems

接口描述

该接口用于构建与会者列表右上角的菜单。

图3 与会者列表右上角的菜单定制位置

注意事项

方法定义

1
- (NSArray <HWMConfToolBarMenuItem *> *)buildParticipantTitleBarMenuItems;

参数描述

返回值

示例代码

1
2
3
4
5
6
7
/// 构建与会者列表右上角的菜单
- (NSArray <HWMConfToolBarMenuItem *> *)buildParticipantTitleBarMenuItems{
    HWMConfToolBarMenuItem *shareItem = [HWMConfToolBarMenuItem defaultShareItem];
    HWMConfToolBarMenuItem *addressBookItem = [HWMConfToolBarMenuItem defaultAddressBookItem];
    
    return @[shareItem, addressBookItem];
}

buildParticipantActionSheetItems

接口描述

该接口用于构建与会者列表中成员点击弹出的actionsheet的菜单。

图4 与会者列表中成员点击弹出的actionsheet的菜单定制位置

注意事项

方法定义

1
- (NSArray <HWMConfParticipantActionMenuItem *> *)buildParticipantActionSheetItems;

参数描述

返回值

示例代码

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
/// 构建与会者列表中成员点击弹出的actionsheet的菜单
- (NSArray <HWMConfParticipantActionMenuItem *> *)buildParticipantActionSheetItems{
    // 请求主持人
    HWMConfParticipantActionMenuItem *requestChairmanItem = (HWMConfParticipantActionMenuItem *)[HWMConfParticipantActionMenuItem defaultRequestChairmanItem];
    // 释放主持人
    HWMConfParticipantActionMenuItem *releaseChairmanItem = (HWMConfParticipantActionMenuItem *)[HWMConfParticipantActionMenuItem defaultReleaseChairmanItem];
    // 广播会场 or 停止
    HWMConfParticipantActionMenuItem *broadcastItem = (HWMConfParticipantActionMenuItem *)[HWMConfParticipantActionMenuItem defaultBroadcastItem];
    // 静音 or 取消静音
    HWMConfParticipantActionMenuItem *muteItem = (HWMConfParticipantActionMenuItem *)[HWMConfParticipantActionMenuItem defaultMuteItem];
    // 挂断
    HWMConfParticipantActionMenuItem *hangupItem = (HWMConfParticipantActionMenuItem *)[HWMConfParticipantActionMenuItem defaultHangupItem];
    //移除与会者
    HWMConfParticipantActionMenuItem *removeAttendeeItem = (HWMConfParticipantActionMenuItem *)[HWMConfParticipantActionMenuItem defaultRemoveAttendeeItem];
    // 转移主持人
    HWMConfParticipantActionMenuItem *transferItem = (HWMConfParticipantActionMenuItem *)[HWMConfParticipantActionMenuItem defaultTransferChairmanItem];
    // 选看 or 取消选看
    HWMConfParticipantActionMenuItem *watchItem = (HWMConfParticipantActionMenuItem *)[HWMConfParticipantActionMenuItem defaultWatchItem];
    // 举手 or 手放下
    HWMConfParticipantActionMenuItem *handup = (HWMConfParticipantActionMenuItem *)[HWMConfParticipantActionMenuItem defaultHandupItem];
    // 呼叫其他号码
    HWMConfParticipantActionMenuItem *callOtherItem = (HWMConfParticipantActionMenuItem *)[HWMConfParticipantActionMenuItem defaultCallOtherNumberItem];
    // 改名
    HWMConfParticipantActionMenuItem *changeNameItem = (HWMConfParticipantActionMenuItem *)[HWMConfParticipantActionMenuItem defaultChangeNickNameItem];
    // 重呼
    HWMConfParticipantActionMenuItem *recallItem = (HWMConfParticipantActionMenuItem *)[HWMConfParticipantActionMenuItem defaultRecallItem];
    
    return @[releaseChairmanItem, requestChairmanItem, broadcastItem, watchItem, muteItem, transferItem, recallItem, callOtherItem, changeNameItem,    handup, hangupItem, removeAttendeeItem];
}

buildParticipantActionSheetItems头像点击事件自定义

接口描述

该接口用于构建与会者列表中成员点击弹出的actionsheet的菜单后,自定义头像点击事件。

图5 与会者列表中成员点击弹出的actionsheet的菜单,头像点击定制位置

注意事项

  1. 需要自定义buildParticipantActionSheetItems,添加defaultViewDetails的item。
  2. defaultViewDetails设置delegate对象
  3. 在代理对象位置实现代理

方法定义

参数描述

返回值

示例代码
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
/// 是否显示头像右边箭头及是否可以点击
- (BOOL)isShowAccessoryView:(HWMConfParticipant *)participant {
    // 根据需要返回是否显示
    return YES;
}

/// 构建与会者列表中成员点击弹出的actionsheet的菜单
- (NSArray <HWMConfParticipantActionMenuItem *> *)buildParticipantActionSheetItems{
    /// 查看详情
    HWMConfParticipantActionMenuItem *detailsItem = [HWMConfParticipantActionMenuItem defaultViewDetails];
    detailsItem.delegate = self;
    detailsItem.actionClickEvent = ^(HWMConfCtrlType type, HWMConfParticipant * _Nonnull participant) {
        NSLog(@"处理点击事件");
    };
    /// 以上为查看详情自定义相关

    // 请求主持人
    HWMConfParticipantActionMenuItem *requestChairmanItem = (HWMConfParticipantActionMenuItem *)[HWMConfParticipantActionMenuItem defaultRequestChairmanItem];
    // 释放主持人
    HWMConfParticipantActionMenuItem *releaseChairmanItem = (HWMConfParticipantActionMenuItem *)[HWMConfParticipantActionMenuItem defaultReleaseChairmanItem];
    // 广播会场 or 停止
    HWMConfParticipantActionMenuItem *broadcastItem = (HWMConfParticipantActionMenuItem *)[HWMConfParticipantActionMenuItem defaultBroadcastItem];
    // 静音 or 取消静音
    HWMConfParticipantActionMenuItem *muteItem = (HWMConfParticipantActionMenuItem *)[HWMConfParticipantActionMenuItem defaultMuteItem];
    // 挂断
    HWMConfParticipantActionMenuItem *hangupItem = (HWMConfParticipantActionMenuItem *)[HWMConfParticipantActionMenuItem defaultHangupItem];
    //移除与会者
    HWMConfParticipantActionMenuItem *removeAttendeeItem = (HWMConfParticipantActionMenuItem *)[HWMConfParticipantActionMenuItem defaultRemoveAttendeeItem];
    // 转移主持人
    HWMConfParticipantActionMenuItem *transferItem = (HWMConfParticipantActionMenuItem *)[HWMConfParticipantActionMenuItem defaultTransferChairmanItem];
    // 选看 or 取消选看
    HWMConfParticipantActionMenuItem *watchItem = (HWMConfParticipantActionMenuItem *)[HWMConfParticipantActionMenuItem defaultWatchItem];
    // 举手 or 手放下
    HWMConfParticipantActionMenuItem *handup = (HWMConfParticipantActionMenuItem *)[HWMConfParticipantActionMenuItem defaultHandupItem];
    // 呼叫其他号码
    HWMConfParticipantActionMenuItem *callOtherItem = (HWMConfParticipantActionMenuItem *)[HWMConfParticipantActionMenuItem defaultCallOtherNumberItem];
    // 改名
    HWMConfParticipantActionMenuItem *changeNameItem = (HWMConfParticipantActionMenuItem *)[HWMConfParticipantActionMenuItem defaultChangeNickNameItem];
    // 重呼
    HWMConfParticipantActionMenuItem *recallItem = (HWMConfParticipantActionMenuItem *)[HWMConfParticipantActionMenuItem defaultRecallItem];
    
    return @[releaseChairmanItem, requestChairmanItem, broadcastItem, watchItem, muteItem, transferItem, recallItem, callOtherItem, changeNameItem,    handup, hangupItem, removeAttendeeItem];
}