root/vendor/jcalc/calculator.html

Revision 2693, 3.7 kB (checked in by demian, 2 months ago)

checking in datagrid js libs

  • Property svn:eol-style set to native
  • Property svn:executable set to *
Line 
1 <!--
2 Title: Tigra Calculator
3 URL: http://www.softcomplex.com/products/tigra_calculator/
4 Version: 1.0
5 Date: 04/14/2003 (mm/dd/yyyy)
6 Note: Permission given to use this script in ANY kind of applications if
7    header lines are left unchanged.
8 Note: Script consists of two files: calculator.js and calculator.html
9 -->
10
11 <html>
12 <head>
13         <title>Tigra Calculator</title>
14         </head>
15 <body topmargin="0" marginheight="0" leftmargin="0" marginwidth="0" onload="on_load()" onunload="T.t_load=false" bgcolor="#BDD7EF">
16 <form name="calc">
17 <table cellpadding="0" cellpadding="0" border="0" width="100%" align="center">
18 <tr>
19         <td align="center">
20         <input type="text" name="monitor" value="0" size="25" maxlength="25" dir="rtl" onfocus="document.body.focus()" style="border-top:1px solid #4682B4;border-bottom:1px solid #4682B4;border-left:1px solid #4682B4;border-right:1px solid #4682B4;width:170">
21         </td>
22 </tr>
23 <tr>
24         <td align="center">
25         <table cellpadding="0" cellspacing="2" border="0">
26         <tr align="center">
27                 <td><a href="#"><img src="images/0_1.gif" border="0" alt="7" width="30" height="21"></a></td>
28                 <td><a href="#"><img src="images/1_1.gif" border="0" alt="8" width="30" height="21"></a></td>
29                 <td><a href="#"><img src="images/2_1.gif" border="0" alt="9" width="30" height="21"></a></td>
30                 <td><a href="#"><img src="images/3_1.gif" border="0" alt="divide" width="30" height="21"></a></td>
31                 <td><a href="#"><img src="images/4_1.gif" border="0" alt="clear" width="30" height="21"></a></td>
32         </tr>
33         <tr align="center">
34                 <td><a href="#"><img src="images/5_1.gif" border="0" alt="4" width="30" height="21"></a></td>
35                 <td><a href="#"><img src="images/6_1.gif" border="0" alt="5" width="30" height="21"></a></td>
36                 <td><a href="#"><img src="images/7_1.gif" border="0" alt="6" width="30" height="21"></a></td>
37                 <td><a href="#"><img src="images/8_1.gif" border="0" alt="multiply" width="30" height="21"></a></td>
38                 <td><a href="#"><img src="images/9_1.gif" border="0" alt="extract square root" width="30" height="21"></a></td>
39         </tr>
40         <tr align="center">
41                 <td><a href="#"><img src="images/10_1.gif" border="0" alt="1" width="30" height="21"></a></td>
42                 <td><a href="#"><img src="images/11_1.gif" border="0" alt="2" width="30" height="21"></a></td>
43                 <td><a href="#"><img src="images/12_1.gif" border="0" alt="3" width="30" height="21"></a></td>
44                 <td><a href="#"><img src="images/13_1.gif" border="0" alt="substruct" width="30" height="21"></a></td>
45                 <td><a href="#"><img src="images/14_1.gif" border="0" alt="show result" width="30" height="21"></a></td>
46         </tr>
47         <tr align="center">
48                 <td><a href="#"><img src="images/15_1.gif" border="0" alt="0" width="30" height="21"></a></td>
49                 <td><a href="#"><img src="images/16_1.gif" border="0" alt="change sign" width="30" height="21"></a></td>
50                 <td><a href="#"><img src="images/17_1.gif" border="0" alt="decimal point" width="30" height="21"></a></td>
51                 <td><a href="#"><img src="images/18_1.gif" border="0" alt="add" width="30" height="21"></a></td>
52                 <td> </td>
53         </tr>
54         </table>               
55         </td>
56 </tr>
57 </table>
58 </form>
59 <script language="JavaScript">
60 var arr_zn = ["7","8","9","/","C","4","5","6","*","sqr","1","2","3","-","=","0","z",".","+"],
61 T = self.opener.TCR, a_img = [], i, j, l;
62 function ch_img(v1, v2) {
63         document.images[v1].src = 'images/'+v1+'_'+v2+'.gif';
64 }
65 function on_load() {
66         T.TCRmntr('C');
67         T.t_load = true;
68         if (T.control_obj.value == '') from_p = '0';
69         else from_p = T.control_obj.value;
70         document.forms[0].elements[0].value = from_p;
71 }
72 for (i = 0; i < document.links.length; i++) {
73         l = document.links[i];
74         l.onmousedown = Function("ch_img(" + i + ",0)")
75         l.onmouseout = Function("ch_img(" + i + ",1)")
76         l.onmouseup = l.onmouseover = Function("ch_img(" + i + ",2)")
77         l.onclick = l.ondblclick = Function("T.TCRmntr('" + arr_zn[i] + "')");
78 }
79 </script>
80 </body></html>
Note: See TracBrowser for help on using the browser.