Git Product home page Git Product logo

modifiedstepsview's Introduction

ModifiedStepsView

改进的StepsView

根据StepsView进行改进,添加了每一步进行的等待动画和每一步的执行结果动画

##具体的如下图所示

image

##使用方法

###activity的xml文件中添加:

   <com.example.lenovo.library.StepsView
     android:id="@+id/steps_view"
     android:layout_height="wrap_content"
     android:layout_width="fill_parent"
     app:numOfSteps="4"></com.example.lenovo.library.StepsView>

###在你的activity中调用

     stepsView = (StepsView) findViewById(R.id.steps_view);
     final String[] steps = {"step1", "step2", "step3", "step4"};
     stepsView.setLabels(steps)
            .setColorIndicator(Color.GRAY)
            .setBarColor(Color.GREEN)
            .setLabelColor(Color.BLACK);

    new Thread() {
        public void run() {
            for (int i = 0; i < steps.length; i++) {
                if(isStop) {
                    break;
                }
                Message msg = new Message();
                msg.obj = i;
                handler.sendMessage(msg);
                try {
                    Thread.sleep(4000);
                } catch (Exception e) {
                }
            }
            Message msg = new Message();
            msg.obj = steps.length;
            handler.sendMessage(msg);
        }
    }.start();

'''

modifiedstepsview's People

Contributors

gpfduoduo 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.