Bug P3
Status Update
Comments
gg...@google.com <gg...@google.com>
gg...@google.com <gg...@google.com> #2
I face with the same problem. I have different pageMargin in landscape and portrait and when viewpager is scrolled for the more than first position, after rotating device it is shifted.
I beleive the problem is inside onSizeChanged that is called after onConfigurationChanged, it has following code:
if (w != oldw) {
recomputeScrollPosition(w, oldw, mPageMargin, mPageMargin);
}
w always not equals oldw when changing orientation, so recomputeScrollPosition is called, but whit the same values for margin and oldMargin.
This should be fixed.
I beleive the problem is inside onSizeChanged that is called after onConfigurationChanged, it has following code:
if (w != oldw) {
recomputeScrollPosition(w, oldw, mPageMargin, mPageMargin);
}
w always not equals oldw when changing orientation, so recomputeScrollPosition is called, but whit the same values for margin and oldMargin.
This should be fixed.
da...@talentomobile.com <da...@talentomobile.com> #3
[Comment deleted]
gg...@google.com <gg...@google.com>
t6...@gmail.com <t6...@gmail.com> #4
I found the same problem in suport library v4, wrong align happens only when ViewPager has a page margin > 0.
da...@talentomobile.com <da...@talentomobile.com> #5
[Comment deleted]
t6...@gmail.com <t6...@gmail.com> #6
The issue is still reproducible in support library v4 (rev. 18).
I managed to fix the issue by importing the source code of ViewPager in my project and modifying from onSizeChanged method the following line:
From:
if (w != oldw) {
recomputeScrollPosition(w, oldw, mPageMargin, mPageMargin);
}
To:
if (w != oldw) {
recomputeScrollPosition(w, oldw, 0, 0);
}
I managed to fix the issue by importing the source code of ViewPager in my project and modifying from onSizeChanged method the following line:
From:
if (w != oldw) {
recomputeScrollPosition(w, oldw, mPageMargin, mPageMargin);
}
To:
if (w != oldw) {
recomputeScrollPosition(w, oldw, 0, 0);
}
da...@talentomobile.com <da...@talentomobile.com> #7
I use this little wrapper as a work around for the bug:
ublic class FixedViewPager extends ViewPager {
public FixedViewPager(Context context, AttributeSet attrs) {
super(context, attrs);
}
public FixedViewPager(Context context) {
super(context);
}
@Override
protected void onSizeChanged(int w, int h, int oldw, int oldh) {
super.onSizeChanged(w-this.getPageMargin(), h, oldw-this.getPageMargin(), oldh);
}
}
ublic class FixedViewPager extends ViewPager {
public FixedViewPager(Context context, AttributeSet attrs) {
super(context, attrs);
}
public FixedViewPager(Context context) {
super(context);
}
@Override
protected void onSizeChanged(int w, int h, int oldw, int oldh) {
super.onSizeChanged(w-this.getPageMargin(), h, oldw-this.getPageMargin(), oldh);
}
}
Description
On Android 12 the developers can't see the fingers that the device has. And when you remove a biometric. can't access the cipher.doFinal() [response Key user not authenticated]. And the device keeps it blocked. And there isn't a way to fix it. Could you update to setInvalidatedByBiometricEnrollment(true) delete and add some new biometric