class Ui::LayoutMethodModel

Constants

METHODS

Attributes

combo[R]
display[R]

Public Class Methods

new(display, combo) click to toggle source
Calls superclass method
# File lib/roby/gui/relations_view/relations_config.rb, line 161
def initialize(display, combo)
    super()
    @display, @combo = display, combo
end

Public Instance Methods

data(index, role) click to toggle source
# File lib/roby/gui/relations_view/relations_config.rb, line 170
def data(index, role)
    return Qt::Variant.new unless role == Qt::DisplayRole && index.valid?
    Qt::Variant.new(METHODS[index.row])
end
flags(index) click to toggle source
# File lib/roby/gui/relations_view/relations_config.rb, line 177
def flags(index)
    Qt::ItemIsSelectable | Qt::ItemIsEnabled
end
layout_method(index) click to toggle source
# File lib/roby/gui/relations_view/relations_config.rb, line 174
def layout_method(index)
end
rowCount(parent) click to toggle source
# File lib/roby/gui/relations_view/relations_config.rb, line 166
def rowCount(parent)
    return 0 if parent.valid?
    return METHODS.size
end
selected() click to toggle source
# File lib/roby/gui/relations_view/relations_config.rb, line 181
def selected
    index = combo.current_index
    display.layout_method =
        if index == 0 then nil
        else METHODS[index]
        end
    display.update
end