Skip to content

Commit

Permalink
Merge pull request #70 from webex/Release/3.10.0
Browse files Browse the repository at this point in the history
Release/3.10.0
  • Loading branch information
knamoach authored Oct 16, 2023
2 parents c04d1e6 + eee09f9 commit 399013e
Show file tree
Hide file tree
Showing 57 changed files with 1,581 additions and 119 deletions.
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -79,19 +79,19 @@ This demo support Android device with **Android 7.0** or later
- For Full SDK
```
dependencies {
implementation 'com.ciscowebex:webexsdk:3.9.2'
implementation 'com.ciscowebex:webexsdk:3.10.0'
}
```
- For Meeting SDK
```
dependencies {
implementation 'com.ciscowebex:webexsdk-meeting:3.9.2'
implementation 'com.ciscowebex:webexsdk-meeting:3.10.0'
}
```
- For WebexCalling SDK
```
dependencies {
implementation 'com.ciscowebex:webexsdk-wxc:3.9.2'
implementation 'com.ciscowebex:webexsdk-wxc:3.10.0'
}
```
Expand Down
14 changes: 7 additions & 7 deletions app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,8 @@ android {
applicationId "com.cisco.sdk_android"
minSdkVersion Versions.minSdk
targetSdkVersion Versions.targetSdk
versionCode 3090200
versionName "3.9.2"
versionCode 3100000
versionName "3.10.0"

testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"

Expand Down Expand Up @@ -113,11 +113,12 @@ android {
}

dependencies {

//At a time only one WebexSDK should be used.
implementation 'com.ciscowebex:webexsdk:3.10.0' // For full flavor
//implementation 'com.ciscowebex:webexsdk-wxc:3.10.0' //For webexCalling flavor
//implementation 'com.ciscowebex:webexsdk-meeting:3.10.0' // For meeting flavor

// At a time only one WebexSDK should be used.
implementation 'com.ciscowebex:webexsdk:3.9.2' // For full flavor
// implementation 'com.ciscowebex:webexsdk-wxc:3.9.2' //For webexCalling flavor
//implementation 'com.ciscowebex:webexsdk-meeting:3.9.2' // For meeting flavor
implementation fileTree(dir: "libs", include: ["*.jar"])
implementation Dependencies.kotlinStdLib
implementation Dependencies.coreKtx
Expand Down Expand Up @@ -155,5 +156,4 @@ dependencies {
implementation Dependencies.firebaseCrashlytics
implementation Dependencies.gson
implementation Dependencies.glide

}
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ import androidx.annotation.StringRes
import androidx.lifecycle.Lifecycle
import androidx.recyclerview.widget.RecyclerView
import androidx.test.espresso.Espresso.onView
import androidx.test.espresso.Espresso.closeSoftKeyboard
import androidx.test.espresso.PerformException
import androidx.test.espresso.UiController
import androidx.test.espresso.ViewAction
Expand Down
16 changes: 10 additions & 6 deletions app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -76,8 +76,7 @@
android:name=".calling.LockScreenActivity"
android:showOnLockScreen="true"
android:showWhenLocked="true"
android:turnScreenOn="true"
/>
android:turnScreenOn="true" />

<service
android:name=".CallRejectService"
Expand Down Expand Up @@ -138,13 +137,13 @@
<activity
android:name=".calling.CallActivity"
android:configChanges="orientation|screenSize|screenLayout|keyboardHidden|smallestScreenSize"
android:exported="true"
android:launchMode="singleTask"
android:resizeableActivity="true"
android:showOnLockScreen="true"
android:showWhenLocked="true"
android:supportsPictureInPicture="true"
android:turnScreenOn="true"
android:exported="true"
tools:ignore="UnusedAttribute" />
<activity
android:name=".search.SearchActivity"
Expand Down Expand Up @@ -182,6 +181,12 @@
<activity
android:name=".calling.CucmCallActivity"
android:screenOrientation="portrait" />
<activity
android:name=".calling.captions.ClosedCaptionsActivity"
android:screenOrientation="portrait" />
<activity
android:name=".calling.captions.ClosedCaptionsLanguageActivity"
android:screenOrientation="portrait" />

<service
android:name=".firebase.KitchenSinkFCMService"
Expand All @@ -204,9 +209,8 @@
android:name="com.google.firebase.messaging.default_notification_channel_id"
android:value="@string/default_notification_channel_id" />
<meta-data
android:name="android.content.APP_RESTRICTIONS"
android:resource="@xml/app_restrictions" />

android:name="android.content.APP_RESTRICTIONS"
android:resource="@xml/app_restrictions" />
</application>

</manifest>
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,18 @@ import com.ciscowebex.androidsdk.membership.Membership
import com.ciscowebex.androidsdk.membership.MembershipObserver
import com.ciscowebex.androidsdk.message.LocalFile
import com.ciscowebex.androidsdk.message.MessageObserver
import com.ciscowebex.androidsdk.phone.*
import com.ciscowebex.androidsdk.phone.Breakout
import com.ciscowebex.androidsdk.phone.BreakoutSession
import com.ciscowebex.androidsdk.phone.Call
import com.ciscowebex.androidsdk.phone.CallMembership
import com.ciscowebex.androidsdk.phone.MediaOption
import com.ciscowebex.androidsdk.phone.Phone
import com.ciscowebex.androidsdk.phone.VirtualBackground
import com.ciscowebex.androidsdk.phone.CallObserver
import com.ciscowebex.androidsdk.phone.NotificationCallType
import com.ciscowebex.androidsdk.phone.ReceivingNoiseInfo
import com.ciscowebex.androidsdk.phone.closedCaptions.CaptionItem
import com.ciscowebex.androidsdk.phone.closedCaptions.ClosedCaptionsInfo
import com.ciscowebex.androidsdk.space.SpaceObserver
import java.io.PrintWriter

Expand Down Expand Up @@ -660,6 +671,24 @@ class WebexRepository(val webex: Webex) : WebexUCLoginDelegate {
}
}
}

override fun onClosedCaptionsArrived(closedCaptions: CaptionItem) {
val observers: MutableList<CallObserver>? = _callObservers[_callId]
observers?.let { it ->
it.forEach { observer ->
observer.onClosedCaptionsArrived(closedCaptions)
}
}
}

override fun onClosedCaptionsInfoChanged(closedCaptionsInfo: ClosedCaptionsInfo) {
val observers: MutableList<CallObserver>? = _callObservers[_callId]
observers?.let { it ->
it.forEach { observer ->
observer.onClosedCaptionsInfoChanged(closedCaptionsInfo)
}
}
}
}

private fun registerCallObserver(call: Call) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,10 @@ import org.json.JSONObject
import com.ciscowebex.androidsdk.auth.PhoneServiceRegistrationFailureReason
import com.ciscowebex.androidsdk.auth.TokenAuthenticator
import com.ciscowebex.androidsdk.auth.UCLoginServerConnectionStatus
import com.ciscowebex.androidsdk.internal.ResultImpl
import com.ciscowebex.androidsdk.kitchensink.calling.CallObserverInterface
import com.ciscowebex.androidsdk.kitchensink.utils.CallObjectStorage
import com.ciscowebex.androidsdk.kitchensink.utils.Constants
import com.ciscowebex.androidsdk.message.LocalFile
import com.ciscowebex.androidsdk.phone.ShareConfig
import com.ciscowebex.androidsdk.phone.BreakoutSession.BreakoutSessionError
Expand All @@ -45,6 +47,8 @@ import com.ciscowebex.androidsdk.phone.SwitchToAudioVideoCallResult
import com.ciscowebex.androidsdk.phone.PhoneConnectionResult
import com.ciscowebex.androidsdk.phone.ReceivingNoiseInfo
import com.ciscowebex.androidsdk.phone.ReceivingNoiseRemovalEnableResult
import com.ciscowebex.androidsdk.phone.closedCaptions.CaptionItem
import com.ciscowebex.androidsdk.phone.closedCaptions.ClosedCaptionsInfo
import com.google.firebase.installations.FirebaseInstallations
import java.io.PrintWriter

Expand Down Expand Up @@ -541,6 +545,14 @@ class WebexViewModel(val webex: Webex, val repository: WebexRepository) : BaseVi
override fun onReceivingNoiseInfoChanged(info: ReceivingNoiseInfo) {
callObserverInterface?.onReceivingNoiseInfoChanged(info)
}

override fun onClosedCaptionsArrived(closedCaptions: CaptionItem) {
callObserverInterface?.onClosedCaptionsArrived(closedCaptions)
}

override fun onClosedCaptionsInfoChanged(closedCaptionsInfo: ClosedCaptionsInfo) {
callObserverInterface?.onClosedCaptionsInfoChanged(closedCaptionsInfo)
}
}

val callObserverMap : HashMap<String, VMCallObserver> = HashMap()
Expand Down Expand Up @@ -756,7 +768,7 @@ class WebexViewModel(val webex: Webex, val repository: WebexRepository) : BaseVi

fun setPushTokens(id: String, token: String){
if(BuildConfig.WEBHOOK_URL.isEmpty()) {
webex.phone.setPushTokens(KitchenSinkApp.applicationContext().packageName, id, token)
webex.phone.setPushTokens(KitchenSinkApp.applicationContext().packageName, id, token, Constants.Keys.appId)
}
}

Expand Down Expand Up @@ -857,8 +869,20 @@ class WebexViewModel(val webex: Webex, val repository: WebexRepository) : BaseVi
?.getValue() as Boolean?
}

fun switchAudioMode(mode: Call.AudioOutputMode) {
getCall(currentCallId.orEmpty())?.switchAudioOutput(mode)
fun switchAudioMode(mode: Call.AudioOutputMode, handler: CompletionHandler<Boolean>) {
getCall(currentCallId.orEmpty())?.switchAudioOutput(mode) { result ->
if (result.data == false) {
Log.d(tag, "ATSDK Error: Switch mode to ${mode.name} failed")
handler.onComplete(ResultImpl.success(false))
} else {
Log.d(tag, "ATSDK Switch mode to ${mode.name} success")
handler.onComplete(ResultImpl.success(true))
}
}
}

fun getCurrentAudioOutputMode(): Call.AudioOutputMode? {
return getCall(currentCallId.orEmpty())?.getCurrentAudioOutput()
}

fun enableAudioBNR(value: Boolean) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,8 @@ import com.ciscowebex.androidsdk.kitchensink.databinding.ActivityCallBinding
import com.ciscowebex.androidsdk.kitchensink.utils.CallObjectStorage
import com.ciscowebex.androidsdk.kitchensink.utils.Constants
import com.ciscowebex.androidsdk.phone.*
import com.ciscowebex.androidsdk.phone.closedCaptions.CaptionItem
import com.ciscowebex.androidsdk.phone.closedCaptions.ClosedCaptionsInfo
import com.google.android.material.bottomsheet.BottomSheetDialogFragment


Expand Down Expand Up @@ -459,6 +461,14 @@ class CallActivity : BaseActivity(), CallControlsFragment.OnCallActionListener,
TODO("Not yet implemented")
}

override fun onClosedCaptionsArrived(closedCaptions: CaptionItem) {
TODO("Not yet implemented")
}

override fun onClosedCaptionsInfoChanged(closedCaptionsInfo: ClosedCaptionsInfo) {
TODO("Not yet implemented")
}

override fun finish() {
if(calls.size > 0){
//Resume a queued call
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,8 @@ class CallBottomSheetFragment(val showIncomingCallsClickListener: (Call?) -> Uni
val cameraOptionsClickListener: (Call?) -> Unit,
val multiStreamOptionsClickListener: (Call?) -> Unit,
val sendDTMFClickListener: (Call?) -> Unit,
val showBreakoutSessions: () -> Unit): BottomSheetDialogFragment() {
val showBreakoutSessions: () -> Unit,
val closedCaptionOptions: (Call?) -> Unit): BottomSheetDialogFragment() {
companion object {
val TAG = "CallBottomSheetFragment"
}
Expand Down Expand Up @@ -215,6 +216,11 @@ class CallBottomSheetFragment(val showIncomingCallsClickListener: (Call?) -> Uni
showBreakoutSessions()
}

closedCaptionOptions.setOnClickListener {
dismiss()
closedCaptionOptions(call)
}

cancel.setOnClickListener { dismiss() }
}.root
}
Expand Down
Loading

0 comments on commit 399013e

Please sign in to comment.