popSample.xrw 2.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576
  1. <?xml version="1.0" encoding="EUC-KR"?>
  2. <xhtml:html xmlns:xhtml="http://www.w3.org/1999/xhtml" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="http://www.w3.org/2002/01/xforms" xmlns:ev="http://www.w3.org/2001/xml-events">
  3. <xhtml:head>
  4. <xhtml:title>Untitle</xhtml:title>
  5. <model id="model1">
  6. <instance id="instance1">
  7. <root xmlns="">
  8. <example>Sample</example>
  9. <grid>
  10. <item>
  11. <a>1</a>
  12. <b>2</b>
  13. <c>3</c>
  14. </item>
  15. <item>
  16. <a>1</a>
  17. <b>2</b>
  18. <c>3</c>
  19. </item>
  20. <item>
  21. <a>1</a>
  22. <b>2</b>
  23. <c>3</c>
  24. </item>
  25. </grid>
  26. </root>
  27. </instance>
  28. </model>
  29. <script type="javascript">
  30. <![CDATA[
  31. function onclick()
  32. {
  33. if ("SoonsuViewer" == document.userAgent)
  34. {
  35. if ("xforms:cell" != document.all(event.target).elementName)
  36. {
  37. pop_group.visible = false;
  38. }
  39. }
  40. else
  41. {
  42. if ("xforms:col" != event.pTarget.elementName)
  43. {
  44. pop_group.visible = false;
  45. }
  46. }
  47. }
  48. ]]>
  49. </script>
  50. </xhtml:head>
  51. <xhtml:body>
  52. <datagrid id="datagrid1" nodeset="/root/grid/item" caption="caption1^caption2^caption3" colsep="^" mergecellsfixedrows="bycolrec" rowsep="|" style="left:90px; top:50px; width:350px; height:150px; ">
  53. <col ref="a"/>
  54. <col ref="b"/>
  55. <col ref="c"/>
  56. <script type="javascript" ev:event="onrowchanged">
  57. <![CDATA[
  58. pop_group.attribute("left") = (event.clientX - 10) + "px";
  59. pop_group.attribute("top") = (event.clientY - 10) + "px";
  60. pop_group.visible = true;
  61. ]]>
  62. </script>
  63. </datagrid>
  64. <group id="pop_group" visibility="hidden" overflow="hidden" style="left:460px; top:85px; width:114px; height:52px; background-color:#ccffcc; ">
  65. <button id="button1" style="left:5px; top:10px; width:100px; height:30px; ">
  66. <caption> ȸ</caption>
  67. <script type="javascript" ev:event="onclick">
  68. <![CDATA[
  69. alert("window.load");
  70. ]]>
  71. </script>
  72. </button>
  73. </group>
  74. </xhtml:body>
  75. </xhtml:html>