Skip to content

Commit

Permalink
chore: add a method for debug
Browse files Browse the repository at this point in the history
  • Loading branch information
js-seo authored and parkjurung committed Jan 10, 2025
1 parent 595d28a commit bd2c1c5
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions pagecall/src/main/java/com/pagecall/PagecallWebView.java
Original file line number Diff line number Diff line change
Expand Up @@ -199,6 +199,11 @@ public void loadDataWithBaseURL(@Nullable String baseUrl, @NonNull String data,

private PagecallWebChromeClient webChromeClient;

private void sendChatForDebug(String message) {
String escapedMessage = message.replace("'", "\\'");
this.evaluateJavascriptWithLog("Pagecall.chat.sendMessage('" + escapedMessage + "');");
}

private void updateCommunicationDevice() {
AudioManager audioManager = (AudioManager) context.getSystemService(Context.AUDIO_SERVICE);
List<AudioDeviceInfo> devices = Build.VERSION.SDK_INT >= Build.VERSION_CODES.S ? audioManager.getAvailableCommunicationDevices() : Arrays.asList(audioManager.getDevices(AudioManager.GET_DEVICES_OUTPUTS));
Expand Down

0 comments on commit bd2c1c5

Please sign in to comment.