Help Center> Meeting> Client SDK Reference> Android SDK> API Reference> Basic Settings> Customizing the Panel Used to Share a Meeting
Updated on 2023-03-23 GMT+08:00

Customizing the Panel Used to Share a Meeting

You can customize the panel used to share a meeting in OpenSDKConfig.

Figure 1 displays the sharing effect.

Application Scenarios

On the participant list screen, when a user touches the share button, the sharing panel is displayed. You can customize the style and content of the sharing panel.

Precautions

1. sdkConfig takes effect only when this configuration is passed during SDK initialization.

Figure 1 Sample of a custom panel used to share a meeting

Sample Code

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
// Customize the menu used to share a meeting.
public class CustomShareHandle implements IShareHandle {
    @Override
    public List<IShareModel> buildShareItems(Context context, ConfInfo confInfo, ShareTypeEnum shareTypeEnum) {
        String subject = confInfo.getConfSubject();
        String guestUrl = confInfo.getConfGuestUri();
        String time = DateUtil.getDateTimeStringForUi(confInfo.getConfStartTime(), confInfo.getConfEndTime());
        String chairman = confInfo.getConfScheduserName();
        String confId = confInfo.getConfId();
        String guestPwd = TextUtils.isEmpty(confInfo.getConfPwd()) ? Utils.getApp().getString(com.huawei.hwmmobileconfui.R.string.conf_no_pwd) : confInfo.getConfPwd();
        String content = String.format(Utils.getApp().getString(com.huawei.hwmmobileconfui.R.string.conf_share_content), subject, time, chairman, confId, guestPwd, guestUrl);
        // Set the SMS sharing menu.
        SmsShareModel smsShareModel = new SmsShareModel();
        smsShareModel.setContent(content);
        // Set the copy link.
        CopyShareModel copyShareModel = new CopyShareModel();
        copyShareModel.setContent(content);
        List<IShareModel> shareModels = new ArrayList<>();
        shareModels.add(smsShareModel);
        shareModels.add(copyShareModel);
        return shareModels;
    }
}
sdkConfig.setShareHandle(new CustomShareHandle());