Class: Thirdeye::Window

Inherits:
Base
  • Object
show all
Defined in:
lib/thirdeye/window.rb

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from Base

i3, #i3

Constructor Details

#initialize(node) ⇒ Window



22
23
24
# File 'lib/thirdeye/window.rb', line 22

def initialize(node)
  @data = node
end

Instance Attribute Details

#dataObject

Returns the value of attribute data.



20
21
22
# File 'lib/thirdeye/window.rb', line 20

def data
  @data
end

Class Method Details

.allObject



4
5
6
# File 'lib/thirdeye/window.rb', line 4

def all
  self.collect_nodes i3.get_tree['nodes']
end

Instance Method Details

#focusObject



34
35
36
# File 'lib/thirdeye/window.rb', line 34

def focus
  i3.command "[con_id=#{window_id}] focus"
end

#idObject



26
27
28
# File 'lib/thirdeye/window.rb', line 26

def id
  data['id']
end

#nameObject



30
31
32
# File 'lib/thirdeye/window.rb', line 30

def name
  data['name']
end