?? fileupload.zul
字號:
<?xml version="1.0" encoding="UTF-8"?><!--fileupload.zul{{IS_NOTE Purpose: Description: History: Thu Nov 13 16:07:16 TST 2008, Created by Flyworld}}IS_NOTECopyright (C) 2008 Potix Corporation. All Rights Reserved.{{IS_RIGHT}}IS_RIGHT--><window id="demo" apply="org.zkoss.zkdemo.userguide.DemoWindowComposer"> <html><![CDATA[ <h4>Fileupload</h4> <p>Another frequently used modal window. It facilitates uploading files from client computer to the server.</p> <p>Try to press the "Upload" button and the fileupload modal window will open. Select an image file to upload and see what happened (The image will be shown on the demo window).</p> ]]></html> <separator />
<tabbox width="100%" tabscroll="false">
<tabs>
<tab id="demoView" label="Demo"/>
<tab id="srcView" label="View Source"/>
</tabs>
<tabpanels>
<tabpanel>
<window id="view">
</window>
</tabpanel>
<tabpanel>
<panel>
<panelchildren>
<textbox id="codeView" class="code" rows="20" width="95%">
<attribute name="value"><![CDATA[
<zk> <button label="Upload"> <attribute name="onClick">{ Object media = Fileupload.get(-1); if (media instanceof org.zkoss.util.media.Media[]) { org.zkoss.util.media.Media[] medias = (org.zkoss.util.media.Media [])media; for (int i = 0; i < medias.length; i++) { Image image = new Image(); image.setContent(medias[i]); image.setParent(pics); } } else if (media != null) Messagebox.show("Not an image: "+media, "Error", Messagebox.OK, Messagebox.ERROR); }</attribute> </button> <vbox id="pics" /></zk>
]]></attribute>
</textbox>
</panelchildren>
<toolbar mold="panel">
<button id="tryBtn" label="Try me!"/>
<button id="reloadBtn" label="Reload" height="18px"/>
</toolbar>
</panel>
</tabpanel>
</tabpanels>
</tabbox></window>
?? 快捷鍵說明
復(fù)制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -