Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

onRestoreInstanceState, Thumbs are not visible #64

Open
m-akopov opened this issue Apr 1, 2016 · 2 comments
Open

onRestoreInstanceState, Thumbs are not visible #64

m-akopov opened this issue Apr 1, 2016 · 2 comments

Comments

@m-akopov
Copy link

m-akopov commented Apr 1, 2016

When onRestoreInstanceState of the view is called, the thumbs become invisible. I think that's because createPins method is called, and it creates thumbs with 0 radius pans.


mRightThumb
                .init(ctx, yPos, 0, mPinColor, mTextColor, mCircleSize, mCircleColor, mMinPinFont,
                        mMaxPinFont, false);

Please fix it.

@OneWorld123
Copy link

Fix in method "createPins". I borrowed the code for the pinSize from the method "onSizeChanged". Only occures, if setTemporaryPins(false)

float density = getResources().getDisplayMetrics().density;
    float expandedPinRadius = mExpandedPinRadius / density;

    if (mIsRangeBar) {
        mLeftThumb = new PinView(ctx);
        mLeftThumb.init(ctx, yPos, expandedPinRadius, mPinColor, mTextColor, mCircleSize, mCircleColor,
                mMinPinFont, mMaxPinFont, false);
    }
    mRightThumb = new PinView(ctx);
    mRightThumb
            .init(ctx, yPos, expandedPinRadius, mPinColor, mTextColor, mCircleSize, mCircleColor, mMinPinFont,
                    mMaxPinFont, false);

@ghost
Copy link

ghost commented May 10, 2016

Hello, I have the same question about disappearing thumb.
Please could you tell me how to fix in method "createPins" in library?
Thanks a lot. ~~

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants