Module: Rubeus::Awt::Setters

Defined in:
lib/rubeus/awt/setters.rb

Class Method Summary collapse

Instance Method Summary collapse

Class Method Details

.included(base) ⇒ Object



6
7
8
9
10
11
12
13
# File 'lib/rubeus/awt/setters.rb', line 6

def self.included(base)
  base.module_eval do
    alias_method :set_preferred_size, :set_preferred_size_rubeus
    alias_method :preferred_size=, :set_preferred_size_rubeus
    alias_method :set_size, :set_size_rubeus
    alias_method :size=, :set_size_rubeus
  end
end

Instance Method Details

#set_preferred_size_rubeus(*args) ⇒ Object



19
20
21
# File 'lib/rubeus/awt/setters.rb', line 19

def set_preferred_size_rubeus(*args)
  java_send :setPreferredSize, [Dimension], Dimension.create(*args)
end

#set_size_rubeus(*args) ⇒ Object



15
16
17
# File 'lib/rubeus/awt/setters.rb', line 15

def set_size_rubeus(*args)
  java_send :setSize, [Dimension], Dimension.create(*args)
end