Permalink
Browse files

fixed bug on gtk::layout.bind

  • Loading branch information...
1 parent 413d421 commit 4a558da32635b57aab17bd3ad52d809776687a7a andrea@SONGOKU committed Nov 6, 2009
Showing with 3 additions and 2 deletions.
  1. +3 −2 lib/freightrain/binding/rubygnome_extensions/gtk_layout.rb
@@ -23,8 +23,8 @@ def elements=(enumerable)
end
end
self.height = @elements.length * @height_factor
- (0...enumerable.length).each do |index|
- @elements[index].value = enumerable[index]
+ @elements.each do |element|
+ element.value = enumerable[@elements.index(element)]
end
end
@@ -38,6 +38,7 @@ def bind(options)
@elements = []
@control = options[:control]
@signals = options[:signals]
+ options[:force] = true
selected_callback = @signals[:selected]
@signals[:selected] = lambda do |value|
elements.each do |item|

0 comments on commit 4a558da

Please sign in to comment.