Giter Club home page Giter Club logo

customizekeyboard's Introduction

#自定义Android键盘

##由于项目需要临时写了个自定义安全键盘

用法:

依赖:

dependencies{
   compile 'com.ziyeyouhu:customizekeyboard:1.0.0'
}

初始化

 private void initMoveKeyBoard() {
         keyboardUtil = new KeyboardUtil(this, rootView, scrollView);
         keyboardUtil.setOtherEdittext(normalEd);
         // monitor the KeyBarod state
         keyboardUtil.setKeyBoardStateChangeListener(new KeyBoardStateListener());
         // monitor the finish or next Key
         keyboardUtil.setInputOverListener(new inputOverListener());
         specialEd.setOnTouchListener(new KeyboardTouchListener(keyboardUtil, KeyboardUtil.INPUTTYPE_ABC, -1));
     }

关于键盘输入状态

     public static int inputType = 1;                   // 默认
     public static final int INPUTTYPE_NUM = 1;         // 数字,右下角 为空
     public static final int INPUTTYPE_NUM_FINISH = 2;  // 数字,右下角 完成
     public static final int INPUTTYPE_NUM_POINT = 3;   // 数字,右下角 为点
     public static final int INPUTTYPE_NUM_X = 4;       // 数字,右下角 为X
     public static final int INPUTTYPE_NUM_NEXT = 5;    // 数字,右下角 为下一个
     public static final int INPUTTYPE_ABC = 6;         // 一般的abc
     public static final int INPUTTYPE_SYMBOL = 7;      // 标点键盘
     public static final int INPUTTYPE_NUM_ABC = 8;     // 数字,右下角 为下一个

###效果图如下

customizekeyboard's People

Contributors

ziyeyouhu avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.