fix scrollable false prevent scrollToPosition
This commit is contained in:
@@ -99,6 +99,30 @@ class SliderPanel extends Panel {
|
||||
space: 10,
|
||||
backgroundColor: Color.RED,
|
||||
}),
|
||||
hlayout([
|
||||
text({
|
||||
text: "Scrollable",
|
||||
layoutConfig: {
|
||||
widthSpec: LayoutSpec.FIT,
|
||||
heightSpec: LayoutSpec.JUST,
|
||||
},
|
||||
textSize: 20,
|
||||
textColor: Color.BLACK,
|
||||
textAlignment: gravity().center(),
|
||||
height: 50,
|
||||
}),
|
||||
switchView({
|
||||
state: true,
|
||||
onSwitch: (state) => {
|
||||
pager.scrollable = state
|
||||
},
|
||||
}),
|
||||
], {
|
||||
layoutConfig: layoutConfig().most().configHeight(LayoutSpec.FIT),
|
||||
gravity: gravity().center(),
|
||||
space: 10,
|
||||
backgroundColor: Color.RED,
|
||||
}),
|
||||
hlayout([
|
||||
text({
|
||||
text: "Bounces",
|
||||
|
Reference in New Issue
Block a user