Method: GGLib::GUIWindow#setFocus

Defined in:
lib/window.rb

#setFocus(object) ⇒ Object



150
151
152
153
154
155
156
157
158
159
# File 'lib/window.rb', line 150

def setFocus(object)
  if @focused!=nil and not @focused.sleeping? #dont blur the object if it is the window or if it is sleeping
    @focused.blur
  end
  if object==nil
    @focused=nil
  else
    @focused=@guiWidgets[object]
  end
end