glimmer-dsl-opal 0.7.5 → 0.8.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +12 -0
- data/README.md +182 -12
- data/VERSION +1 -1
- data/lib/glimmer-dsl-opal.rb +8 -0
- data/lib/glimmer-dsl-opal/ext/class.rb +10 -0
- data/lib/{file.rb → glimmer-dsl-opal/ext/file.rb} +0 -0
- data/lib/glimmer-dsl-opal/samples/hello/hello_browser.rb +23 -0
- data/lib/glimmer-dsl-opal/samples/hello/hello_computed.rb +27 -0
- data/lib/glimmer-dsl-opal/samples/hello/hello_list_multi_selection.rb +62 -32
- data/lib/glimmer-dsl-opal/samples/hello/hello_list_single_selection.rb +47 -22
- data/lib/glimmer-dsl-opal/samples/hello/hello_message_box.rb +37 -0
- data/lib/glimmer-dsl-opal/samples/hello/hello_pop_up_context_menu.rb +84 -0
- data/lib/glimmer/data_binding/observable_element.rb +1 -1
- data/lib/glimmer/dsl/opal/custom_widget_expression.rb +1 -1
- data/lib/glimmer/dsl/opal/dsl.rb +2 -0
- data/lib/glimmer/dsl/opal/menu_bar_expression.rb +54 -0
- data/lib/glimmer/dsl/opal/menu_expression.rb +61 -0
- data/lib/glimmer/dsl/opal/widget_expression.rb +3 -2
- data/lib/glimmer/dsl/opal/widget_listener_expression.rb +2 -2
- data/lib/glimmer/swt/custom/checkbox_group.rb +2 -2
- data/lib/glimmer/swt/custom/radio_group.rb +2 -2
- data/lib/glimmer/swt/event_listener_proxy.rb +14 -4
- data/lib/glimmer/swt/grid_layout_proxy.rb +1 -0
- data/lib/glimmer/swt/label_proxy.rb +6 -3
- data/lib/glimmer/swt/list_proxy.rb +33 -0
- data/lib/glimmer/swt/menu_item_proxy.rb +87 -0
- data/lib/glimmer/swt/menu_proxy.rb +162 -0
- data/lib/glimmer/swt/message_box_proxy.rb +51 -57
- data/lib/glimmer/swt/property_owner.rb +2 -0
- data/lib/glimmer/swt/radio_proxy.rb +1 -1
- data/lib/glimmer/swt/shell_proxy.rb +32 -187
- data/lib/glimmer/swt/tab_folder_proxy.rb +43 -0
- data/lib/glimmer/swt/table_column_proxy.rb +3 -2
- data/lib/glimmer/swt/table_editor.rb +1 -1
- data/lib/glimmer/swt/table_item_proxy.rb +7 -5
- data/lib/glimmer/swt/table_proxy.rb +10 -0
- data/lib/glimmer/swt/widget_proxy.rb +313 -30
- data/lib/glimmer/ui/custom_shell.rb +1 -1
- data/lib/glimmer/ui/custom_widget.rb +3 -3
- metadata +20 -7
@@ -34,7 +34,7 @@ module Glimmer
|
|
34
34
|
klass.include(Glimmer)
|
35
35
|
Glimmer::UI::CustomWidget.add_custom_widget_namespaces_for(klass)
|
36
36
|
keyword = klass.name.split(':').last.underscore
|
37
|
-
|
37
|
+
LocalStorage[keyword] = $LOADED_FEATURES.last
|
38
38
|
end
|
39
39
|
|
40
40
|
def request_parameter_string
|
@@ -187,13 +187,13 @@ module Glimmer
|
|
187
187
|
result || body_root&.can_handle_observation_request?(observation_request)
|
188
188
|
end
|
189
189
|
|
190
|
-
def handle_observation_request(observation_request,
|
190
|
+
def handle_observation_request(observation_request, block)
|
191
191
|
observation_request = observation_request.to_s
|
192
192
|
if observation_request.start_with?('on_updated_')
|
193
193
|
property = observation_request.sub(/^on_updated_/, '') # TODO look into eliminating duplication from above
|
194
194
|
add_observer(DataBinding::Observer.proc(&block), property) if can_add_observer?(property)
|
195
195
|
else
|
196
|
-
body_root.handle_observation_request(observation_request,
|
196
|
+
body_root.handle_observation_request(observation_request, block)
|
197
197
|
end
|
198
198
|
end
|
199
199
|
|
@@ -267,7 +267,7 @@ module Glimmer
|
|
267
267
|
|
268
268
|
def method_missing(method, *args, &block)
|
269
269
|
if can_handle_observation_request?(method)
|
270
|
-
handle_observation_request(method,
|
270
|
+
handle_observation_request(method, block)
|
271
271
|
else
|
272
272
|
body_root.send(method, *args, &block)
|
273
273
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: glimmer-dsl-opal
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.8.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- AndyMaleh
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2020-12-
|
11
|
+
date: 2020-12-17 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: glimmer
|
@@ -70,16 +70,22 @@ dependencies:
|
|
70
70
|
name: to_collection
|
71
71
|
requirement: !ruby/object:Gem::Requirement
|
72
72
|
requirements:
|
73
|
-
- - "
|
73
|
+
- - ">="
|
74
74
|
- !ruby/object:Gem::Version
|
75
75
|
version: 2.0.1
|
76
|
+
- - "<"
|
77
|
+
- !ruby/object:Gem::Version
|
78
|
+
version: 3.0.0
|
76
79
|
type: :runtime
|
77
80
|
prerelease: false
|
78
81
|
version_requirements: !ruby/object:Gem::Requirement
|
79
82
|
requirements:
|
80
|
-
- - "
|
83
|
+
- - ">="
|
81
84
|
- !ruby/object:Gem::Version
|
82
85
|
version: 2.0.1
|
86
|
+
- - "<"
|
87
|
+
- !ruby/object:Gem::Version
|
88
|
+
version: 3.0.0
|
83
89
|
- !ruby/object:Gem::Dependency
|
84
90
|
name: puts_debuggerer
|
85
91
|
requirement: !ruby/object:Gem::Requirement
|
@@ -210,8 +216,8 @@ dependencies:
|
|
210
216
|
- - "~>"
|
211
217
|
- !ruby/object:Gem::Version
|
212
218
|
version: 0.4.4
|
213
|
-
description: Glimmer DSL for Opal (Pure Ruby Web GUI and Auto-Webifier of
|
214
|
-
Apps
|
219
|
+
description: Glimmer DSL for Opal on Rails (Pure Ruby Web GUI and Auto-Webifier of
|
220
|
+
Desktop Apps)
|
215
221
|
email: andy.am@gmail.com
|
216
222
|
executables: []
|
217
223
|
extensions: []
|
@@ -238,10 +244,11 @@ files:
|
|
238
244
|
- app/assets/stylesheets/glimmer/jquery-ui.theme.css
|
239
245
|
- app/assets/stylesheets/glimmer/jquery.ui.timepicker.css
|
240
246
|
- lib/display.rb
|
241
|
-
- lib/file.rb
|
242
247
|
- lib/glimmer-dsl-opal.rb
|
248
|
+
- lib/glimmer-dsl-opal/ext/class.rb
|
243
249
|
- lib/glimmer-dsl-opal/ext/date.rb
|
244
250
|
- lib/glimmer-dsl-opal/ext/exception.rb
|
251
|
+
- lib/glimmer-dsl-opal/ext/file.rb
|
245
252
|
- lib/glimmer-dsl-opal/ext/struct.rb
|
246
253
|
- lib/glimmer-dsl-opal/samples/elaborate/contact_manager.rb
|
247
254
|
- lib/glimmer-dsl-opal/samples/elaborate/contact_manager/contact.rb
|
@@ -264,6 +271,8 @@ files:
|
|
264
271
|
- lib/glimmer-dsl-opal/samples/hello/hello_group.rb
|
265
272
|
- lib/glimmer-dsl-opal/samples/hello/hello_list_multi_selection.rb
|
266
273
|
- lib/glimmer-dsl-opal/samples/hello/hello_list_single_selection.rb
|
274
|
+
- lib/glimmer-dsl-opal/samples/hello/hello_message_box.rb
|
275
|
+
- lib/glimmer-dsl-opal/samples/hello/hello_pop_up_context_menu.rb
|
267
276
|
- lib/glimmer-dsl-opal/samples/hello/hello_radio.rb
|
268
277
|
- lib/glimmer-dsl-opal/samples/hello/hello_radio_group.rb
|
269
278
|
- lib/glimmer-dsl-opal/samples/hello/hello_tab.rb
|
@@ -308,6 +317,8 @@ files:
|
|
308
317
|
- lib/glimmer/dsl/opal/layout_data_expression.rb
|
309
318
|
- lib/glimmer/dsl/opal/layout_expression.rb
|
310
319
|
- lib/glimmer/dsl/opal/list_selection_data_binding_expression.rb
|
320
|
+
- lib/glimmer/dsl/opal/menu_bar_expression.rb
|
321
|
+
- lib/glimmer/dsl/opal/menu_expression.rb
|
311
322
|
- lib/glimmer/dsl/opal/message_box_expression.rb
|
312
323
|
- lib/glimmer/dsl/opal/observe_expression.rb
|
313
324
|
- lib/glimmer/dsl/opal/property_expression.rb
|
@@ -345,6 +356,8 @@ files:
|
|
345
356
|
- lib/glimmer/swt/layout_proxy.rb
|
346
357
|
- lib/glimmer/swt/list_proxy.rb
|
347
358
|
- lib/glimmer/swt/make_shift_shell_proxy.rb
|
359
|
+
- lib/glimmer/swt/menu_item_proxy.rb
|
360
|
+
- lib/glimmer/swt/menu_proxy.rb
|
348
361
|
- lib/glimmer/swt/message_box_proxy.rb
|
349
362
|
- lib/glimmer/swt/point.rb
|
350
363
|
- lib/glimmer/swt/property_owner.rb
|