gallery和下面的第一个button的图像必须是相同的吗?

定义了gallery,下面设置了三个button,然后在ribbon .js里定义了GetImage函数,发现当add_classification和secret对应的图像不相同时,三个button的图像都不会显示出来,只有add_classification和secret对应的图像相同时,gallery和三个button的图像都能都正常显示。这是为什么? ``` <gallery id="add_classification" label="添加密级" getEnabled="OnGetEnabled" getImage="GetImage" visible="true" size="large" > <button id="secret" label="秘密" getImage="GetImage" /> <button id="confidential" label="机密" getImage="GetImage" /> <button id="top_secret" label="绝密" getImage="GetImage" /> </gallery> ```
广东省
浏览 84
收藏
点赞
分享
+1
5
+1
全部评论 5
 
陈俊东
陈俊东

@金山办公

你是在线的wps加载项吧,第一次菜单展开不显示,第二次就显示了吧?这是目前机制问题,图片下载是异步的,第一次菜单展开时,图片没有缓存,所以没显示,但是此时触发图片下载,下载完下次点开菜单就会显示了,gallery和button 图像相同时,因为gallery已经有图片缓存了,第一次菜单展开时就会直接用缓存了
· 广东省
回复
GP-杨剑锋Alston
不是,我的图片都是放在images文件夹里的
· 广东省
回复