加载网页一般费时,所以需要再开始加载网页时,添加蒙版,再加载网页后,取消蒙版
具体方法如下:
duilib UI布局端:
<VBox bkcolor="xnw_client" bordercolor="green" bordersize="1,1,1,1" padding="1,1,1,1">
<!-- 客户端名称设置 -->
<HBox height="30" bkcolor="xnw_yellow">
<Control />
<Label text="" valign="center" font="2" normaltextcolor="black" />
<Control />
<Button class="btn_wnd_close_black" name="myClosebtn" margin="0,0,10,0" valign="center" />
</HBox>
<VBox name="loading" height="stretch" visible="true">
<Control />
<Control bkimage="loading.gif" width="auto" height="auto" halign="center" />
<Control />
</VBox>
<CefControl name="cef_control" visible="false"/>
</VBox>
c++ 端:需要处理 CEF开始加载 和结束加载回调
逻辑就是 CEF开始加载时,显
来源:oschina
链接:https://my.oschina.net/u/4255339/blog/3227961