To build DpadDemo sources you will need to:
- Download android sdk from https://developer.android.com/sdk/installing/index.html?pkg=tools
- Set ANDROID_HOME to the path of Android sdk folder
- Open Android SDK manager and install
- Tools/Android SDK Build-tools 23.0.3
- Android 6.0 (API 23)
- Extras/Android Support Repository
- Extras/Google Repository
DpadDemo uses gradle as build system. Here are commands to build and install the project from command line:
- Assemble only debug apk: ./gradlew assembleDebug
- Install debug apk on connected device: ./gradlew installDebug
Devices having D-pad are not common these days so to test this project on emulator you will need to do the following:
- Run the app and you get to see 'Select Deployment Target' dialog.
- Click 'Create New Emulator' then select a device and click 'Clone Device'
- On the 'Hardware Profile Configuration' window check both the checkboxes in 'Input' row and the select 'D-pad' from 'Navigation Style' dropdown.
- Click 'Finish' and you are done.
- When emulator opens up, you can click more options and go to Directional pad tab to use it.