zoukankan      html  css  js  c++  java
  • Android Coding: Gestures Builder: create your gestures library

    Android Coding: Gestures Builder: create your gestures library

    Sep 18, 2011

    Gestures Builder: create your gestures library

    Gesture is a prerecorded touch screen motion sequency. If user performs gesture as the prerecorded gesture, your app can recogized as a command.



    Gestures API (android.gesture) was introduced in Android 1.6, lets you store, load, draw and recognize gestures. In order to use Gestures API, you need a prerecorded gestures library. The Android 1.6 SDK (or later) comes with a new application pre-installed on the emulator, called Gestures Builder. You can use this application to create a set of pre-defined gestures for your own application.



    You can also find the source code of Gestures Builder in SDK samples, such that you can create it on true device to create your own gestures library.



    Create GesturesBuilder

    • In Eclipse, click File -> New - Project... to create a New Android Project.
    • Select "Create project from existing sample", select Build Target higher than 1.6, select GesturesBuilder in Samples, and click Finish.
    • Build and Run the App




    GesturesBuilder



    After you Add gesture and DONE, a Toast will show you where is the gestures file saved, /mnt/sdcard/gestures (root of sd card) in my case. You can copy the gestures file to /res/raw folder of you gesture-enabled app as your gestures library.

    next Post:
  • 相关阅读:
    Domain Logic approaches
    Load data local infile 实验报告
    eclipse导入Maven项目
    MYSQL数据库导入数据时出现乱码的解决办法
    mysql创建用户并分配权限
    CDI Features
    Java Design Patterr
    关联tomcat源代码
    Spring AOP Capabilities and Goals
    CDI FEATURES
  • 原文地址:https://www.cnblogs.com/lexus/p/2798398.html
Copyright © 2011-2022 走看看