win_gui 0.1.6 → 0.2.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (169) hide show
  1. data/.gitignore +21 -21
  2. data/HISTORY +7 -0
  3. data/LICENSE +20 -20
  4. data/README.rdoc +77 -114
  5. data/Rakefile +24 -58
  6. data/VERSION +1 -1
  7. data/features/support/env.rb +7 -4
  8. data/features/win_gui.feature +9 -9
  9. data/lib/version.rb +8 -0
  10. data/lib/win_gui/window.rb +78 -69
  11. data/lib/win_gui.rb +25 -3
  12. data/spec/spec.opts +1 -1
  13. data/spec/spec_helper.rb +90 -118
  14. data/spec/win_gui/window_spec.rb +120 -123
  15. data/tasks/common.rake +14 -0
  16. data/tasks/doc.rake +14 -0
  17. data/tasks/gem.rake +39 -0
  18. data/tasks/git.rake +34 -0
  19. data/tasks/spec.rake +19 -0
  20. data/tasks/version.rake +71 -0
  21. metadata +68 -188
  22. data/.document +0 -5
  23. data/book_code/early_success/bundle.rb +0 -34
  24. data/book_code/early_success/english.txt +0 -1
  25. data/book_code/early_success/jruby_basics.rb +0 -47
  26. data/book_code/early_success/windows_basics.rb +0 -97
  27. data/book_code/guessing/locknote.rb +0 -379
  28. data/book_code/guessing/monkeyshines.rb +0 -14
  29. data/book_code/guessing/note.rb +0 -120
  30. data/book_code/guessing/note_spec.rb +0 -175
  31. data/book_code/guessing/replay.rb +0 -21
  32. data/book_code/guessing/seed.rb +0 -9
  33. data/book_code/guessing/spec_helper.rb +0 -69
  34. data/book_code/guessing/windows_gui.rb +0 -247
  35. data/book_code/home_stretch/junquenote.rb +0 -151
  36. data/book_code/home_stretch/locknote.rb +0 -180
  37. data/book_code/home_stretch/note.rb +0 -144
  38. data/book_code/home_stretch/note_spec.rb +0 -191
  39. data/book_code/home_stretch/spec_helper.rb +0 -55
  40. data/book_code/home_stretch/swing_gui.rb +0 -50
  41. data/book_code/home_stretch/windows_gui.rb +0 -232
  42. data/book_code/junquenote/exports.sh +0 -10
  43. data/book_code/junquenote/jruby_mac.sh +0 -10
  44. data/book_code/junquenote/junquenote_app.rb +0 -262
  45. data/book_code/novite/Rakefile +0 -10
  46. data/book_code/novite/app/controllers/application.rb +0 -18
  47. data/book_code/novite/app/controllers/guests_controller.rb +0 -28
  48. data/book_code/novite/app/controllers/parties_controller.rb +0 -77
  49. data/book_code/novite/app/helpers/application_helper.rb +0 -11
  50. data/book_code/novite/app/helpers/guests_helper.rb +0 -10
  51. data/book_code/novite/app/helpers/parties_helper.rb +0 -10
  52. data/book_code/novite/app/models/guest.rb +0 -11
  53. data/book_code/novite/app/models/party.rb +0 -32
  54. data/book_code/novite/app/models/party_mailer.rb +0 -19
  55. data/book_code/novite/app/views/layouts/application.rhtml +0 -44
  56. data/book_code/novite/app/views/parties/new.html.erb +0 -42
  57. data/book_code/novite/app/views/parties/show.html.erb +0 -43
  58. data/book_code/novite/app/views/party_mailer/invite.erb +0 -17
  59. data/book_code/novite/config/boot.rb +0 -117
  60. data/book_code/novite/config/database.yml +0 -19
  61. data/book_code/novite/config/environment.rb +0 -67
  62. data/book_code/novite/config/environments/development.rb +0 -29
  63. data/book_code/novite/config/environments/production.rb +0 -27
  64. data/book_code/novite/config/environments/test.rb +0 -30
  65. data/book_code/novite/config/initializers/inflections.rb +0 -18
  66. data/book_code/novite/config/initializers/mime_types.rb +0 -13
  67. data/book_code/novite/config/routes.rb +0 -47
  68. data/book_code/novite/db/migrate/001_create_parties.rb +0 -26
  69. data/book_code/novite/db/migrate/002_create_guests.rb +0 -23
  70. data/book_code/novite/db/schema.rb +0 -41
  71. data/book_code/novite/log/empty.txt +0 -0
  72. data/book_code/novite/public/.htaccess +0 -40
  73. data/book_code/novite/public/404.html +0 -38
  74. data/book_code/novite/public/422.html +0 -38
  75. data/book_code/novite/public/500.html +0 -38
  76. data/book_code/novite/public/dispatch.cgi +0 -10
  77. data/book_code/novite/public/dispatch.fcgi +0 -24
  78. data/book_code/novite/public/dispatch.rb +0 -18
  79. data/book_code/novite/public/favicon.ico +0 -0
  80. data/book_code/novite/public/images/rails.png +0 -0
  81. data/book_code/novite/public/index.html +0 -285
  82. data/book_code/novite/public/javascripts/application.js +0 -10
  83. data/book_code/novite/public/javascripts/controls.js +0 -971
  84. data/book_code/novite/public/javascripts/dragdrop.js +0 -980
  85. data/book_code/novite/public/javascripts/effects.js +0 -1128
  86. data/book_code/novite/public/javascripts/prototype.js +0 -4233
  87. data/book_code/novite/public/robots.txt +0 -5
  88. data/book_code/novite/script/about +0 -3
  89. data/book_code/novite/script/console +0 -3
  90. data/book_code/novite/script/destroy +0 -3
  91. data/book_code/novite/script/generate +0 -3
  92. data/book_code/novite/script/performance/benchmarker +0 -3
  93. data/book_code/novite/script/performance/profiler +0 -3
  94. data/book_code/novite/script/performance/request +0 -3
  95. data/book_code/novite/script/plugin +0 -3
  96. data/book_code/novite/script/process/inspector +0 -3
  97. data/book_code/novite/script/process/reaper +0 -3
  98. data/book_code/novite/script/process/spawner +0 -3
  99. data/book_code/novite/script/runner +0 -3
  100. data/book_code/novite/script/server +0 -3
  101. data/book_code/novite/test/test_helper.rb +0 -46
  102. data/book_code/one_more_thing/applescript.rb +0 -68
  103. data/book_code/one_more_thing/note_spec.rb +0 -50
  104. data/book_code/one_more_thing/spec_helper.rb +0 -17
  105. data/book_code/one_more_thing/textedit-pure.rb +0 -28
  106. data/book_code/one_more_thing/textedit.applescript +0 -26
  107. data/book_code/one_more_thing/textedit.rb +0 -32
  108. data/book_code/one_more_thing/textnote.rb +0 -87
  109. data/book_code/simplify/junquenote.rb +0 -48
  110. data/book_code/simplify/locknote.rb +0 -46
  111. data/book_code/simplify/note.rb +0 -35
  112. data/book_code/simplify/note_spec.rb +0 -28
  113. data/book_code/simplify/swing_gui.rb +0 -45
  114. data/book_code/simplify/windows_gui.rb +0 -232
  115. data/book_code/simplify/windows_gui_spec.rb +0 -35
  116. data/book_code/story/invite.story +0 -19
  117. data/book_code/story/journal.txt +0 -29
  118. data/book_code/story/novite_stories.rb +0 -156
  119. data/book_code/story/party.rb +0 -149
  120. data/book_code/story/password.rb +0 -61
  121. data/book_code/story/password.story +0 -26
  122. data/book_code/story/rsvp.story +0 -29
  123. data/book_code/tables/TestTime.html +0 -93
  124. data/book_code/tables/TestTimeSample.html +0 -63
  125. data/book_code/tables/calculate_time.rb +0 -39
  126. data/book_code/tables/calculator.rb +0 -108
  127. data/book_code/tables/calculator_actions.rb +0 -27
  128. data/book_code/tables/calculator_spec.rb +0 -47
  129. data/book_code/tables/fit.rb +0 -32
  130. data/book_code/tables/matrix.rb +0 -109
  131. data/book_code/tables/pseudocode.rb +0 -17
  132. data/book_code/tubes/book_selenium.rb +0 -67
  133. data/book_code/tubes/book_watir.rb +0 -60
  134. data/book_code/tubes/dragdrop.html +0 -81
  135. data/book_code/tubes/html_capture.rb +0 -33
  136. data/book_code/tubes/joke_list.rb +0 -67
  137. data/book_code/tubes/list_spec.rb +0 -41
  138. data/book_code/tubes/search_spec.rb +0 -32
  139. data/book_code/tubes/selenium_example.rb +0 -66
  140. data/book_code/tubes/selenium_link.rb +0 -23
  141. data/book_code/tubes/web_server.rb +0 -14
  142. data/book_code/windows/wgui.rb +0 -29
  143. data/book_code/windows/wobj.rb +0 -25
  144. data/book_code/windows/wsh.rb +0 -25
  145. data/book_code/with_rspec/empty_spec.rb +0 -13
  146. data/book_code/with_rspec/junquenote.rb +0 -60
  147. data/book_code/with_rspec/locknote.rb +0 -129
  148. data/book_code/with_rspec/note_spec.rb +0 -32
  149. data/book_code/with_rspec/should_examples.rb +0 -18
  150. data/lib/note/java/jemmy.jar +0 -0
  151. data/lib/note/java/jnote.rb +0 -48
  152. data/lib/note/java/jruby_basics.rb +0 -37
  153. data/lib/note/java/junquenote_app.rb +0 -262
  154. data/lib/note/java/note_spec.rb +0 -20
  155. data/lib/note/win/locknote.rb +0 -19
  156. data/lib/note.rb +0 -15
  157. data/lib/win_gui/constants.rb +0 -82
  158. data/lib/win_gui/def_api.rb +0 -160
  159. data/lib/win_gui/string_extensions.rb +0 -36
  160. data/lib/win_gui/win_gui.rb +0 -437
  161. data/old/windows_basics.rb +0 -80
  162. data/old/wnote.rb +0 -80
  163. data/old/wnote_spec.rb +0 -20
  164. data/spec/note/win/locknote_spec.rb +0 -7
  165. data/spec/test_apps/locknote/LockNote.exe +0 -0
  166. data/spec/win_gui/def_api_spec.rb +0 -339
  167. data/spec/win_gui/string_extensions_spec.rb +0 -61
  168. data/spec/win_gui/win_gui_spec.rb +0 -537
  169. data/win_gui.gemspec +0 -215
@@ -1,18 +0,0 @@
1
- #!/opt/local/bin/ruby
2
- #---
3
- # Excerpted from "Scripted GUI Testing With Ruby",
4
- # published by The Pragmatic Bookshelf.
5
- # Copyrights apply to this code. It may not be used to create training material,
6
- # courses, books, articles, and the like. Contact us if you are in doubt.
7
- # We make no guarantees that this code is fit for any purpose.
8
- # Visit http://www.pragmaticprogrammer.com/titles/idgtr for more book information.
9
- #---
10
-
11
- require File.dirname(__FILE__) + "/../config/environment" unless defined?(RAILS_ROOT)
12
-
13
- # If you're using RubyGems and mod_ruby, this require should be changed to an absolute path one, like:
14
- # "/usr/local/lib/ruby/gems/1.8/gems/rails-0.8.0/lib/dispatcher" -- otherwise performance is severely impaired
15
- require "dispatcher"
16
-
17
- ADDITIONAL_LOAD_PATHS.reverse.each { |dir| $:.unshift(dir) if File.directory?(dir) } if defined?(Apache::RubyRun)
18
- Dispatcher.dispatch
File without changes
@@ -1,285 +0,0 @@
1
- <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
2
- "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
3
- <!--
4
- ! Excerpted from "Scripted GUI Testing With Ruby",
5
- ! published by The Pragmatic Bookshelf.
6
- ! Copyrights apply to this code. It may not be used to create training material,
7
- ! courses, books, articles, and the like. Contact us if you are in doubt.
8
- ! We make no guarantees that this code is fit for any purpose.
9
- ! Visit http://www.pragmaticprogrammer.com/titles/idgtr for more book information.
10
- -->
11
- <html>
12
- <head>
13
- <meta http-equiv="Content-type" content="text/html; charset=utf-8" />
14
- <title>Ruby on Rails: Welcome aboard</title>
15
- <style type="text/css" media="screen">
16
- body {
17
- margin: 0;
18
- margin-bottom: 25px;
19
- padding: 0;
20
- background-color: #f0f0f0;
21
- font-family: "Lucida Grande", "Bitstream Vera Sans", "Verdana";
22
- font-size: 13px;
23
- color: #333;
24
- }
25
-
26
- h1 {
27
- font-size: 28px;
28
- color: #000;
29
- }
30
-
31
- a {color: #03c}
32
- a:hover {
33
- background-color: #03c;
34
- color: white;
35
- text-decoration: none;
36
- }
37
-
38
-
39
- #page {
40
- background-color: #f0f0f0;
41
- width: 750px;
42
- margin: 0;
43
- margin-left: auto;
44
- margin-right: auto;
45
- }
46
-
47
- #content {
48
- float: left;
49
- background-color: white;
50
- border: 3px solid #aaa;
51
- border-top: none;
52
- padding: 25px;
53
- width: 500px;
54
- }
55
-
56
- #sidebar {
57
- float: right;
58
- width: 175px;
59
- }
60
-
61
- #footer {
62
- clear: both;
63
- }
64
-
65
-
66
- #header, #about, #getting-started {
67
- padding-left: 75px;
68
- padding-right: 30px;
69
- }
70
-
71
-
72
- #header {
73
- background-image: url("images/rails.png");
74
- background-repeat: no-repeat;
75
- background-position: top left;
76
- height: 64px;
77
- }
78
- #header h1, #header h2 {margin: 0}
79
- #header h2 {
80
- color: #888;
81
- font-weight: normal;
82
- font-size: 16px;
83
- }
84
-
85
-
86
- #about h3 {
87
- margin: 0;
88
- margin-bottom: 10px;
89
- font-size: 14px;
90
- }
91
-
92
- #about-content {
93
- background-color: #ffd;
94
- border: 1px solid #fc0;
95
- margin-left: -11px;
96
- }
97
- #about-content table {
98
- margin-top: 10px;
99
- margin-bottom: 10px;
100
- font-size: 11px;
101
- border-collapse: collapse;
102
- }
103
- #about-content td {
104
- padding: 10px;
105
- padding-top: 3px;
106
- padding-bottom: 3px;
107
- }
108
- #about-content td.name {color: #555}
109
- #about-content td.value {color: #000}
110
-
111
- #about-content.failure {
112
- background-color: #fcc;
113
- border: 1px solid #f00;
114
- }
115
- #about-content.failure p {
116
- margin: 0;
117
- padding: 10px;
118
- }
119
-
120
-
121
- #getting-started {
122
- border-top: 1px solid #ccc;
123
- margin-top: 25px;
124
- padding-top: 15px;
125
- }
126
- #getting-started h1 {
127
- margin: 0;
128
- font-size: 20px;
129
- }
130
- #getting-started h2 {
131
- margin: 0;
132
- font-size: 14px;
133
- font-weight: normal;
134
- color: #333;
135
- margin-bottom: 25px;
136
- }
137
- #getting-started ol {
138
- margin-left: 0;
139
- padding-left: 0;
140
- }
141
- #getting-started li {
142
- font-size: 18px;
143
- color: #888;
144
- margin-bottom: 25px;
145
- }
146
- #getting-started li h2 {
147
- margin: 0;
148
- font-weight: normal;
149
- font-size: 18px;
150
- color: #333;
151
- }
152
- #getting-started li p {
153
- color: #555;
154
- font-size: 13px;
155
- }
156
-
157
-
158
- #search {
159
- margin: 0;
160
- padding-top: 10px;
161
- padding-bottom: 10px;
162
- font-size: 11px;
163
- }
164
- #search input {
165
- font-size: 11px;
166
- margin: 2px;
167
- }
168
- #search-text {width: 170px}
169
-
170
-
171
- #sidebar ul {
172
- margin-left: 0;
173
- padding-left: 0;
174
- }
175
- #sidebar ul h3 {
176
- margin-top: 25px;
177
- font-size: 16px;
178
- padding-bottom: 10px;
179
- border-bottom: 1px solid #ccc;
180
- }
181
- #sidebar li {
182
- list-style-type: none;
183
- }
184
- #sidebar ul.links li {
185
- margin-bottom: 5px;
186
- }
187
-
188
- </style>
189
- <script type="text/javascript" src="javascripts/prototype.js"></script>
190
- <script type="text/javascript" src="javascripts/effects.js"></script>
191
- <script type="text/javascript">
192
- function about() {
193
- if (Element.empty('about-content')) {
194
- new Ajax.Updater('about-content', 'rails/info/properties', {
195
- method: 'get',
196
- onFailure: function() {Element.classNames('about-content').add('failure')},
197
- onComplete: function() {new Effect.BlindDown('about-content', {duration: 0.25})}
198
- });
199
- } else {
200
- new Effect[Element.visible('about-content') ?
201
- 'BlindUp' : 'BlindDown']('about-content', {duration: 0.25});
202
- }
203
- }
204
-
205
- window.onload = function() {
206
- $('search-text').value = '';
207
- $('search').onsubmit = function() {
208
- $('search-text').value = 'site:rubyonrails.org ' + $F('search-text');
209
- }
210
- }
211
- </script>
212
- </head>
213
- <body>
214
- <div id="page">
215
- <div id="sidebar">
216
- <ul id="sidebar-items">
217
- <li>
218
- <form id="search" action="http://www.google.com/search" method="get">
219
- <input type="hidden" name="hl" value="en" />
220
- <input type="text" id="search-text" name="q" value="site:rubyonrails.org " />
221
- <input type="submit" value="Search" /> the Rails site
222
- </form>
223
- </li>
224
-
225
- <li>
226
- <h3>Join the community</h3>
227
- <ul class="links">
228
- <li><a href="http://www.rubyonrails.org/">Ruby on Rails</a></li>
229
- <li><a href="http://weblog.rubyonrails.org/">Official weblog</a></li>
230
- <li><a href="http://lists.rubyonrails.org/">Mailing lists</a></li>
231
- <li><a href="http://wiki.rubyonrails.org/rails/pages/IRC">IRC channel</a></li>
232
- <li><a href="http://wiki.rubyonrails.org/">Wiki</a></li>
233
- <li><a href="http://dev.rubyonrails.org/">Bug tracker</a></li>
234
- </ul>
235
- </li>
236
-
237
- <li>
238
- <h3>Browse the documentation</h3>
239
- <ul class="links">
240
- <li><a href="http://api.rubyonrails.org/">Rails API</a></li>
241
- <li><a href="http://stdlib.rubyonrails.org/">Ruby standard library</a></li>
242
- <li><a href="http://corelib.rubyonrails.org/">Ruby core</a></li>
243
- </ul>
244
- </li>
245
- </ul>
246
- </div>
247
-
248
- <div id="content">
249
- <div id="header">
250
- <h1>Welcome aboard</h1>
251
- <h2>You&rsquo;re riding Ruby on Rails!</h2>
252
- </div>
253
-
254
- <div id="about">
255
- <h3><a href="rails/info/properties" onclick="about(); return false">About your application&rsquo;s environment</a></h3>
256
- <div id="about-content" style="display: none"></div>
257
- </div>
258
-
259
- <div id="getting-started">
260
- <h1>Getting started</h1>
261
- <h2>Here&rsquo;s how to get rolling:</h2>
262
-
263
- <ol>
264
- <li>
265
- <h2>Create your databases and edit <tt>config/database.yml</tt></h2>
266
- <p>Rails needs to know your login and password.</p>
267
- </li>
268
-
269
- <li>
270
- <h2>Use <tt>script/generate</tt> to create your models and controllers</h2>
271
- <p>To see all available options, run it without parameters.</p>
272
- </li>
273
-
274
- <li>
275
- <h2>Set up a default route and remove or rename this file</h2>
276
- <p>Routes are set up in config/routes.rb.</p>
277
- </li>
278
- </ol>
279
- </div>
280
- </div>
281
-
282
- <div id="footer">&nbsp;</div>
283
- </div>
284
- </body>
285
- </html>
@@ -1,10 +0,0 @@
1
- /***
2
- * Excerpted from "Scripted GUI Testing With Ruby",
3
- * published by The Pragmatic Bookshelf.
4
- * Copyrights apply to this code. It may not be used to create training material,
5
- * courses, books, articles, and the like. Contact us if you are in doubt.
6
- * We make no guarantees that this code is fit for any purpose.
7
- * Visit http://www.pragmaticprogrammer.com/titles/idgtr for more book information.
8
- ***/
9
- // Place your application-specific JavaScript functions and classes here
10
- // This file is automatically included by javascript_include_tag :defaults