The Demo App
The demo app shows usage examples for the most part of the functionality provided in
FlussonicThumbnailView components (please refer here for details on those components). The demo app is in Java.
You can download the demo app project and build it on your computer to test the SDK functionality and experiment with certain functions:
- Download and install the last version of Android Studio from the official website.
- Run Android Studio.
- Configure environment as described in this guide. You need info from "Android development environment" section for your operating system.
If you plan to test the demo application on a virtual device, create an Android Virtual Device (AVD) in Android Studio as described in the same guide under "Using a virtual device" section.
Make sure to select the latest available version of API. However, if demo app will not start with the selected version, try selecting other versions.
Download the demo app for Android. You can download the demo app project by direct link or find it on GitHub at the same link as the whole Android SDK.
- Open the demo app project in Android Studio. All the necessary dependencies, Gradle script settings and modules are already configured in the demo app project, so no additional settings are required, i.e. you do not have to follow the instructions in the readme file.
Select the AVD you've created earlier and the app project, click the Play button to launch the app.
As a result, you will see a demo app in the virtual machine to test its functionality.
build.gradle script contains the parameters for connection to a test Watcher server with cameras:
buildConfigField "String", "SERVER", getCredentials("SERVER", "\"https://cloud.vsaas.io\"") buildConfigField "String", "LOGIN", getCredentials("LOGIN", "\"demo\"") buildConfigField "String", "PASSWORD", getCredentials("PASSWORD", "\"demo\"")
data.network contains the API for authorization and getting the list of cameras.
presentation.camera_list contain usage examples of
FlussonicThumbnailView components, wiht comments.
Pay special attention to the methods:
CameraActivity#setupWatcher(about setting up
CameraActivity#onOptionsItemSelected(about the use of