Leaked source code of windows server 2003
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

148 lines
5.5 KiB

  1. <html>
  2. <head>
  3. <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
  4. <style>
  5. body {margin: 0; font: icon; color: windowtext; background:window; overflow:none}
  6. span {font:icon;}
  7. #FolderIcon {height:expression(TaskpadName.clientHeight + 10); width:100%;}
  8. #TaskpadName {font: caption; color:captiontext; margin-left:0; margin-right:0; margin-top: 0; width:100%; border:0; padding-left:3; padding-top:5; padding-bottom:7;}
  9. #DisplayNameElem {font:icon; padding-left:5px; padding-top:5px; padding-bottom:3px; padding-right:5px}
  10. #Details {padding-left: 12px; margin-top: 8px; overflow:auto}
  11. #DescriptionElem {padding-left: 12px; margin-top: 8px; overflow-y:scroll; overflow:auto}
  12. A:visited {color:expression(document.linkColor);}
  13. A:hover {color:expression(document.linkColor);}
  14. </style>
  15. <script language="JavaScript" for="MMCEvents" EVENT="OnSelectionChange(V, N)">UpdateState();</script>
  16. <script language="JavaScript" for="MMCEvents" EVENT="OnContextMenuExecuted(MI)">UpdateState();</script>
  17. <script language="JavaScript" for="MMCEvents" EVENT="OnViewChange(V, N)">UpdateState();</script>
  18. <script language="JavaScript" for="MMCEvents" EVENT="OnToolbarButtonClicked()">UpdateState();</script>
  19. <script language="JavaScript" for="MMCEvents" EVENT="OnListUpdated(V)">UpdateState();</script>
  20. <script language="JavaScript">
  21. var L_strNoItemSelected_Text = "Select an item to view its description.";
  22. var L_strDescription_Text = "\nDescription:\n";
  23. var L_strMultipleItemsSelected_Text = "Multiple items selected.";
  24. function OnLoad()
  25. {
  26. ViewPanel.addBehavior("#default#mmcview");
  27. MMCEvents.ConnectTo(external.Document.Application);
  28. UpdateState();
  29. }
  30. // Prevent text from being selected and messing up the UI.
  31. function document.onselectstart()
  32. {
  33. event.returnValue = false;
  34. }
  35. function UpdateState()
  36. {
  37. var strDetails = "";
  38. var strDisplayName = "";
  39. var strDescription = "";
  40. var i;
  41. var curnode;
  42. var strNodeType;
  43. N = external.Selection;
  44. switch(N.count)
  45. {
  46. case 0:
  47. DisplayNameElem.style.fontWeight="normal";
  48. strDetails = "";
  49. strDisplayName = L_strNoItemSelected_Text;
  50. break;
  51. case 1:
  52. DisplayNameElem.style.fontWeight="bold";
  53. strDetails = "";
  54. curNode = N(1);
  55. // got the selected node
  56. strNodeType = curNode.Nodetype;
  57. strDisplayName = external.CellContents(curNode, 1);
  58. strDescription = curNode.Property("CCF_DESCRIPTION");
  59. strDetails = curNode.Property("CCF_HTML_DETAILS");
  60. break;
  61. default: // multiselect
  62. DisplayNameElem.style.fontWeight="normal";
  63. strDetails = L_strMultipleItemsSelected_Text;
  64. break;
  65. }
  66. TaskpadName.innerText = external.ActiveScopeNode.Name;
  67. TaskpadName.innerHTML = "<NOBR>" + TaskpadName.innerHTML + "</NOBR>";
  68. DisplayNameElem.innerText = strDisplayName;
  69. DisplayNameElem.innerHTML += "<BR>";
  70. if (strDetails != "")
  71. {
  72. strDetails = "<BR>" + strDetails + "<BR>"
  73. }
  74. DetailsElem.innerHTML = strDetails;
  75. if (strDescription != "")
  76. {
  77. strDescription = L_strDescription_Text + strDescription;
  78. }
  79. DescriptionElem.innerText = strDescription;
  80. }
  81. function OnUnload()
  82. {
  83. MMCEvents.Disconnect;
  84. }
  85. </script>
  86. </head>
  87. <body scroll=no onload=OnLoad()>
  88. <DIV style="position:absolute; top:0; left:0">
  89. <TABLE WIDTH="100%" cellspacing="0" cellpadding="0" COLS="2">
  90. <TR>
  91. <TD><SPAN style="width:32px"></SPAN></TD>
  92. <TD id="TaskpadName"></TD>
  93. </TR>
  94. </TABLE>
  95. </DIV>
  96. <TABLE WIDTH="100%" HEIGHT="100%" cellspacing="0" cellpadding="0" COLS="2">
  97. <TR>
  98. <TD id="LeftPanel" ROWSPAN="2" WIDTH="212px">
  99. <object id='FolderIcon' classid="clsid:B0395DA5-6A15-4E44-9F36-9A9DC7A2F341" tabIndex='-1'></object>
  100. </TD>
  101. <TD ID="RightPanel" bgColor="activecaption" VALIGN="TOP" WIDTH="100%" style="height:expression(TaskpadName.clientHeight);">
  102. </TD>
  103. </TR>
  104. <TR>
  105. <TD HEIGHT="10"></TD>
  106. </TR>
  107. <TR>
  108. <TD>
  109. <DIV id="DisplayNameElem">
  110. </DIV>
  111. </TD>
  112. <TD height="100%" ROWSPAN="2" id="ViewPanel"></TD>
  113. </TR>
  114. <TR>
  115. <TD HEIGHT="100%">
  116. <DIV STYLE="overflow: auto; height:100%; padding-left:5; padding-right:5; word-wrap:break-word">
  117. <SPAN id="DetailsElem"></SPAN>
  118. <span id=DescriptionElem></span>
  119. </DIV>
  120. </TD>
  121. </TR>
  122. </TABLE>
  123. <object id=MMCEvents classid="clsid:ADE6444B-C91F-4e37-92A4-5BB430A33340"></object>
  124. </body>
  125. </html>