4 # Created by Toshi Nagata on 2008/06/27.
5 # Copyright 2008 Toshi Nagata. All rights reserved.
7 # This program is free software; you can redistribute it and/or modify
8 # it under the terms of the GNU General Public License as published by
9 # the Free Software Foundation version 2 of the License.
11 # This program is distributed in the hope that it will be useful,
12 # but WITHOUT ANY WARRANTY; without even the implied warranty of
13 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 # GNU General Public License for more details.
18 def self.run(*args, &block)
19 obj = Dialog.new(*args)
20 obj.instance_eval(&block)
24 alias initialize_orig initialize
26 def initialize(*args, &block)
27 initialize_orig(*args)
28 instance_eval(&block) if block
35 def set_value(tag, value)
36 set_attr(tag, :value=>value)