Method: Watobo::Gui::DiffFrame#onTableClick

Defined in:
lib/watobo/gui/differ_frame.rb

#onTableClick(sender, sel, item) ⇒ Object



63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
# File 'lib/watobo/gui/differ_frame.rb', line 63

def onTableClick(sender,sel,item)
  begin

    row = item.row
    @historyTable.selectRow(row, false)
    hi = @historyTable.getRowText(row).to_i - 1

    if @first_selection and @second_selection
      @first_selection = nil
      @second_selection = nil
    end

    if !@first_selection
      @first_selection = @history[hi]
    else
      @second_selection = @history[hi]
    end

    updateSelection()

  rescue => bang
    puts "!!!ERROR: onTableClick"
    puts bang
    puts "!!!"

  end
end