Your Ad Here
首页 | 编程语言 | 网站建设 | 游戏天堂 | 冲浪宝典 | 网络安全 | 操作系统 | 软件时空 | 硬件指南 | 病毒相关 | IT 认证
软讯网络 > 编程语言 > Java > dojoTree TreeSelector
【标  题】:dojoTree TreeSelector
【关键字】:dojoTree,TreeSelector
【来  源】:http://www.blogjava.net/bjwulin/archive/2006/11/22/82918.html

dojoTree TreeSelector

Your Ad Here

TreeSelector继承于HtmlWidget,其作用主要是处理Tree的Select的功能。
1:具有selectedNode的属性
2:默认的事件名有:
eventNamesDefault: {
??select : "select",
??destroy : "destroy",
??deselect : "deselect",
??dblselect: "dblselect" // select already selected node.. Edit or whatever
?},
3:注意这段代码:eventNames的值。
initialize: function() {

??for(name in this.eventNamesDefault) {
???if (dojo.lang.isUndefined(this.eventNames[name])) {
????this.eventNames[name] = this.widgetId+"/"+this.eventNamesDefault[name];
???}
??}

?},
4:监听树的事件:
listenTree: function(tree) {
??//标题和图标的click都绑定到Selector的select事件。
??dojo.event.topic.subscribe(tree.eventNames.titleClick, this, "select");
??dojo.event.topic.subscribe(tree.eventNames.iconClick, this, "select");

??dojo.event.topic.subscribe(tree.eventNames.collapse, this, "onCollapse");
??dojo.event.topic.subscribe(tree.eventNames.moveFrom, this, "onMoveFrom");
??dojo.event.topic.subscribe(tree.eventNames.removeNode, this, "onRemoveNode");
??dojo.event.topic.subscribe(tree.eventNames.treeDestroy, this, "onTreeDestroy");

??/* remember all my trees to deselect when element is movedFrom them */
??this.listenedTrees.push(tree);
?},

5:

字符串编码与未公开的DBCSCodePageEncoding:【上一篇】
dojoTree Controller(3):【下一篇】
【相关文章】
没有相关文章
【随机文章】
  • 使用word样式格式化文档
  • IDS
  • 3DS Max 7.0 PF Source粒子全攻略(6)
  • AIX支持的最大socket数
  • 不用游标从表中取出前N条记录的存储过程
  • 一种实现Win32消息处理处理函数的新方法 - 基于Thunk实现的类成员消息处理函数
  • Joomla中的SEF
  • 网络工程师必懂的专业术语!
  • 可堆叠10/100M以太网交换机FS524S
  • Borland C++Builder 5.0教程(2)
  • 【相关评论】
    没有相关评论
    【发表评论】
    姓名:
    邮件:
    随机码*
    评论*
          
    |  首 页  |  版权声明  |  联系我们   |  网站地图  |
    CopyRight © 2004-2007 bbb软讯网络 All Rigths Reserved.