rwddialogmap 0.01

Sign up to get free protection for your applications and to get access to all the features.
Files changed (170) hide show
  1. data/Readme.txt +475 -0
  2. data/bin/rwddialogmap +19 -0
  3. data/code/01rwdcore/01rwdcore.rb +29 -0
  4. data/code/01rwdcore/02helptexthashbegin.rb +4 -0
  5. data/code/01rwdcore/03helptexthash.rb +23 -0
  6. data/code/01rwdcore/04helptextend.rb +6 -0
  7. data/code/01rwdcore/jumplinkcommand.rb +26 -0
  8. data/code/01rwdcore/openhelpwindow.rb +31 -0
  9. data/code/01rwdcore/returntomain.rb +10 -0
  10. data/code/01rwdcore/rundocuments.rb +10 -0
  11. data/code/01rwdcore/runeditconfiguration.rb +10 -0
  12. data/code/01rwdcore/runhelpabout.rb +10 -0
  13. data/code/01rwdcore/runopentinkerdocument.rb +7 -0
  14. data/code/01rwdcore/rwdtinkerversion.rb +22 -0
  15. data/code/01rwdcore/rwdwindowreturn.rb +9 -0
  16. data/code/01rwdcore/selectiontab.rb +9 -0
  17. data/code/01rwdcore/setuphelpaboutoptions.rb +13 -0
  18. data/code/01rwdcore/setuptinkerdocuments.rb +6 -0
  19. data/code/01rwdcore/test_cases.rb +109 -0
  20. data/code/01rwdcore/test_harness.rb +13 -0
  21. data/code/01rwdcore/uploadreturns.rb +62 -0
  22. data/code/dd0viewphoto/dd0viewphoto.rb +3 -0
  23. data/code/superant.com.dialogmap/0uninstallapplet.rb +12 -0
  24. data/code/superant.com.dialogmap/changedir.rb +31 -0
  25. data/code/superant.com.dialogmap/clearhypernotescreendisplay.rb +14 -0
  26. data/code/superant.com.dialogmap/clearlinkscreendisplay.rb +13 -0
  27. data/code/superant.com.dialogmap/createnewnote.rb +28 -0
  28. data/code/superant.com.dialogmap/helptexthashrwdhypernote.rb +38 -0
  29. data/code/superant.com.dialogmap/launchurlfile.rb +35 -0
  30. data/code/superant.com.dialogmap/listdirectories.rb +19 -0
  31. data/code/superant.com.dialogmap/listdirectories3.rb +25 -0
  32. data/code/superant.com.dialogmap/listnotedirshtml3.rb +54 -0
  33. data/code/superant.com.dialogmap/loadconfigurationrecord.rb +22 -0
  34. data/code/superant.com.dialogmap/loadconfigurationvariables.rb +14 -0
  35. data/code/superant.com.dialogmap/loadhtmlnoterecord.rb +24 -0
  36. data/code/superant.com.dialogmap/openhelpwindowrwdhyernote.rb +38 -0
  37. data/code/superant.com.dialogmap/runhypernote.rb +10 -0
  38. data/code/superant.com.dialogmap/runwrdhypernotetxtwindow.rb +10 -0
  39. data/code/superant.com.dialogmap/rwdhypernoteresetdir.rb +7 -0
  40. data/code/superant.com.dialogmap/rwdtinkerversion.rb +10 -0
  41. data/code/superant.com.dialogmap/saveconfigurationrecord.rb +20 -0
  42. data/code/superant.com.dialogmap/savelinkrecord.rb +23 -0
  43. data/code/superant.com.dialogmap/viewdialogmaphtml3.rb +66 -0
  44. data/code/superant.com.dialogmap/xmlprettyprint.rb +65 -0
  45. data/code/superant.com.dialogmap/xmlprettyprint2.rb +74 -0
  46. data/code/superant.com.rwdtinkerbackwindow/diagnostictab.rb +19 -0
  47. data/code/superant.com.rwdtinkerbackwindow/helptexthashtinkerwin2.rb +61 -0
  48. data/code/superant.com.rwdtinkerbackwindow/initiateapplets.rb +240 -0
  49. data/code/superant.com.rwdtinkerbackwindow/installgemapplet.rb +34 -0
  50. data/code/superant.com.rwdtinkerbackwindow/installremotegem.rb +20 -0
  51. data/code/superant.com.rwdtinkerbackwindow/listgemdirs.rb +12 -0
  52. data/code/superant.com.rwdtinkerbackwindow/listgemzips.rb +53 -0
  53. data/code/superant.com.rwdtinkerbackwindow/listinstalledfiles.rb +12 -0
  54. data/code/superant.com.rwdtinkerbackwindow/listzips.rb +33 -0
  55. data/code/superant.com.rwdtinkerbackwindow/loadconfigurationrecord.rb +22 -0
  56. data/code/superant.com.rwdtinkerbackwindow/loadconfigurationvariables.rb +14 -0
  57. data/code/superant.com.rwdtinkerbackwindow/network.rb +87 -0
  58. data/code/superant.com.rwdtinkerbackwindow/openappletname.rb +19 -0
  59. data/code/superant.com.rwdtinkerbackwindow/openhelpwindowtinkerwin2.rb +38 -0
  60. data/code/superant.com.rwdtinkerbackwindow/remotegemlist.rb +24 -0
  61. data/code/superant.com.rwdtinkerbackwindow/removeapplet.rb +46 -0
  62. data/code/superant.com.rwdtinkerbackwindow/removeappletvariables.rb +52 -0
  63. data/code/superant.com.rwdtinkerbackwindow/runremoteinstall.rb +11 -0
  64. data/code/superant.com.rwdtinkerbackwindow/runrwdtinkerbackwindow.rb +15 -0
  65. data/code/superant.com.rwdtinkerbackwindow/rwdtinkerwin2version.rb +13 -0
  66. data/code/superant.com.rwdtinkerbackwindow/saveconfigurationrecord.rb +19 -0
  67. data/code/superant.com.rwdtinkerbackwindow/viewappletcontents.rb +22 -0
  68. data/code/superant.com.rwdtinkerbackwindow/viewgemappletcontents.rb +24 -0
  69. data/code/zz0applicationend/zz0end.rb +4 -0
  70. data/configuration/language.dist +8 -0
  71. data/configuration/rwdapplicationidentity.dist +3 -0
  72. data/configuration/rwdtinker.dist +15 -0
  73. data/configuration/rwdwdialogmap-0.01.dist +13 -0
  74. data/configuration/tinkerwin2variables.dist +18 -0
  75. data/gui/00coreguibegin/applicationguitop.rwd +4 -0
  76. data/gui/frontwindow0/cc0openphoto.rwd +22 -0
  77. data/gui/frontwindowselections/00selectiontabbegin.rwd +11 -0
  78. data/gui/frontwindowselections/jumplinkcommands.rwd +15 -0
  79. data/gui/frontwindowselections/wwselectionend.rwd +3 -0
  80. data/gui/frontwindowtdocuments/00documentbegin.rwd +6 -0
  81. data/gui/frontwindowtdocuments/tinkerdocuments.rwd +14 -0
  82. data/gui/frontwindowtdocuments/zzdocumentend.rwd +8 -0
  83. data/gui/helpaboutbegin/zzzrwdlasttab.rwd +6 -0
  84. data/gui/helpaboutbegin/zzzzhelpscreenstart.rwd +3 -0
  85. data/gui/helpaboutbegin/zzzzzzhelpabouttab.rwd +15 -0
  86. data/gui/helpaboutzend/helpscreenend.rwd +3 -0
  87. data/gui/helpaboutzend/zhelpscreenstart2.rwd +3 -0
  88. data/gui/helpaboutzend/zzzzhelpabout2.rwd +15 -0
  89. data/gui/helpaboutzend/zzzzhelpscreen2end.rwd +3 -0
  90. data/gui/tinkerbackwindows/superant.com.dialogmap/10appletbegin.rwd +4 -0
  91. data/gui/tinkerbackwindows/superant.com.dialogmap/12dialogview.rwd +65 -0
  92. data/gui/tinkerbackwindows/superant.com.dialogmap/15aviewxml.rwd +32 -0
  93. data/gui/tinkerbackwindows/superant.com.dialogmap/17aviewxml.rwd +28 -0
  94. data/gui/tinkerbackwindows/superant.com.dialogmap/21editnote.rwd +33 -0
  95. data/gui/tinkerbackwindows/superant.com.dialogmap/67viewconfiguration.rwd +29 -0
  96. data/gui/tinkerbackwindows/superant.com.dialogmap/81jumplinkcommands.rwd +17 -0
  97. data/gui/tinkerbackwindows/superant.com.dialogmap/9end.rwd +6 -0
  98. data/gui/tinkerbackwindows/superant.com.tinkerbackwindow/1appname.rwd +5 -0
  99. data/gui/tinkerbackwindows/superant.com.tinkerbackwindow/40rwdlistzips.rwd +41 -0
  100. data/gui/tinkerbackwindows/superant.com.tinkerbackwindow/45installremotezip.rwd +44 -0
  101. data/gui/tinkerbackwindows/superant.com.tinkerbackwindow/50rwdlistapplets.rwd +44 -0
  102. data/gui/tinkerbackwindows/superant.com.tinkerbackwindow/60editconfiguration.rwd +30 -0
  103. data/gui/tinkerbackwindows/superant.com.tinkerbackwindow/70rwddiagnostics.rwd +29 -0
  104. data/gui/tinkerbackwindows/superant.com.tinkerbackwindow/81jumplinkcommands.rwd +17 -0
  105. data/gui/tinkerbackwindows/superant.com.tinkerbackwindow/9backend.rwd +6 -0
  106. data/gui/tinkerbackwindows/superant.com.tinkerhelpwindow/1appname.rwd +31 -0
  107. data/gui/tinkerbackwindows/superant.com.tinkerhelpwindow/9end.rwd +4 -0
  108. data/gui/tinkerbackwindows/superant.com.versionwindow/1appname.rwd +19 -0
  109. data/gui/tinkerbackwindows/superant.com.versionwindow/helpaboutwindow.rwd +17 -0
  110. data/gui/zzcoreguiend/yy9rwdend.rwd +4 -0
  111. data/init.rb +277 -0
  112. data/installed/dialogmapdata2.inf +2 -0
  113. data/installed/rwdwdialogmap-0.01.inf +8 -0
  114. data/installed/temp.rb +1 -0
  115. data/lang/en/rwdcore/languagefile.rb +58 -0
  116. data/lang/es/rwdcore/languagefile-es.rb +62 -0
  117. data/lang/fr/rwdcore/languagefile.rb +64 -0
  118. data/lang/jp/rwdcore/languagefile.rb +72 -0
  119. data/lang/nl/rwdcore/languagefile.rb +75 -0
  120. data/lib/rconftool.rb +387 -0
  121. data/lib/rwd/browser.rb +123 -0
  122. data/lib/rwd/ftools.rb +174 -0
  123. data/lib/rwd/mime.rb +328 -0
  124. data/lib/rwd/net.rb +876 -0
  125. data/lib/rwd/ruby.rb +889 -0
  126. data/lib/rwd/rwd.rb +1422 -0
  127. data/lib/rwd/sgml.rb +236 -0
  128. data/lib/rwd/thread.rb +63 -0
  129. data/lib/rwd/tree.rb +371 -0
  130. data/lib/rwd/xml.rb +101 -0
  131. data/lib/rwdthemes/default.rwd +317 -0
  132. data/lib/rwdthemes/pda.rwd +72 -0
  133. data/lib/rwdthemes/windowslike.rwd +171 -0
  134. data/lib/zip/ioextras.rb +114 -0
  135. data/lib/zip/stdrubyext.rb +111 -0
  136. data/lib/zip/tempfile_bugfixed.rb +195 -0
  137. data/lib/zip/zip.rb +1378 -0
  138. data/lib/zip/zipfilesystem.rb +558 -0
  139. data/lib/zip/ziprequire.rb +61 -0
  140. data/rwd_files/HowTo_DialogMap.txt +233 -0
  141. data/rwd_files/HowTo_Tinker.txt +482 -0
  142. data/rwd_files/HowTo_TinkerWin2.txt +202 -0
  143. data/rwd_files/Notes/Another Brain Jam.mm +116 -0
  144. data/rwd_files/Notes/HR.xml +2 -0
  145. data/rwd_files/Notes/TaoistBooks.mm +82 -0
  146. data/rwd_files/Readme.txt +57 -0
  147. data/rwd_files/RubyWebDialogs.html +6 -0
  148. data/rwd_files/favicon.ico +0 -0
  149. data/rwd_files/rdoc-style.css +175 -0
  150. data/rwd_files/rwdapplications.html +54 -0
  151. data/rwd_files/tinker.png +0 -0
  152. data/rwdconfig.dist +22 -0
  153. data/rwddialogmap.rb +1 -0
  154. data/tests/RubyGauge.rb +179 -0
  155. data/tests/checkdepends.sh +4 -0
  156. data/tests/cleancnf.sh +6 -0
  157. data/tests/makedist-rwdwdialogmap.rb +58 -0
  158. data/tests/makedist.rb +65 -0
  159. data/tests/rdep.rb +354 -0
  160. data/tests/totranslate.lang +93 -0
  161. data/zips/rwdwaddresses-1.06.zip +0 -0
  162. data/zips/rwdwcalc-0.62.zip +0 -0
  163. data/zips/rwdwdialogmap-0.01.zip +0 -0
  164. data/zips/rwdwfoldeditor-0.04.zip +0 -0
  165. data/zips/rwdwgutenberg-0.09.zip +0 -0
  166. data/zips/rwdwruby-1.07.zip +0 -0
  167. data/zips/temp.rb +1 -0
  168. data/zips/tinkerbellw-0.02.zip +0 -0
  169. data/zips/wrubyslippers-1.06.zip +0 -0
  170. metadata +226 -0
@@ -0,0 +1,12 @@
1
+ # this code is to list the applets that are installed
2
+ def listinstalledfiles
3
+ fileList = Dir.new("installed").entries.sort.reverse.delete_if { |x| ! (x =~ /inf$/) }
4
+ @filesresult = fileList.rwd_method("fillappletname")
5
+ end
6
+
7
+ def fillappletname(inffile)
8
+ applet = inffile.gsub(/\.inf$/, "")
9
+ @a_installlist = applet
10
+ @a_removeapplet = applet
11
+ end
12
+
@@ -0,0 +1,33 @@
1
+ # this code is to list the zipped applets that can be installed
2
+ def fillziptoinstallname(inffile)
3
+ applet = inffile.gsub(/\.zip$/, "")
4
+ @a_installapplet = applet
5
+
6
+ end
7
+
8
+ def listzipfilestoinstall
9
+
10
+ if $zipslocation.slice(0,1) == "/" || $zipslocation.include?(":")
11
+ startlangdir = $zipslocation
12
+ else
13
+ startlangdir = File.join($progdir, $zipslocation )
14
+ end
15
+
16
+ #get a list of the files and subdirectories on the starting directory only
17
+
18
+
19
+ a = Array.new(Dir["#{startlangdir}/*"].entries.sort)
20
+
21
+ #loop through and get the files names
22
+ a.each do |x|
23
+ # only zip files
24
+ if x =~ /\.zip/
25
+ #adds the file to the array to display on the screen
26
+ $zipsarraylocal = $zipsarraylocal | ["#{x}"]
27
+ end
28
+
29
+ end
30
+
31
+ @zipslistresult = $zipsarraylocal.rwd_method("fillziptoinstallname")
32
+ end
33
+
@@ -0,0 +1,22 @@
1
+ # this method puts the configuration rexord on the screen
2
+ def loadconfigurationrecord
3
+
4
+ require 'fileutils'
5
+ if TinkerWin2ConfigurationFileName
6
+ @a_configurationfilename = TinkerWin2ConfigurationFileName
7
+ end
8
+
9
+ begin # exception trapped block
10
+
11
+ Dir.chdir($progdir)
12
+ fileName = File.join(ConfigurationDir, TinkerWin2ConfigurationFileName)
13
+
14
+ fd = File.open(fileName,"r")
15
+ @a_configurationfile = fd.read
16
+ fd.close
17
+ rescue SystemCallError, StandardError
18
+ $stderr.print "system call error: " + $!
19
+ end # exception rescue
20
+
21
+ end
22
+
@@ -0,0 +1,14 @@
1
+ # this method loads the on screen variables into the running class
2
+ def loadconfigurationvariables
3
+
4
+ configfiletoload = File.join(ConfigurationDir,TinkerWin2ConfigurationFileName)
5
+ begin
6
+ load configfiletoload
7
+ @extraconfigdatadisplay = ""
8
+ @newconfigurationresult = "Config Variables loaded"
9
+ rescue
10
+ @extraconfigdatadisplay = ""
11
+ @newconfigurationresult = "loading error"
12
+ end
13
+ end
14
+
@@ -0,0 +1,87 @@
1
+ #network
2
+ require 'socket' # Network stuff
3
+ require 'timeout' # Timeout functions
4
+
5
+ def network_start
6
+ if RUBY_PLATFORM != "i386-mswin32"
7
+ processone = fork {
8
+ network_demon }
9
+ Process.detach(processone)
10
+
11
+ else
12
+ puts "fork not tried winXP?"
13
+ end
14
+ @viewremotecommandresult = "starting controller on next available port"
15
+ end
16
+
17
+ def network_demon
18
+ # Find configuration variables
19
+ host = "127.0.0.1"
20
+ port = $rwdcontrolports[0].to_i
21
+
22
+ openportfound = false
23
+ until openportfound
24
+
25
+ # Create a socket to listen on and bind it to the host and port
26
+ begin
27
+ @socket = UDPSocket::new()
28
+ @socket.bind(host, port)
29
+ # Rescue the "Address in use" error
30
+ openportfound = true
31
+
32
+ rescue Errno::EADDRINUSE
33
+ puts "controller startup: Port #{port} on host #{host} is already in use."
34
+ port=port+1
35
+ # Rescue the "Address not available' error
36
+ rescue Errno::EADDRNOTAVAIL
37
+ puts "Network plugin: Address #{host} is not available to bind."
38
+ port=port+1
39
+ # Rescue "permission denied errors
40
+ rescue Errno::EACCES
41
+ puts "controller startup: Access denied when binding interface addresses. Did you try to bind a port under 1024 as a regular user?"
42
+ port=port+1
43
+ # Rescue all other errors
44
+ rescue
45
+ puts "Network plugin: An error occured."
46
+ port = port+1
47
+ # Rescue all other errors
48
+ end
49
+
50
+ end
51
+
52
+
53
+ # Get all acceptable hosts
54
+ hosts = ["localhost","vaio-sag"]
55
+ # Do some nice errorchecking
56
+ if(hosts.type != Array)
57
+ puts "Network plugin: No hosts found in networkConfig/acceptHosts. Shutting down plugin."
58
+ return -1 # Return the errorcode for plugin failure
59
+ end
60
+
61
+ # Main loop
62
+ while(true)
63
+ # Get data and client data from the client
64
+ data, info = @socket.recvfrom(256)
65
+
66
+ # Is this an acceptable IP address?
67
+ if(hosts.include?(info[2]) || hosts.include?(info[3]))
68
+ command, parameter = data.split(';')
69
+
70
+ # Command actions
71
+ command.downcase!()
72
+ case command
73
+
74
+ when 'stop'
75
+ @socket.send("hello world",0,info[3],info[1].to_i)
76
+
77
+ when 'query'
78
+ @socket.send("#{$rwdapplicationidentity} on port #{$port}",0,info[3],info[1].to_i)
79
+
80
+
81
+ end # case command
82
+
83
+ end # Access control if
84
+ end # while(true)
85
+
86
+ end # Network::start()
87
+
@@ -0,0 +1,19 @@
1
+ def openappletname
2
+ require 'fileutils'
3
+ nametext = "%s" % [@a_installlist]
4
+
5
+ begin # exception trapped block
6
+ fileName = "installed/" + nametext + ".inf"
7
+
8
+ fd = File.open(fileName,"r")
9
+ @displaytext = " "
10
+ while ! fd.eof?
11
+ @displaytext = fd.read
12
+ end
13
+ fd.close
14
+ rescue
15
+ @displaytext = "\n" + "error"
16
+ end # exception rescue
17
+
18
+ end
19
+
@@ -0,0 +1,38 @@
1
+ # this code is to call the help window
2
+ def runhelpwindowtinkerwin2
3
+
4
+ # $helptopicsarray = $helptopicsarray | [""]
5
+
6
+ $help_topic = "tinkerwin2_help"
7
+ if @rwd_tab == "rwdzipslister"
8
+ $help_topic = "tinkerwin2_help"
9
+ end
10
+
11
+ if @rwd_tab == "filelister"
12
+ $help_topic = "applet_viewing"
13
+
14
+ end
15
+ if @rwd_tab == "zipslister"
16
+ $help_topic = "applet_installation"
17
+
18
+ end
19
+ if @rwd_tab == "editconfigurationfile"
20
+ $help_topic = "applet_tinkerbackeditconfiguration"
21
+
22
+ end
23
+ if @rwd_tab == "superantcomremotezipsinstall"
24
+ $help_topic = "remotegemapplet_install"
25
+ end
26
+
27
+
28
+ if @rwd_window != "rwdtinkerhelpwindow"
29
+ $previouswindow = @rwd_window
30
+ $previoustab = @rwd_tab
31
+ else
32
+ $previouswindow = @rwd_window
33
+ $previoustab = @rwd_tab
34
+ end
35
+ runhelpwindow
36
+ end
37
+
38
+
@@ -0,0 +1,24 @@
1
+ # This tinker method is to retrieve the list of rwdzip applets available to install from the remote repository
2
+ def superantcomremotegemlist
3
+ gemcommandoption = "search --remote "
4
+ gemfilename = "rwdzip"
5
+ commandtext = "gem search --remote rwdzip"
6
+ commandtemp = $xpcommand + commandtext
7
+ begin # exception trapped block
8
+
9
+ tempremotegemappletsresult = `#{commandtemp} 2>&1`
10
+ @superantcomremotegemappletsfullresult = tempremotegemappletsresult
11
+ fileList = tempremotegemappletsresult.split(/\n/).delete_if { |x| ! (x =~ /\Arwdzip/) }
12
+
13
+ @superantcomremotegemappletsresult = fileList.rwd_method("superantcomremotegemappletdirsname")
14
+ rescue SystemCallError, StandardError
15
+ @superantcomremotegemappletsresult = "system call error: " + $!
16
+ end # exception rescue
17
+ end
18
+
19
+ def superantcomremotegemappletdirsname(inffile)
20
+ applet = inffile
21
+ @superantcominstallremoteappletinput = applet
22
+
23
+ end
24
+
@@ -0,0 +1,46 @@
1
+ # method to remove a tinker applet
2
+ def removeapplet
3
+ require 'fileutils'
4
+ nametext = "%s" % [@a_removeapplet]
5
+
6
+ fileName = "installed/" + nametext + ".inf"
7
+ @appletremoveresult = removeappletvariables(nametext)
8
+
9
+ setuphelpaboutoptions # update the help about list
10
+ setuptinkerdocuments # update the document pull down list
11
+ runhelpwindow # update the help menu
12
+ showjumplinkoptions # update the application link menu
13
+ runrwdtinkerbackwindow # back to applet window
14
+
15
+ begin # exception trapped block
16
+
17
+ count = 0
18
+ fd = File.open(fileName,"r")
19
+
20
+
21
+ fd.each { |oneline|
22
+ if count == 1
23
+ if File.exist?(oneline.chop)
24
+ FileUtils.rm_rf( oneline.chop)
25
+ end
26
+
27
+ end
28
+ count = 1
29
+ }
30
+ fd.close
31
+
32
+
33
+
34
+ FileUtils.rm_rf( fileName)
35
+
36
+
37
+ @removeapplettext = "applet files removed!" + " " + @appletremoveresult
38
+
39
+ runbackwindowappletremove
40
+
41
+ rescue
42
+ @removeapplettext = " removeapplet" + " .."
43
+
44
+ end # exception rescue
45
+
46
+ end
@@ -0,0 +1,52 @@
1
+
2
+ #***********************************************************************
3
+ #* Rwd/Tinker -- A Ruby program for the RudyWebDialog.
4
+ #* Copyright (c) 2004 - 2005 by Steven Gibson. All Rights Reserved.
5
+ #*
6
+ #* This library is free software; you can redistribute it and/or
7
+ #* modify it under the terms of the GNU General Public
8
+ #* License as published by the Free Software Foundation; either
9
+ #* .
10
+ #*
11
+ #* These files are distributed in the hope that they will be useful,
12
+ #* but WITHOUT ANY WARRANTY; without even the implied warranty of
13
+ #* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14
+ #* General Public License for more details.
15
+ #*
16
+ #* You should have received a copy of the GNU General Public
17
+ #* License along with these files; if not, write to the Free Software
18
+ #* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
19
+ #*
20
+ #* For further information please contact the author by e-mail
21
+ #* at "steven@superant.com".
22
+ #***********************************************************************/
23
+
24
+ def removeappletvariables(tempremovename)
25
+
26
+ begin # exception trapped block
27
+ if $DEBUG
28
+ $stderr.puts "in removeappletvariables"
29
+ end
30
+ # removefileinf = File.open(tempremove){|f| f.read}
31
+
32
+ temp = tempremovename.gsub("-","_")
33
+ removemethod = temp.gsub(".","_")
34
+
35
+
36
+ send "#{removemethod}"
37
+
38
+ tmpremoveapplet = " successfull applet variable removal "
39
+
40
+ rescue
41
+
42
+ tmpremoveapplet = " removeappletvariables .."
43
+
44
+ end # exception rescue
45
+
46
+ return tmpremoveapplet
47
+
48
+ end
49
+
50
+
51
+
52
+
@@ -0,0 +1,11 @@
1
+ # Application RwdTinker orginally (c) 2004 Steven Gibson under GPL.
2
+ # This application is a framework for writing programs from RubyWebDialogs
3
+ # For information see http://www.rubyforge.net/projects/rwdapplications
4
+
5
+ # call the rwdtinker helpwindow
6
+
7
+ def runremotezipsinstall
8
+ @rwd_window = "tinkerbackwindow"
9
+ @rwd_tab = "superantcomremotezipsinstall"
10
+ end
11
+
@@ -0,0 +1,15 @@
1
+ # Application RwdTinker orginally (c) 2004 Steven Gibson under GPL.
2
+ # This application is a framework for writing programs from RubyWebDialogs
3
+ # For information see http://www.rubyforge.net/projects/rwdapplications
4
+
5
+ # call the rwdtinker helpwindow
6
+
7
+ def runrwdtinkerbackwindow
8
+ @rwd_window = "tinkerbackwindow"
9
+ @rwd_tab = "rwdzipslister"
10
+ end
11
+
12
+ def runbackwindowappletremove
13
+ @rwd_window = "tinkerbackwindow"
14
+ @rwd_tab = "filelister"
15
+ end
@@ -0,0 +1,13 @@
1
+ # Application RwdTinker orginally (c) 2004 Steven Gibson under GPL.
2
+ # This application is a framework for writing programs from RubyWebDialogs
3
+ # For information see http://www.rubyforge.net/projects/rwdapplications
4
+
5
+ # return the version constant defined in the config file
6
+ def runrwdtinkerwin2version
7
+ @rwd_window = "applicationversion"
8
+ @versionappnamedisplay = "RwdTinkerWin2"
9
+ @versioncopyrightdisplay = "(c) 2004 Steven Gibson "
10
+ @versionnumberdisplay = "Version " + RwdTinkerWin2Version
11
+
12
+ end
13
+
@@ -0,0 +1,19 @@
1
+ # this method saves the configuration record
2
+ def saveconfigurationrecord
3
+ require 'fileutils'
4
+ if @a_configurationfilename
5
+ newname = "%s" % [@a_configurationfilename] # grab the filename to create
6
+ newdata =@a_configurationfile
7
+
8
+ begin # exception trapped block
9
+ fileName = File.join( ConfigurationDir, newname )
10
+ fd = File.open(fileName,"w")
11
+ fd.print(newdata) # save the record info to the file
12
+ fd.close
13
+ @newconfigurationresult=newdata # show the record info in the browser
14
+ rescue SystemCallError, StandardError
15
+ $stderr.print "system call error: " + $!
16
+ end # exception rescue
17
+ end
18
+ end
19
+
@@ -0,0 +1,22 @@
1
+ #view contents of a tinker applet
2
+ def viewappletcontents
3
+ require 'fileutils'
4
+ require 'lib/zip/zip'
5
+ nametext = "%s" % [@a_installapplet]
6
+
7
+ begin # exception trapped block
8
+ fullname = nametext + ".zip"
9
+ fileName = File.join($zipslocation,fullname)
10
+ tempfilecontents = " "
11
+ zf = Zip::ZipFile.new(fileName)
12
+ zf.sort.each {
13
+ |entry|
14
+ tempfilecontents = tempfilecontents + entry.to_s + "\n"
15
+ }
16
+ @appletcontentstext = tempfilecontents
17
+
18
+ rescue
19
+ @installapplettext = "unzip error - error opening applet"
20
+ end # exception rescue
21
+
22
+ end
@@ -0,0 +1,24 @@
1
+ #view gem info
2
+ def viewgemappletcontents
3
+ require 'fileutils'
4
+ require 'lib/zip/zip'
5
+ nametext = "%s" % [@a_installapplet]
6
+
7
+ begin # exception trapped block
8
+ fullname = nametext + ".zip"
9
+
10
+ tempfilecontents = " "
11
+ zf = Zip::ZipFile.new(fullname)
12
+ zf.sort.each {
13
+ |entry|
14
+ tempfilecontents = tempfilecontents + entry.to_s + "\n"
15
+ }
16
+ @appletcontentstext = tempfilecontents
17
+
18
+ rescue
19
+ @installapplettext = "unzip error - error opening applet"
20
+ end # exception rescue
21
+
22
+ end
23
+
24
+
@@ -0,0 +1,4 @@
1
+
2
+
3
+ end # end of rwdtinker class
4
+
@@ -0,0 +1,8 @@
1
+ ##VERSION: (1.79)
2
+ #language selection file
3
+ ##NAME: ($lang):(1.78)
4
+ #$lang = "jp"
5
+ $lang= "en"
6
+ #$lang= "nl"
7
+ #$lang= "es"
8
+ #$lang= "fr"
@@ -0,0 +1,3 @@
1
+ ##VERSION: (1.79)
2
+ $rwdapplicationidentity = "rwdtinker main application"
3
+
@@ -0,0 +1,15 @@
1
+ ##VERSION: (1.79)
2
+ ConfigurationDir = "configuration" # for use in program - init.rb has this value without using this constant
3
+ CodeName = "rwdtinker"
4
+ CodeNameFile = CodeName + ".rb"
5
+ RWDFile = "rwdtinker.rwd"
6
+ LangDir = "lang"
7
+ CodeDir = "code"
8
+ GuiDir = "gui"
9
+ $help_topic = "general_help"
10
+ $prevouswindow ="main"
11
+ $rwdcontrolports =["13713","13714","13715","13716"] # remote control code not actived 2007
12
+ $port = 7705
13
+ Browser_Exe = 'mozilla '
14
+ RwdTinkerVersion = "1.79"
15
+
@@ -0,0 +1,13 @@
1
+ ##VERSION: (0.01)
2
+ ##NAME: ($rwddialogmap_directory):(0.01)
3
+ $rwddialogmap_directory = "rwd_files"
4
+ ##NAME: ($dialogmapbrowser):(0.01)
5
+ $dialogmapbrowser = "firefox"
6
+ $tinkerhelpaboutarray += ["RwdDialogMap"]
7
+ $tinkerdocumentsarray += ["HowTo_DialogMap.txt"]
8
+ JumpLink.update(:RwdDialogMap=>"runrwddialogmapmain")
9
+ $rwdjumplink +=["RwdDialogMap"]
10
+ $dialogchoicepull = ["default.dlg"]
11
+ ##NAME: (RwdDialogMapVersion):(0.01)
12
+ RwdDialogMapVersion = "0.01"
13
+
@@ -0,0 +1,18 @@
1
+ ##VERSION: (1.79)
2
+ TinkerWin2ConfigurationFileName = "tinkerwin2variables.cnf" # this file name - do not change
3
+ ##NAME: ($zipslocation):(1.78)
4
+ $zipslocation = "zips" # location of applets to add
5
+ $zipsarray = [""]
6
+ $zipsarraylocal = [""]
7
+ ##NAME: ($xpcommand):(1.78)
8
+ $xpcommand = " " # Linux machines
9
+ # $xpcommand = "cmd /C " # XP machines with cmd shell
10
+ ##NAME: ($gemdirectory_withgemfiles):(1.78)
11
+ $gemdirectory_withgemfiles = "/var/lib/gems/1.8/gems"
12
+ # $gemdirectory_withgemfiles = "c:\\ruby\\lib\\ruby\\gems\\1.8\\gems" # XP machine
13
+ ##NAME: ($geminstalled_directory):(1.78)
14
+ # $geminstalled_directory = "/ruby/lib/ruby/gems/1.8/gems" # XP machine
15
+ $geminstalled_directory = "/var/lib/gems/1.8/gems" # Debian Linux
16
+
17
+ RwdTinkerWin2Version = "1.79"
18
+
@@ -0,0 +1,4 @@
1
+ $rwdguivar=
2
+ "<application>
3
+ <window name=\"main\" title=\"RwdDialogmap - RwdTinker for Ruby\">
4
+ <tabs>"
@@ -0,0 +1,22 @@
1
+ $rwdguivar=
2
+
3
+ "
4
+ <tab name=\"viewtinkerlogo\" caption=\"Tinker\">
5
+
6
+ <table>
7
+ <row> <p align=\"right\">#{Message[:tinker_logo]}</row>
8
+
9
+ </table>
10
+ <image src=\"tinker.png\"> </image>
11
+ <table>
12
+ <row> <p></row>
13
+
14
+ </table>
15
+ <horizontal>
16
+
17
+ <button caption=#{Message[:help]} action=\"runhelpwindow\"/>
18
+
19
+
20
+ </horizontal>
21
+
22
+ </tab>"
@@ -0,0 +1,11 @@
1
+ $rwdguivar=
2
+ "
3
+ <tab name=\"selectiontab\" caption=#{Message[:menu_panel]}>
4
+
5
+ <table>
6
+ <row> <p align=\"right\">Open a new location </row>
7
+
8
+ </table>
9
+ "
10
+
11
+
@@ -0,0 +1,15 @@
1
+ $rwdguivar=
2
+ "
3
+ <horizontal>
4
+ <button caption=#{Message[:showjump_links]} action=\"showjumplinkoptions\"/>
5
+ <button caption=#{Message[:help]} action=\"runhelpwindowtinkerwin2\"/>
6
+ </horizontal>
7
+ <table>
8
+ <select name=\"a_jumplinkinput\"> %%jumplinkoptions%% </select>
9
+
10
+ </table>
11
+
12
+ <horizontal>
13
+ <button caption=#{Message[:jumptoapplication_location]} action=\"runjumplinkcommand\"/>
14
+ </horizontal>
15
+ "
@@ -0,0 +1,3 @@
1
+ $rwdguivar=
2
+ "
3
+ </tab>"
@@ -0,0 +1,6 @@
1
+ $rwdguivar=
2
+ "
3
+ <tab name=\"documentsrwdtinkerone\" caption=#{Message[:documents]}>
4
+ <horizontal>
5
+ <table>"
6
+
@@ -0,0 +1,14 @@
1
+ $rwdguivar=
2
+ "
3
+ <horizontal>
4
+ <button caption=#{Message[:showdocument_list]} action=\"setuptinkerdocuments\"/>
5
+
6
+ </horizontal>
7
+ <table>
8
+ <select name=\"a_tinkerdocumentinput\"> %%tinkerdocumentsarray%% </select>
9
+
10
+ </table>
11
+ <horizontal>
12
+ <button caption=#{Message[:open_document]} action=\"runopentinkerdocument\"/>
13
+ </horizontal>
14
+ "
@@ -0,0 +1,8 @@
1
+ $rwdguivar=
2
+ "
3
+ <horizontal>
4
+ <button caption=#{Message[:help]} action=\"runhelpwindow\"/>
5
+
6
+ </horizontal>
7
+ </tab>"
8
+
@@ -0,0 +1,6 @@
1
+ $rwdguivar=
2
+ "
3
+ </tabs>
4
+ </window>"
5
+
6
+
@@ -0,0 +1,3 @@
1
+ $rwdguivar=
2
+ "
3
+ <helpwindow name=\"main\" title=#{Message[:help_about]}>"
@@ -0,0 +1,15 @@
1
+ $rwdguivar=
2
+ "
3
+ <horizontal>
4
+ <button caption=#{Message[:showhelpabout_links]} action=\"setuphelpaboutoptions\"/>
5
+
6
+ </horizontal>
7
+ <table>
8
+ <select name=\"a_helpaboutinput\"> %%helpaboutoptions%% </select>
9
+
10
+ </table>
11
+
12
+ <horizontal>
13
+ <button caption=#{Message[:openselectedhelp_about]} action=\"runrwdtinkerversion\"/>
14
+ </horizontal>
15
+ "
@@ -0,0 +1,3 @@
1
+ $rwdguivar=
2
+ "
3
+ </helpwindow>"