Beth_Chen
(Beth Chen)
November 27, 2017, 5:09pm
1
Following SDK example2, I have a CustomMeetingActivity class.
It is defined in the config.xml as
\<resources\>
\<string name="zm\_config\_conf\_activity"\>com.xyz.ui.CustomMeetingActivity\</string\>
\</resources\>
And also in Manifest.xml
But when join the meeting, my CustomMeetingActivity, getLayout() is never called.
Would appreciate any help on how to load my custom layout.
Jacky_Du
(Jacky Du)
November 28, 2017, 1:28am
2
Hi Beth,
Could you also provide the code snippet of activity defination in your manifest and CustomMeestingActivity class implemetion. So that we can check what’s going on there.
Thanks.
Beth_Chen
(Beth Chen)
November 28, 2017, 4:24pm
3
In Manifest.xml I added this activity.
\<activity
android:name="com.xyz.ui.CustomMeetingActivity"
android:configChanges="orientation|screenSize"
android:hardwareAccelerated="false"
android:theme="@style/ZMTheme.SubWindow"
android:process=":zoom\_meeting"
android:screenOrientation="landscape" /\>
The CustomMeetingActivity class were mostly copy from example
public class CustomMeetingActivity extends MeetingActivity {
private Button btnLeaveZoomMeeting;
private Button btnSwitchToNextCamera;
private Button btnAudio;
private Button btnParticipants;
private Button btnShare;
private Button btnStopShare;
private Button btnMoreOptions;
@Override
protected int getLayout() {
return R.layout.activity\_custom\_av\_meeting;
}
@Override
protected boolean isAlwaysFullScreen() {
return false;
}
@Override
protected boolean isSensorOrientationEnabled() {
return false;
}
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
disableFullScreenMode();
}
@Override
public void onConfigurationChanged (Configuration newConfig) {
super.onConfigurationChanged(newConfig);
disableFullScreenMode();
}
private void disableFullScreenMode() {
getWindow().setFlags(~WindowManager.LayoutParams.FLAG\_FULLSCREEN, WindowManager.LayoutParams.FLAG\_FULLSCREEN);
}
@Override
public void onBackPressed() {
if ( getFragmentManager().getBackStackEntryCount() \> 0)
{
getFragmentManager().popBackStack();
return;
}
super.onBackPressed();
}
@Override
protected void onResume() {
super.onResume();
// disable animation
overridePendingTransition(0, 0);
}
// @Override
// protected void onMeetingConnected() {
// updateButtonsStatus();
// }
//
// @Override
// protected void onSilentModeChanged(boolean inSilentMode) {
// updateButtonsStatus();
// }
//
// @Override
// protected void onStartShare() {
// btnShare.setVisibility(View.GONE);
// btnStopShare.setVisibility(View.VISIBLE);
// }
//
// @Override
// protected void onStopShare() {
// btnShare.setVisibility(View.VISIBLE);
// btnStopShare.setVisibility(View.GONE);
// }
//
// private void updateButtonsStatus() {
//
// boolean enabled = (isMeetingConnected() && !isInSilentMode());
//
// btnSwitchToNextCamera.setEnabled(enabled);
// btnAudio.setEnabled(enabled);
// btnParticipants.setEnabled(enabled);
// btnShare.setEnabled(enabled);
// btnMoreOptions.setEnabled(enabled);
//
// if(isSharingOut()) {
// btnShare.setVisibility(View.GONE);
// btnStopShare.setVisibility(View.VISIBLE);
// } else {
// btnShare.setVisibility(View.VISIBLE);
// btnStopShare.setVisibility(View.GONE);
// }
// }
}
Beth_Chen
(Beth Chen)
November 28, 2017, 4:32pm
4
The av meeting is launched from a fragment. The meeting starts successfully but the CustomMeetingActivity is not called.
public class AudioVideoMeetingFragment extends AbstractFragment implements ZoomSDKInitializeListener, MeetingServiceListener, View.OnClickListener, AppAVMeetingService.AudioVideoMeetingListener {
public void onClickBtnJoinMeeting() {
ZoomSDK zoomSDK = ZoomSDK.getInstance();
if (!zoomSDK.isInitialized()) {
AppLogger.trace("ZoomSDK has not been initialized successfully");
return;
}
MeetingService meetingService = zoomSDK.getMeetingService();
JoinMeetingOptions opts = new JoinMeetingOptions();
// opts.no\_driving\_mode = true;
// opts.no\_invite = true;
// opts.no\_meeting\_end\_message = true;
// opts.no\_titlebar = true;
// opts.no\_bottom\_toolbar = true;
// opts.no\_dial\_in\_via\_phone = true;
// opts.no\_dial\_out\_to\_phone = true;
// opts.no\_disconnect\_audio = true;
// opts.no\_share = true;
// opts.invite\_options = InviteOptions.INVITE\_VIA\_EMAIL + InviteOptions.INVITE\_VIA\_SMS;
// opts.meeting\_views\_options = MeetingViewsOptions.NO\_BUTTON\_SHARE;
// opts.no\_audio = true;
// opts.no\_video = true;
// opts.no\_meeting\_error\_message = true;
// opts.participant\_id = "participant id";
int ret = meetingService.joinMeeting( getApplicationContext(), String.valueOf(mSpaceMeeting.getId()), mCurrentUserDisplayName, "", opts);
}
}
Jacky_Du
(Jacky Du)
November 29, 2017, 1:34am
5
Hi Beth,
Your activity defination and configuration are all right. It is very strange why the function does not work. Could you please try to run our sdk demo(example2) and try to modify the activity class name/package name. Then, check if can this issue reproduce on sdk demo project.
Thanks.
Beth_Chen
(Beth Chen)
December 8, 2017, 7:55pm
6
I am back to continue on getting the custom UI working.
I am not sure what your last suggestion is. Example2 works fine. But when I added CustomMeetingActivity to my app it does not work.
Please confirm the steps to add Custom activity.
add resource to config.xml under Values
<resources>
<string name=“zm_config_conf_activity”>com.xyz.ui.CustomMeetingActivity</string>
</resources>
Define the activity in Manifest.xml file
<activity
android:name=“com.xyz.ui.CustomMeetingActivity”
android:configChanges=“orientation|screenSize”
android:hardwareAccelerated=“false”
android:theme="@style /ZMTheme.SubWindow"
android:process=":zoom_meeting"
android:screenOrientation=“landscape” />
When these two are in place, the CustomMeetingActivity.getLayout() should be called on start or join meeting.
One thing that my program is different from the exampl2 is that the joinMeeting is called from a fragment which started from the Main activity. The Audio Video meeting starts fine, just not loading my custom meeting layout.
Jacky_Du
(Jacky Du)
December 11, 2017, 1:16am
7
Hi Beth,
Did you define the “zm_config_conf_activity” in your App main project so that it can override the default value in zoom sdk aar package?
Beth_Chen
(Beth Chen)
December 11, 2017, 4:58pm
8
Hi Jacky
I don’t quite understand your question. My previous post listed the steps I took to add CustomMeetingActivity. What am I missing?
“Define the “zm_config_conf_acitity” in my App main project?” Are you asking if I have CustomMeetingActivity.java class in my package? The answer is yes
-Beth
Jacky_Du
(Jacky Du)
December 12, 2017, 1:32am
9
Hi Beth,
You should confirm that the string zm_config_conf_activity (you defined in your string resource) can override the default value in zoom sdk.
Please try to print the string value of zm_config_conf_activity in your code and check if the value is same as you have defined (
<string name=“zm_config_conf_activity”>com.xyz.ui.CustomMeetingActivity</string>)
Thanks
Beth_Chen
(Beth Chen)
December 12, 2017, 3:44pm
10
I printed my whole CustomMeetingActivity 14 days ago. Is there something else you are looking for that’s missing?
Beth_Chen
(Beth Chen)
December 12, 2017, 4:06pm
11
It is working now that when I move the CustomMeetingActivity to be in the same package level as my Main activity instead of in the com.xyz.ui package.
Thanks for your help.
Hi @Jacky_Du ,
we are using Zoom SDK, Actually, we’ve faced the same issue that faced Mr.Betth_Chen.
we’re read your discussion, and we checked all the steps that you are mentioned during your discussion, and I found that we have already added them to our project.
we using Ionic, so due to the limitation of Ionic, our requirement is hard to meet with your Ionic SDK. So we go to using Custom UI as your SDK demo(sample 2).
What happened with us is that we are getting notification Meeting in progress
but Custom Meeting UI is not been called.
We will be grateful for you to have a support
Thanks in advance
jon.zoom
(Jon)
February 16, 2021, 5:11pm
13
Hi @rana.al.huniess , thanks for using our SDK.
Since you are using a custom meeting UI, you are solely responsible for the meeting UI. This means that you will need to respond to the meeting status notification and create the meeting UI yourself.
Thanks!