又一个问题:
我有一个滚动视图,其中的图像由 createView 加载,但是如何从 url 添加图像?在我的情况下,如果我将 ../images/.... 更改为http://www.codeworxx.com/images/ ...图像未加载。在coverFlowView 中它有效?!?!
有任何想法吗?这是我的代码:
var image1 = Ti.UI.createView({width:320,height:156,backgroundImage:'../images/gallery/bmw3er/image1.jpg'});
var image2 = Ti.UI.createView({width:320,height:156,backgroundImage:'../images/gallery/bmw3er/image2.jpg'});
var image3 = Ti.UI.createView({width:320,height:156,backgroundImage:'../images/image3.jpg'});
var image4 = Ti.UI.createView({width:320,height:156,backgroundImage:'../images/image4.jpg'});
var image5 = Ti.UI.createView({width:320,height:156,backgroundImage:'../images/image5.jpg'});
var image6 = Ti.UI.createView({width:320,height:156,backgroundImage:'../images/image6.jpg'});
var scrollView = Ti.UI.createScrollableView({
views:[image1,image2,image3,image4,image5,image6],
showPagingControl:true,
clipViews:false,
top:0,
left:30,
right:30,
width:320,
height:156,
opacity:0
});
再次感谢你的帮助。
萨沙