--- /dev/null
+h3.log{\r
+margin:1em 0;\r
+}\r
+\r
+\r
+#log{\r
+white-space:nowrap;\r
+width:300px;\r
+height:200px;\r
+border:solid 1px #cfcad2;\r
+}\r
+\r
+ol#log li{\r
+margin-left:30px;\r
+}\r
+\r
+ol#log{\r
+overflow:auto;\r
+}\r
+\r
+#tree_container{\r
+height:200px;\r
+width:300px;\r
+position:relative;\r
+border:solid 1px #b7b7b7;\r
+}\r
+\r
+\r
+/*@global*/\r
+\r
+.mif-tree-wrapper{\r
+position: absolute;\r
+width: 100%;\r
+height:100%;\r
+margin:0;\r
+padding:0;\r
+overflow:auto;\r
+font-family:sans-serif;\r
+font-size:11px;\r
+line-height:18px;/******Tree node height******/\r
+white-space:nowrap;\r
+cursor:default;\r
+}\r
+\r
+.mif-tree-bg{\r
+width:100%;\r
+height:100%;\r
+position:absolute;\r
+overflow:hidden;\r
+}\r
+\r
+.mif-tree-bg-container{\r
+width:100%;\r
+display:none;\r
+}\r
+\r
+.mif-tree-bg-node{\r
+width:100%;\r
+height:18px;\r
+}\r
+\r
+.mif-tree-bg-selected{\r
+background-color:#dcd7ab;\r
+}\r
+\r
+.mif-tree-wrapper:focus{\r
+outline:0;\r
+}\r
+\r
+.mif-tree-wrapper span{\r
+padding-bottom:2px;\r
+padding-top:2px;\r
+cursor:inherit;\r
+}\r
+\r
+.mif-tree-children{\r
+padding-left:18px;\r
+width:18px;\r
+}\r
+\r
+.mif-tree-node{\r
+width:18px;\r
+background:url('../assets/images/line.gif') repeat-y 8px 0px;\r
+}\r
+\r
+.mif-tree-node-last{\r
+background:url('../assets/images/line.gif') no-repeat 8px 0px;\r
+}\r
+\r
+.mif-tree-name{\r
+cursor: default;\r
+overflow:hidden;\r
+margin-left:4px;\r
+}\r
+\r
+.mif-tree-name a{\r
+color:red;\r
+}\r
+\r
+.mif-tree-name a:hover{\r
+color:blue;\r
+}\r
+\r
+\r
+.mif-tree-node-wrapper{\r
+background:url('../assets/images/horizontal-line.gif') no-repeat 9px center;\r
+}\r
+\r
+/*@gadjets*/\r
+\r
+.mif-tree-gadjet{\r
+background-image:url('../assets/images/gadjets.gif');\r
+padding-right: 16px;\r
+z-index:1;\r
+overflow:hidden;\r
+background-repeat:no-repeat;\r
+cursor:default;\r
+}\r
+\r
+.mif-tree-gadjet-none{\r
+background:none;\r
+}\r
+\r
+.mif-tree-gadjet-minus{\r
+background-position: 0px 50%;\r
+}\r
+\r
+.mif-tree-gadjet-plus{\r
+background-position: -18px 50%;\r
+}\r
+\r
+\r
+.mif-tree-gadjet-hover .mif-tree-gadjet-minus{\r
+background-position: -54px 50%;\r
+}\r
+\r
+.mif-tree-gadjet-hover .mif-tree-gadjet-plus{\r
+background-position: -72px 50%;\r
+}\r
+\r
+\r
+\r
+\r
+/*.mif-tree-gadjet-hover{\r
+background-image:url('../assets/images/gadjets-hover.gif');\r
+}*/\r
+\r
+\r
+\r
+\r
+/*@icons*/\r
+.mif-tree-icon{\r
+padding-right:18px;\r
+background-position:0 50%;\r
+background-repeat:no-repeat;\r
+cursor:inherit;\r
+}\r
+\r
+.mif-tree-open-icon{\r
+background-image:url('../assets/images/openicon.gif')\r
+}\r
+\r
+.mif-tree-close-icon{\r
+background-image:url('../assets/images/closeicon.gif')\r
+}\r
+\r
+.mif-tree-loader-open-icon,.mif-tree-loader-close-icon{\r
+background-image:url('../assets/images/mootree_loader.gif');\r
+}\r
+\r
+.mif-tree-book-icon{\r
+background-image:url('../assets/images/book_icon.gif');\r
+}\r
+\r
+.mif-tree-bin-open-icon{\r
+background-image:url('../assets/images/bin_open_icon.gif');\r
+}\r
+\r
+.mif-tree-bin-close-icon{\r
+background-image:url('../assets/images/bin_close_icon.gif');\r
+}\r
+\r
+\r
+/*@selection*/\r
+\r
+.mif-tree-node-selected .mif-tree-name{\r
+background-color: #010161;\r
+color:#fff;\r
+text-transform:italic;\r
+}\r
+\r
+.mif-tree-highlighter{\r
+height:18px;\r
+overflow:hidden;\r
+width:100%;\r
+background:#b64553;\r
+position:absolute;\r
+}\r
+\r
+\r
+\r
+/*@d'n'd*/\r
+.mif-tree-pointer{\r
+height:1px;\r
+overflow: hidden;\r
+position: absolute;\r
+background-image:url('../assets/images/1.gif');\r
+background-repeat:repeat-x;\r
+background-color:#292fef;\r
+}\r
+\r
+\r
+.mif-tree-ghost{\r
+background-color:#fff;\r
+border:solid 2px #e8e8f7;\r
+padding-left:2px;\r
+}\r
+\r
+.mif-tree-ghost .mif-tree-node-wrapper{\r
+background:none;\r
+}\r
+\r
+.mif-tree-ghost span.mif-tree-text{\r
+padding-top:1px;\r
+padding-bottom:1px;\r
+}\r
+\r
+.mif-tree-ghost-icon{\r
+padding-left:16px;\r
+background-color:#fff;\r
+background-repeat:no-repeat;\r
+background-image:url('../assets/images/dropzone.gif');\r
+}\r
+\r
+.mif-tree-ghost-after{\r
+background-position:-64px 2px;\r
+}\r
+\r
+.mif-tree-ghost-before{\r
+background-position:-48px 2px;\r
+}\r
+\r
+.mif-tree-ghost-between{\r
+background-position:-16px 2px;\r
+}\r
+\r
+.mif-tree-ghost-inside{\r
+background-position:-0px 2px;\r
+}\r
+\r
+.mif-tree-ghost-notAllowed{\r
+background-position:-32px 2px;\r
+}\r
+\r
+.mif-tree-drag-current{\r
+background-color:#cfcfd8;\r
+}\r
+\r
+.mif-tree-replace{\r
+background-color:#99c8fb;\r
+}\r
+\r
+\r
+/*@checkbox*/\r
+.mif-tree-checkbox{\r
+padding-left:18px;\r
+}\r
+\r
+.mif-tree-node-checked, .mif-tree-node-checked .mif-tree-checkbox{\r
+background:url('../assets/images/checked.gif') center 2px no-repeat;\r
+}\r
+\r
+.mif-tree-node-unchecked, .mif-tree-node-unchecked .mif-tree-checkbox{\r
+background:url('../assets/images/unchecked.gif') center 2px no-repeat;\r
+}\r
+\r
+.mif-tree-node-checked-selected{\r
+background:url('../assets/images/checked_selected.gif') center 2px no-repeat;\r
+}\r
+\r
+.mif-tree-node-unchecked-selected{\r
+background:url('../assets/images/unchecked_selected.gif') center 2px no-repeat;\r
+}\r
+\r
+\r
+\r
+/*@rename*/\r
+.mif-tree-rename{\r
+display: inline;\r
+line-height: 14px;\r
+height:14px;\r
+cursor: default;\r
+overflow:hidden;\r
+font-family:sans-serif;\r
+font-size:11px;\r
+padding:1px 0;\r
+border:solid 1px black;\r
+}\r
--- /dev/null
+window.addEvent('domready',function(){\r
+ SimpleTree = new Mif.Tree({\r
+ container: $('tree_container'),\r
+ types: {\r
+ folder: {\r
+ openIcon: 'mif-tree-open-icon',\r
+ closeIcon: 'mif-tree-close-icon'\r
+ }\r
+ },\r
+ dfltType: 'folder',\r
+ height: 18\r
+ })\r
+ .load({\r
+ url: '../assets/files/simpleTree.json'\r
+ })\r
+ .addEvent('load', function(){\r
+ this.root.recursive(function(){\r
+ this.toggle();\r
+ });\r
+ })\r
+ .addEvent('select',function(node){\r
+ $('log').adopt(new Element('li').set('html', node.name + ' selected'));\r
+ })\r
+ .addEvent('unSelect', function(node){\r
+ $('log').adopt(new Element('li').set('html', node.name + ' unselected'));\r
+ });\r
+});\r