Class: Glimmer::SWT::LatestShellProxy
- Inherits:
-
ShellProxy
- Object
- WidgetProxy
- CompositeProxy
- ShellProxy
- Glimmer::SWT::LatestShellProxy
- Defined in:
- lib/glimmer/swt/latest_shell_proxy.rb
Constant Summary
Constants inherited from ShellProxy
ShellProxy::HEIGHT_MIN, ShellProxy::STYLE, ShellProxy::WIDTH_MIN
Constants inherited from WidgetProxy
WidgetProxy::DEFAULT_INITIALIZERS
Instance Attribute Summary
Attributes inherited from ShellProxy
Attributes inherited from WidgetProxy
#args, #background, #children, #disposed?, #enabled, #focus, #font, #foreground, #menu, #menu_requested, #parent, #path, #rendered
Instance Method Summary collapse
-
#initialize(parent, args, block) ⇒ LatestShellProxy
constructor
A new instance of LatestShellProxy.
- #latest_shell ⇒ Object
- #method_missing(method, *args, &block) ⇒ Object
- #open ⇒ Object
- #respond_to?(method, *args, &block) ⇒ Boolean
Methods inherited from ShellProxy
#close, #dom, #element, #hide, #open?, #parent_path, #style_dom_css, #text, #text=
Methods inherited from CompositeProxy
#default_layout, #dom, #get_layout, #layout=, #layout, #pack
Methods inherited from WidgetProxy
#add_content_on_render, #add_css_class, #add_css_classes, #add_observer, #apply_property_type_converters, #build_dom, #can_handle_observation_request?, #clear_css_classes, #content, #content_on_render_blocks, #css_classes, #default_observation_request_to_event_mapping, #dialog_ancestor, #dispose, #dom_element, #effective_observation_request_to_event_mapping, #element, #event_handling_suspended?, #event_listener_proxies, for, #get_data, #handle_observation_request, #has_style?, #id, #id=, #listener_dom_element, #listener_path, max_id_number_for, max_id_numbers, #name, next_id_number_for, #observation_request_to_event_mapping, #observation_requests, #parent_dom_element, #parent_path, #parents, #post_add_content, #post_dispose_child, #post_initialize_child, #property_type_converters, #remove_all_listeners, #remove_css_class, #remove_css_classes, #remove_event_listener_proxies, #render, reset_max_id_numbers!, #resume_event_handling, #selector, #set_attribute, #set_data, #set_focus, #shell, #skip_content_on_render_blocks?, #style_element, #suspend_event_handling, #swt_widget, underscored_widget_name, widget_class, widget_exists?, widget_handling_listener, #widget_property_listener_installers
Methods included from PropertyOwner
#attribute_getter, #attribute_setter, #get_attribute, #set_attribute
Constructor Details
#initialize(parent, args, block) ⇒ LatestShellProxy
Returns a new instance of LatestShellProxy.
27 28 29 |
# File 'lib/glimmer/swt/latest_shell_proxy.rb', line 27 def initialize(parent, args, block) # No Op end |
Dynamic Method Handling
This class handles dynamic methods through the method_missing method
#method_missing(method, *args, &block) ⇒ Object
31 32 33 34 35 36 37 |
# File 'lib/glimmer/swt/latest_shell_proxy.rb', line 31 def method_missing(method, *args, &block) if latest_shell.nil? super(method, *args, &block) else latest_shell.send(method, *args, &block) end end |
Instance Method Details
#latest_shell ⇒ Object
51 52 53 |
# File 'lib/glimmer/swt/latest_shell_proxy.rb', line 51 def latest_shell @latest_shell ||= DisplayProxy.instance.shells.last end |
#open ⇒ Object
43 44 45 46 47 48 49 |
# File 'lib/glimmer/swt/latest_shell_proxy.rb', line 43 def open Document.ready? do DisplayProxy.instance.async_exec { latest_shell&.open } end end |
#respond_to?(method, *args, &block) ⇒ Boolean
39 40 41 |
# File 'lib/glimmer/swt/latest_shell_proxy.rb', line 39 def respond_to?(method, *args, &block) super || latest_shell&.respond_to?(method, *args, &block) end |