![]() Using the View.onTouchEvent() you are able to get a lot of information such as tilt and orientation, pressure, and if this touch is from a stylus, finger, or even a stylus eraser. There are many stylus APIs that you can use to build more advanced support. Some applications are more prone to being used with a stylus, so take that into account when thinking in terms of your application. Some Chrome OS devices and phones ship with a stylus, so you may consider building support for this. It disables the compatibility mode and allows you to handle these distinct events. If you want to take full advantage of these different events, you can let the system know this by declaring the following in your manifest: Īdding this signifies that you have optimized your app for PC devices that are typically used with keyboard, mouse, and a trackpad. As such the compatibility mode would translate the scroll wheel event into a touch scroll event. As an example - many applications are not testing for the mouse scroll wheel - but every application looks at touch scroll events. A compatibility mode will help your application to use the widely used phone events instead of special events which are usually not handled by many applications. ![]() public boolean dispatchKeyShortcutEvent(KeyEvent event) ) įor other mouse compatibility strategies you should see the examples here.īy default your application should work on ChromeOS devices like it does on phones. Most of these are easy to implement as there is an API for Ctrl based shortcuts, dispatchKeyShortcutEvent. Think about which shortcuts users will expect based on the nature of your application, such as save, print, copy, paste, undo, and redo. Keyboard shortcuts are some of the best functionality that you can add for users with a keyboard as it brings convenience and a level of familiarity in using your application. See more on adding this functionality here. Navigation using the arrow keys is also easy to add in your layout files using the android:nextFocusDown attribute (for the down arrow) and the respective attributes for each navigation arrow. You can add navigation using the Tab key easily by using the android:nextFocusForward attribute in your layout files. ![]() If you have made accessibility a top priority you are a long way ahead, as those efforts lend to creating a navigable UI by other means than just touch. This experience gives your user a faster way of navigating through your app and getting to the information they want while not having to use a trackpad or touch screen, both of which may be uncomfortable for users. As a user, I navigate through lists, forms, and navigation tabs using tab and the arrow keys. Having a physical keyboard opens your application up to multiple navigation methods. You can make sure your application will be available on all Chrome OS devices by not requiring a touchscreen and adding this to your manifest. If you really believe that your application needs a real touch screen or multi touch than restrict based on these, but think about how you could provide a great experience with either a simulated touch gesture from the operating system or different ways of handling the same behavior. The trackpad simulates a fake touch event, so if you are requiring a touchscreen, your application will not be available on some Chrome OS devices. Users are going to expect certain applications to behave as they would on any other laptop when using a Chromebook so, as you test your app on Chrome OS, think of features you would want on this form factor.įirst things first, you should make sure that you are not requiring a touch screen or multi-touch in your manifest if you want your app to be used on Chrome OS. Many (but not all) have a touch screen, so your app needs to understand these inputs. The most obvious difference when using your application on a Chromebook is that there is a keyboard, trackpad, and sometimes a stylus that comes with the device. We’re going to cover one of them in this post, input compatibility. However, there are a few areas that tend to require some attention and optimizations. Most Android applications are already available to Chromebook users and run without needing to change anything. ![]() With the release of the new Google Pixelbook, the Google Play Store officially out of beta on Chrome OS, and the overall usage of Chromebooks on the rise, it’s time to start thinking about how your Android application will perform on Chrome OS. Get Your Android App Ready for Chromebooks
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |