Commit Graph

104 Commits

Author SHA1 Message Date
Saúl Ibarra Corretgé 90e4291751 [iOS] Update Podfile.lock 2017-11-21 11:46:35 +01:00
Lyubo Marinov 713700456e [iOS] Configuration-specific AppIcons
While having configuration-specific AppIcons may be of questionable use,
I'm more interested in using the Debug version for enterprise
distribution and the Release version for AppStore distribution.
2017-11-15 16:07:36 -06:00
Saúl Ibarra Corretgé f973a695d8 [RN] Add audio route picker
Due to the difference in nature, the iOS and Android implementations are
completely different:

iOS: MPVolumeView is used, which allows us to place a button which will launch a
native route picker provided by iOS itself. This view is different depending on
the iOS version, with the iOS 11 version being more complete.

Android: A completely custom component is used, which displays a bottom sheet
with the device categories, not devices individually. This is akin to the sheet
in the builtin dialer.
2017-11-15 09:31:40 -06:00
Lyubo Marinov fc3bc21eea [RN] Reproducible (CocoaPods) builds
Now that we have package-log.json for the sake of reproducible builds,
we should lock CocoaPods as well.
2017-11-15 09:25:56 -06:00
paweldomas cbd2bb0140 fix(JitsiMeetView): fix rotation on iOS
The root view was not adjusting it's bounds after device rotation.
2017-11-02 14:32:35 +01:00
paweldomas b74bede0e7 feat(web/RN): update React to v16 and React Native to 0.49 2017-11-02 14:32:35 +01:00
Saúl Ibarra Corretgé b4b2d6f630 [iOS] Remove unneeded imports 2017-10-30 14:06:20 +01:00
Saúl Ibarra Corretgé 84fd7825c1 [iOS] Import React headers in a consistent way 2017-10-25 14:53:45 -05:00
Lyubo Marinov af53a5c48c [iOS] Fix iOS 9 after CallKit
Revert "[RN] Remove unnecessary source code" (commit
a3441030a3). But since the project file
needs to explicitly mention the CallKit and Intents framework, do not
use the semantic @import as that's confusing in the case.
2017-10-11 12:20:11 -05:00
Saúl Ibarra Corretgé 20a6a61b45 [iOS] Add icon for CallKit in-call UI 2017-10-11 09:15:44 -05:00
Saúl Ibarra Corretgé 8e59660f33 [iOS] Update Xcode project file
CocoaPods has made some updates to the bundled resource files.
2017-10-09 15:38:31 -05:00
Lyubo Marinov 4bf19d73fd [RN] Fix documentation comments
* Javadoc introduced @code as a replacement of <code> and <tt> which is
  better aligned with other javadoc tags such as @link. Use it in the
  Java source code. If we switch to Kotlin, then we'll definitely use
  Markdown.

* There are more uses of @code in the JavaScript source code than <tt>
  so use @code for the sake of consistency. Eventually, I'd rather we
  switch to Markdown because it's easier on my eyes.

* Xcode is plain confused by @code and @link. The Internet says that
  Xcode supports the backquote character to denote the beginning and end
  of a string of characters which should be formatted for display as
  code but it doesn't work for me. <tt> is not rendered at all. So use
  the backquote which is rendered itself. Hopefully, if we switch to
  Markdown, then it'll be common between JavaScript and Objective-C
  source code.
2017-10-01 01:35:19 -05:00
Lyubo Marinov a3441030a3 [RN] Remove unnecessary source code 2017-09-29 12:43:42 -05:00
Lyubo Marinov 3b5ee2d4c6 [iOS] Add initial CallKit support 2017-09-29 12:00:13 -05:00
Saúl Ibarra Corretgé 8d11b3024e [iOS] Add initial CallKit support
This commit adds initial support for CallKit on supported platforms: iOS >= 10.

Since the call flow in Jitsi Meet is basically making outgoing calls, only
outgoing call support is currently handled via CallKit.

Features:
 - "Green bar" when in a call.
 - Native CallKit view when tapping on the call label on the lock screen.
 - Support for audio muting from the native CallKit view.
 - Support for recent calls (audio-only calls logged as Audio calls, others show
   as Video calls).
 - Call display name is room name.
 - Graceful downgrade on systems without CallKit support.

Limitations:
 - Native CallKit view cannot be shown for audio-only calls (this is a CallKit
   limitaion).
 - The video button in the CallKit view will start a new video call to the same
   room, and terminate the previous one.
 - No support for call hold.
2017-09-28 16:36:39 -05:00
Lyubo Marinov e1222e947b [RN] Documentation, comments 2017-09-27 13:08:37 -05:00
Saúl Ibarra Corretgé 341e7e01aa [RN] Add the ability to set the default URL in the SDK 2017-09-27 11:59:00 -05:00
Lyubo Marinov b55faab33e Coding style 2017-09-27 11:01:27 -05:00
Saúl Ibarra Corretgé 3fdffa7497 [RN] Add AppInfo module
It provides access to the app's display name and version.
2017-09-27 10:32:07 -05:00
Lyubo Marinov 72c9933e73 [RN] SDK building, installing, and publishing
Based on work authored by Shuai Li <sli@atlassian.com>, Daniel Ornelas
<dornelas@atlassian.com>, and Lyubo Marinov <lmarinov@atlassian.com>.
2017-09-11 20:12:56 -05:00
Lyubo Marinov fce0e4c22c [RN] Report loadConfigError with locationURL to the SDK consumers 2017-09-06 20:34:46 -05:00
Lyubo Marinov 4dc78ce458 [RN] Increase the coverage of JitsiMeetViewListener
JitsiMeetViewListener is an integral part of the public API of Jitsi
Meet SDK for Android. Utilize it in the Debug configuration of the Jitsi
Meet app for Android in order to increase (1) awareness of API breakages
and (2) API coverage.

The same goes for JitsiMeetViewDelegate in Jitsi Meet SDK and app for
iOS.
2017-09-06 16:31:15 -05:00
Lyubo Marinov 67edaac1c9 [RN] Coding style 2017-09-06 16:31:15 -05:00
Lyubo Marinov e830b80b6b [RN] Fix documentation 2017-09-06 16:31:15 -05:00
Saúl Ibarra Corretgé 284e4e543e [RN] Detect errors when loading the configuration
The error is stored in the redux store in base/config so other components can
consult it. It is also broadcasted as a new event in the external API for the
SDK.
2017-09-06 16:31:14 -05:00
Lyubo Marinov 1d8ee9d32f [RN] Reduce maintenance
JitsiMeetViewListener currently has methods of one and the same pattern
so adding new methods i.e. events i.e. redux action types is a question
of repetition in the Java source code. Speed up the support of new
events by trying to deal with them in a generic way.

The same goes for JitsiMeetViewDelegate.
2017-09-06 15:57:00 -05:00
Lyubo Marinov 6003b560ae [RN] Fix opening the same URL multiple times
Deep/universal linking now utilizes loadURL (when possible). But loadURL
is imperative in the native source code while its JavaScript counterpart
i.e. React App Component prop url is declarative. So there's the
following bug: open a URL, leave the conference (by tapping the hangup
button, for example), and then opening the same URL actually leaves you
on the Welcome page (if enabled; otherwise, a black screen).

The implementation has a flow though: opening the same URL twice in a
row without an intervening leave will leave the first opening and join
the new opening. Which can be improved by not leaving and joining if the
conference is joined, joining, an not leaving. But that can be done
separately as an improvement independent of the current implementation
details.
2017-08-15 17:32:37 -05:00
Lyubo Marinov 207393d98e [RN] Coding style 2017-08-15 17:32:37 -05:00
Saúl Ibarra Corretgé 122ebe48c7 [RN] Cache avatars and provide a default in case load fails
Avatars are cached to the filesystem and loaded from there when requested again.
The cache is cleaned after a conference ends and on application startup
(defensive move).

In addition, implement a fully local avatar system, which is used as a fallback
when loading a remote avatar fails. It can also be forced using a prop.

The fully local avatars use a user icon as a mask and apply a background color
qhich is picked by hashing the URI passed to the avatar. If no URI is passed a
random color is chosen.

A grace period of 1 second is also implemented so a default local avatar will be
rendered if an Avatar component is mounted but has no URI. If a URI is specified
later on, it will be loaded and displayed. In case loading the remote avatar
fails, the locally generated one will be used.
2017-08-03 13:45:41 -05:00
Lyubo Marinov 1ad8436cb5 [Android] Use loadURL in the app 2017-08-01 12:07:22 -05:00
Lyubo Marinov 6b2a93909b [iOS] Use loadURL in the app 2017-08-01 06:31:03 -05:00
Saúl Ibarra Corretgé aaf5dd75fa [iOS] Fix loading initial URL when app is closed
We must not pass nil as the URL, that will translate to null and we won't be
able to load the initial URL which is passed as the launch parameters.
2017-07-28 09:18:35 -05:00
Saúl Ibarra Corretgé 1fb31b6773 [iOS] Fix crash when a nil URL is loaded
NSDictionary doesn't support nil values, they must be objects, so use NSNull
instead, which is the kosher way to do it.
2017-07-27 11:33:56 +02:00
Lyubo Marinov 9871580e6d [iOS] Completeness (maybe) 2017-07-26 15:54:58 -05:00
Lyubo Marinov 3546cf4915 Fixes jsdocs, formatting 2017-07-26 15:54:57 -05:00
Lyubo Marinov a2c2d3bee1 [RN] Alternative to JitsiMeetView.loadURL w/o URL
Introduces loadURLObject in JitsiMeetView on Android and iOS which
accepts a Bundle and NSDictionary, respectively, similar in structure to
the JS object accepted by the constructor of Web's ExternalAPI. At this
time, only the property url of the bundle/dictionary is supported.
However, it allows the public API of loadURLObject to be consumed. The
property url will be made optional in the future and other properties
will be supported from which a URL will be constructed.
2017-07-26 15:53:35 -05:00
Lyubo Marinov f0ab835b46 [RN] Add loadURLString to JitsiMeetView
Initializing a new URL/NSURL instance is a chore especially when one
takes into account that the JavaScript side (1) is loading the URL
asynchronously and (2) is capable of parsing strings that may or may not
be represented as URL/NSURL.

The Android method loadURLString(String) may have been called
loadURL(String) to overload loadURL(URL) but I didn't want to do that
because:

1. It would not be compatible with existing source code such as
loadURL(null) which would have become ambiguous.

2. I wanted to achieve better convergence with the iOS API.
2017-07-25 19:07:01 -05:00
Saúl Ibarra Corretgé 99b856233d [iOS] Fix joining initial URL if app was closed
On iOS, if the app is closed the startup options are only passed as the
`launchOptions` dictionary of `applicationDidFinishLaunching`. Thus add a helper
method to be called from there by embedding applications so we can copy that
dictionary.
2017-07-07 08:57:49 -05:00
Saúl Ibarra Corretgé 82e10e1a00 [iOS] Don't bring the packager to the foreground upon launch 2017-07-06 14:07:20 +02:00
Daniel Ornelas 8a01067b62 Added post-script to the Release configuraiton to build iOS SDK as Universal framework 2017-06-23 19:39:53 -05:00
Daniel Ornelas 7c2d59033b Fixed nullable pointer warnings in iOS SDK 2017-06-23 19:39:41 -05:00
Saúl Ibarra Corretgé be30dd09e9 [iOS] Add scheme for building only the SDK 2017-06-19 16:08:30 -05:00
Saúl Ibarra Corretgé d7818be067 [iOS] Link with WebRTC.framework at the top level
Before, Jitsi Meet (the app) would only link with JitsiMeet.framework, which in
turn embedded WebRTC.framework. While possible, Apple doesn't allow apps with
nested frameworks to be submitted to the store. Now the app will link with
WebRTC.framework directly so there is no framework nesting.

A potential improvement here is to build WebRTC as a static library so it can
then be embedded in JitsiMeet.framework and completely hidden from the app.
2017-06-19 11:03:13 -05:00
Saúl Ibarra Corretgé 2db574810b [RN] Fix target reference in iOS scheme 2017-06-15 09:51:04 -05:00
Lyubo Marinov 4b2add7aa6 [Android] Allow multiple JitsiMeetViews 2017-06-10 03:34:11 -05:00
Lyubo Marinov 10e5e0fdf5 [iOS] Allow multiple JitsiMeetViews 2017-06-09 19:17:01 -05:00
Lyubo Marinov 5f64ccb97d [RN] Naming 2017-06-09 14:51:31 -05:00
Saúl Ibarra Corretgé 4687c1f465 [RN] Add ability to skip the welcome page
Also expose this in the native SDKs.
2017-06-09 14:10:10 -05:00
Lyubo Marinov 90466183d6 [RN] Consistency in Jitsi Meet SDK for Android 2017-06-09 00:03:23 -05:00
Saúl Ibarra Corretgé a075f24000 [RN] Add conference events to native SDKs
The current implementation doesn't use the API and Transport modules. This is
due to the fact that they are too tied to APP at the moment, which is web only.

Once API is refactored and moved into the Redux store this will be adjusted,
though it's unlikely that the lowest level React Native module (ExternalAPI)
changes drastically.

This commit also introduces a stopgap limitation of only allowing a single
instance for JitsiMeetView objects on both Android and iOS. React Native doesn't
really play well with having multiple instances of the same modules on the same
bridge, since they behave a bit like singletons. Even if we were to use multiple
bridges, some features depend on system-level global state, such as the
AVAudioSession mode or Android's immersive mode. Further attempts will be made
at lifting this limitation in the future, though.
2017-06-09 00:03:23 -05:00