GithubHelp home page GithubHelp logo

androidwheel's People

Contributors

sephiroth74 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

androidwheel's Issues

Set wheel position from code

Thank you for making this very useful widget. I need to set its starting position to something other than halfway - e.g. the total range is 0 to 100, but I want it to start at 30 rather than 50.

How can this be done?

can not run

there is no main class it.sephiroth.test.test.MainActivity

Error importing android wheel to my project

Hey there! I just imported this project to Eclipse to use it as library, but when I added this library to my project, a lot of errors appeared suddenly in my project... Errors were like this: R cannot be resolved to a variable. So, which is the correct way to import android wheel?

SetValue causes a "divide by 0" exception.

Using the setvalue method gives me a divide by zero exception.

My code is as follows:

            mWheel = (Wheel) v.findViewById(R.id.wheel);
            mWheel.setOnScrollListener( new Wheel.OnScrollListener() {

                @Override
                public void onScrollStarted( Wheel view, float value, int roundValue ) {
                    Log.i("SPINZ", "STARTED: f: " + value + " / i: " + roundValue);
                }

                @Override
                public void onScrollFinished( Wheel view, float value, int roundValue ) {
                    Log.i("SPINZ", "FINISHED: f: " + value + " / i: " + roundValue);
                    roundValue *= -1;
                    roundValue += 40;
                    if (roundValue >= 0 && roundValue < sections.length)
                        mSectionTV.setText(sections[roundValue]);
                }

                @Override
                public void onScroll( Wheel view, float value, int roundValue ) {

                    roundValue *= -1;
                    roundValue += 40;
                    if (roundValue >= 0 && roundValue < sections.length)
                        mSectionTV.setText(sections[roundValue]);
                }
            } );

            mWheel.setValue(1.0f, true);

If I take mWheel.setValue(1.0f, true) and move it to right after mWheel = (Wheel) v.findViewById(R.id.wheel), then I don't get the divide by zero exception, but the method doesn't do anything either.

setValue can not work

mWheel.setValue(1, false) seems not work in onCreate , but in OnScrollListener it works fine.

Numbers

Is there any way to put numbers to wheel instead vertical lines?

Sample

Do you have any samples??

Adding support for Android 2.1 and 2.2

Your wheel looks great & funny.
But, I must set API to >= 9 when build because in Wheel.java line 1084 you define a OverScroller (which only from API 9+). This mean I cannot run this app on Android 2.1 and 2.2.

Can you take time to add support for 2.1 and 2.2?

Thanks.

Use with minimal XML

Specifically, I'm trying to move the lines

sephiroth:numRotations="2"
sephiroth:ticks="20"

to code, so that I can externalize the wheel and change it at will in my app. However, I can't find a way to control these via java rather than xml.

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.