提交 b0f2698a 编写于 作者: shutao-dc's avatar shutao-dc

update swiper.uvue 适配kotlin语法

上级 a6f7384b
...@@ -131,8 +131,10 @@ ...@@ -131,8 +131,10 @@
// 获取模拟滑动手势的起始点 // 获取模拟滑动手势的起始点
let ele = uni.getElementById("swiper-view") let ele = uni.getElementById("swiper-view")
let eleRect = ele?.getBoundingClientRect() let eleRect = ele?.getBoundingClientRect()
this.swipeX = eleRect!.width - 10 if(eleRect != null) {
this.swipeY += eleRect!.y + uni.getSystemInfoSync().safeArea.top + 44 + 35 this.swipeX = eleRect.width - 10
this.swipeY += eleRect.y + uni.getSystemInfoSync().safeArea.top + 44 + 35
}
}, },
methods: { methods: {
swipertouchStart(e: UniTouchEvent) { swipertouchStart(e: UniTouchEvent) {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册