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

the master version can`t support API below Level 11 #95

Open
zhanglt1986 opened this issue Sep 9, 2013 · 13 comments
Open

the master version can`t support API below Level 11 #95

zhanglt1986 opened this issue Sep 9, 2013 · 13 comments

Comments

@zhanglt1986
Copy link

getMeasuredState() and MEASURED_STATE_TOO_SMALL are used in ViewFlow.java ,
they are only support API level 11 and above.

@adouggy
Copy link

adouggy commented Sep 17, 2013

Yes, thanks. it works for me. default version from master is android 2.2 which make compile failed with hint getMeasuredState.

@guanguodong999
Copy link

Thanks , see this anwser . issue is solved.

@yolapop
Copy link

yolapop commented Nov 11, 2013

Excuse me, what was the solution?

@guanguodong999
Copy link

oh,sorry,just saw. In your project,

bonne chance!

ÔÚ 2013-11-11 19:40:05£¬Yolapop notifications@github.com дµÀ£º

Excuse me, what was the solution?

¡ª
Reply to this email directly or view it on GitHub.

@ghost
Copy link

ghost commented Nov 14, 2013

What was the solution? I don't see anything between "in your project" and "bonne chance".

@guanguodong999
Copy link

That is a image between "in your project" and "bonne chance".
please check the enclosure.
eclipse -> viewflow-> project.properties
target = android-17


please check your project .perhaps your name of project.properties file is below API 11.
If you don't solve , you can email , and attach the screenshot.
email : guanguodong999@163.com
ÔÚ 2013-11-15 07:31:40£¬"Charles Neveu" notifications@github.com дµÀ£º

What was the solution? I don't see anything between "in your project" and "bonne chance".

¡ª
Reply to this email directly or view it on GitHub.

@Venni27
Copy link

Venni27 commented Dec 25, 2013

Does it mean that the min sdk level is 11 now?

1 similar comment
@siwangqishiq
Copy link

Does it mean that the min sdk level is 11 now?

@atest1
Copy link

atest1 commented Mar 19, 2014

branch:recyclebin is OK with API Level 8.

@ghost
Copy link

ghost commented Jun 18, 2014

in ViewFlow.java function onMeasure()

replace
childState = child.getMeasuredState();

with
childState = child.MEASURED_HEIGHT_STATE_SHIFT >> child.MEASURED_STATE_MASK;

@Gurvinder1406
Copy link

Thanks a ton @PhilippEmmermacher
Can you please briefly explain what exactly was the issue ?

@ghost
Copy link

ghost commented Jul 17, 2014

@Gurvinder1406

The function getMeasuredState() was introduced in API 11.
This means it cannot be used in API's below Level 11.

But if you look at its documentation (http://developer.android.com/reference/android/view/View.html#getMeasuredState%28%29) you will easily notice what the function does:

"Return only the state bits of getMeasuredWidthAndState() and getMeasuredHeightAndState(), combined into one integer. The width component is in the regular bits MEASURED_STATE_MASK and the height component is at the shifted bits MEASURED_HEIGHT_STATE_SHIFT>>MEASURED_STATE_MASK. "

@ghost
Copy link

ghost commented Dec 25, 2014

thanks a lot @PhilippEmmermacher that worked perfectly.

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

8 participants