⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 toctree.java

📁 非常接近C/S操作方式的Java Ajax框架-ZK 用ZK框架使你的B/S应用程序更漂亮更易操作。 官网:www.zkoss.org
💻 JAVA
字号:
/* TocTree.java{{IS_NOTE	Purpose:			Description:			History:		Thu Sep 28 19:02:37     2006, Created by tomyeh}}IS_NOTECopyright (C) 2006 Potix Corporation. All Rights Reserved.{{IS_RIGHT}}IS_RIGHT*/package org.zkoss.zkdemo.userguide;import org.zkoss.zk.ui.*;import org.zkoss.zk.ui.ext.AfterCompose;import org.zkoss.zul.*;/** * The Table-of-Content tree on the left. * * @author tomyeh */public class TocTree extends Tree implements AfterCompose {	public TocTree() {	}	public void onSelect() {		Treeitem item = getSelectedItem();		if (item != null) {			Include inc = (Include)Path.getComponent("/root/contents/xcontents");			inc.setSrc((String)item.getValue());		}	}	public void afterCompose() {		final Execution exec = Executions.getCurrent();		String id = exec.getParameter("id");		Treeitem item = null;		if (id != null) {			try {				item = (Treeitem)getSpaceOwner().getFellow(id);			} catch (ComponentNotFoundException ex) { //ignore			}		}		if (item == null)			item = (Treeitem)getSpaceOwner().getFellow("s1");		exec.setAttribute("contentSrc", (String)item.getValue());			//so index.zul know which page to load based on the id parameter		selectItem(item);	}}

⌨️ 快捷键说明

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