z30-serverpush.zul

来自「ZK是一个Ajax Java Web框架」· ZUL 代码 · 共 53 行

ZUL
53
字号
<?xml version="1.0" encoding="UTF-8"?><!--server-push.zul{{IS_NOTE	Purpose:			Description:			History:		Mon Aug  6 12:35:50     2007, Created by tomyeh}}IS_NOTECopyright (C) 2007 Potix Corporation. All Rights Reserved.{{IS_RIGHT}}IS_RIGHT--><window title="Server Push">The number at the bottom shall be counting.Click "Stop Push", and it shall stop.Click "Start Push", and it shall count again (from 1).<separator/>Note: the server push is enabled and timer disabled at the beginning.	<vbox>	<button label="Start Push" onClick="org.zkoss.zkdemo.test2.ServerPush.start(info)"/>	<button label="Stop Push" onClick="org.zkoss.zkdemo.test2.ServerPush.stop()"/>	<button label="Start Timer" onClick="timer.start()"/>	<button Label="Stop Timer" onClick="timer.stop()"/>	</vbox>	<timer id="timer" running="false" repeats="true" delay="1000"		onTimer='org.zkoss.zkdemo.test2.ServerPush.updateInfo(info, "timer")'/>	<div id="info" style="border:1px solid blue"/>	<zscript>	org.zkoss.zkdemo.test2.ServerPush.start(info);	</zscript><script>spau = {};zk.override(zkau.cmd1, "addAft", spau, function (uuid, cmp, html) {	try {		spau.addAft(uuid, cmp, html);	} catch (e) {		zk.debug("Error: addAft: "+uuid+"\n"+html);		zkCmsp.stopAll();		zkTimer.stopAll();		throw e;	}});</script></window>

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?