processing-android
processing-android copied to clipboard
Revamping AndroidSDK installer/Updater and Emulator UX
I wanted to talk about the current user experience(UX). When milestone 1 and 2 are done, we will have a revamped version of the SDK installer, SDK updater and the emulator installer/manager. I don't expect the SDK updater will change the current UX beside the discussed features to update individual components. On the other hand, the installer and emulator will introduce a new layer to the UX that will need to be discussed and properly defined.
Let me describe the current experience.
- [L1] The user using the PDE switches into Android Mode
- [L2] If the Android SDK is not detected, it will display a dialog box asking to do either an "automatic install"(a) of the Android SDK or "provide the SDK path"(b) if the Android SDK is already installed in the local computer.
- [L3] The manual install (b) provides a file selector dialog box where the user provides the path for the Android SDK
- [L4] An automatic install will download and setup the AndroidSDK in Processing's sketchbook folder (Fix location)
- [L5] If the user selects manual install (b) and quits or does not provide a valid path, there is a message displaying "The Android mode has been disabled" and the installation fails.
- [L6] If the user runs an app in disabled Android mode either by pressing run or by running on an emulator, he/she will get an error in the PDE's console.
- [L7] If the Android SDK path is provided in (b), then it is my understanding that the emulator device is neither downloaded not installed (?) (Intended behavior?).
- [L8] To verify: Would launching the app on the emulator in the PDE trigger the installation of the (default) emulator device?
- [L9] If automatic install (a) is selected, then I believe the Android SDK is installed together with the emulator. In other words, this is an automated process with minimum user intervention and therefore, perfect for new users.
- [L10] Note the Android SDK installer does not overlap with the Android Mode install in the Processing IDE. In other words, when the user is running PDE in Java Mode and he/she wishes to use the AM, he will need to install it first via the Contribution Manager >> Mode. After the AM is installed, then the user will be prompted to install the AndroidSDK. ([This need to be verified that this is the intended behavior]
After miletose 1+2 are completed, the new UX will be along the next lines:
- [L101] AndroidSDK installer will show up when the user selects the AM in the PDE and PDE fails to locate the AndroidSDK files.
- [L102] New feature: The installer provides a button in the installer message dialog allowing people to choose a folder where to install the AndroidSDK in case of automatic install (a). As default folder input, this File Selector should indicate the path to the sketchbook folder.
- [L103] Should the user also use this Folder Selector window to indicate the path of the AndroidSDK (b) in case if it was previously installed?
- [L104] In case of auto-install, then this will also install the default emulator.
- [L105] Should this previous point be the intended behavior?
- [L106] Note that there is not AndroidSDK install option available in the PDE menu.
- [L107] Any updates for the AndroidSDK would be managed by using the revamped SDK installer.
- [L108] Now the emulator: Installing a new emulator device should be done through the Emulator viewer/installer. This would be triggered from the PDE menu, probably under the Android menu title.
- [L109] The emulator window option dialog box should be available only after an Android SDK has been successfully installed (?).
- [L110] There is a variable called ANDROID_AVD_HOME where indicates where to find currently installed emulators. This could be another File Selector to allow users to indicate where the emulators should be installed (To be discussed)
- [L111] The menu in the PDE should display all the available emulators and the user should be able to select any of them to launch their sketch.
- [L112] Stopping the emulator should not affect the PDE
- [L113] The PDE could fire multiple devices. How to manage them?
- [L114] Need to handle cases when the android mode is disabled for the PDE and the user attempts to launch a sketch on an Emulator or any new device. Should these operations be blocked when the AM is disabled?
This is a start of the user experience before and after your work. Notice that this can change or it can be improved if needed. We also need to keep in mind that Processing and, in this case the Android Mode, both should be leaning towards simplicity and easy to use to permit new users start using the technology right away without needing to know a lot about the Android technology.
@kfrajer @DeerajTheepshi The updated UX looks good to me, the only comment I have at this moment is that I don't think installing the emulator alongside the SDK is a good idea because it takes up a lot of space and not everyone will use it. It should only be installed when the user requests to run their sketches in the emulator, I think.
I have explained my views on certain parts of it and I have also mentioned the order in which these will be implemented.
- [L101] : This is default behavior and hence no changes are required.
- [L102] : Folder Selection and default Installation directory : We have completed work on this , with the last PR.
- [L103] : I cannot get what you mean by "same window". We definitely cant use the same window as we do for automatic download as it has information about packages that will be downloaded. Currently choosing Locate SDK manually opens up a file chooser and goes into the PDE. My suggestion would be to provide a window, where users can choose by opening a File Chooser and then have a button to confirm their option. Will begin after automatic installer is completed
- [L104] and [L105] : From Andres's suggestion, I guess its better to remove emulator download along with SDK and shift it to a much more specific emulator installer. Removal would be done in next commit, and the installer will be focused when we reach the emulator in phase 2
- [L106] to [L109] : Looks good, will be implemented in phase 2 , emulator section.
- [L110] : In my opinion its better to have the Emulator files within the SDK folder as it's the android Standard.
- [L111] : Yay! This is one of the feature, I'm waiting to implement. (Phase 2 , Emulator)
- [L113] : I would need some help here, any article or any resources could be useful. I will do a self research too.
And along with this, I would also like to change the updater UX as mentioned in the Evol doc, the tabbed layout with SDK Updates on one tab and SDK Tool updates on the other tab. This will be done once the android Installer is completed.