Commit 8f5b85ad by 李嘉林

轮播图宽度

parent 0454a6e3
...@@ -53,7 +53,7 @@ Component({ ...@@ -53,7 +53,7 @@ Component({
return; return;
} }
firstLoad = true; firstLoad = true;
let winWid = wx.getSystemInfoSync().windowWidth; //获取当前屏幕的宽度 let winWid = wx.getSystemInfoSync().windowWidth - this.data.datas.componentData.paddingList[2].value - this.data.datas.componentData.paddingList[3].value; //获取当前屏幕的宽度
let imgh = e.detail.height; //图片高度 let imgh = e.detail.height; //图片高度
let imgw = e.detail.width; let imgw = e.detail.width;
let swiperH = winWid * imgh / imgw + "px"; let swiperH = winWid * imgh / imgw + "px";
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment