diff options
| author | nagai <nagai@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2004-10-11 04:51:21 +0000 |
|---|---|---|
| committer | nagai <nagai@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2004-10-11 04:51:21 +0000 |
| commit | bbe91bcd1898d544739e41fdf91aa8288526540a (patch) | |
| tree | d280d8542cc44d1cd1a75e8ec87b1f9d231561b7 /ext/tk/lib/tkextlib/bwidget | |
| parent | 28c7b64f14c02a953ba051acd144e4ee5144450e (diff) | |
| download | ruby-bbe91bcd1898d544739e41fdf91aa8288526540a.tar.gz ruby-bbe91bcd1898d544739e41fdf91aa8288526540a.tar.xz ruby-bbe91bcd1898d544739e41fdf91aa8288526540a.zip | |
* ext/tk/lib/tk/*: untabify
git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@7029 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ext/tk/lib/tkextlib/bwidget')
| -rw-r--r-- | ext/tk/lib/tkextlib/bwidget/dialog.rb | 14 | ||||
| -rw-r--r-- | ext/tk/lib/tkextlib/bwidget/listbox.rb | 10 | ||||
| -rw-r--r-- | ext/tk/lib/tkextlib/bwidget/messagedlg.rb | 108 | ||||
| -rw-r--r-- | ext/tk/lib/tkextlib/bwidget/notebook.rb | 2 | ||||
| -rw-r--r-- | ext/tk/lib/tkextlib/bwidget/passwddlg.rb | 2 | ||||
| -rw-r--r-- | ext/tk/lib/tkextlib/bwidget/tree.rb | 22 |
6 files changed, 79 insertions, 79 deletions
diff --git a/ext/tk/lib/tkextlib/bwidget/dialog.rb b/ext/tk/lib/tkextlib/bwidget/dialog.rb index 4a60a7ceb..d175a2d8b 100644 --- a/ext/tk/lib/tkextlib/bwidget/dialog.rb +++ b/ext/tk/lib/tkextlib/bwidget/dialog.rb @@ -43,7 +43,7 @@ class Tk::BWidget::Dialog cmd = self.class::TkCommandNames[0] if keys and keys != None tk_call_without_enc(cmd, @path, '-parent', @relative, - *hash_kv(keys, true)) + *hash_kv(keys, true)) else tk_call_without_enc(cmd, @path, '-parent', @relative) end @@ -64,9 +64,9 @@ class Tk::BWidget::Dialog super(slot) else if slot.to_s == 'relative' - super('parent', value) + super('parent', value) else - super(slot, value) + super(slot, value) end end end @@ -74,16 +74,16 @@ class Tk::BWidget::Dialog def configinfo(slot=nil) if slot if slot.to_s == 'relative' - super('parent') + super('parent') else - super(slot) + super(slot) end else ret = super() if TkComm::GET_CONFIGINFO_AS_ARRAY - ret << ['relative', 'parent'] + ret << ['relative', 'parent'] else - ret['relative'] = 'parent' + ret['relative'] = 'parent' end end end diff --git a/ext/tk/lib/tkextlib/bwidget/listbox.rb b/ext/tk/lib/tkextlib/bwidget/listbox.rb index 102be9a5f..9f505703f 100644 --- a/ext/tk/lib/tkextlib/bwidget/listbox.rb +++ b/ext/tk/lib/tkextlib/bwidget/listbox.rb @@ -30,7 +30,7 @@ class Tk::BWidget::ListBox class Event_for_Items < TkEvent::Event def self._get_extra_args_tbl [ - TkComm.method(:string) # item idenfier + TkComm.method(:string) # item idenfier ] end end @@ -135,19 +135,19 @@ class Tk::BWidget::ListBox def selection_set(*args) tk_send_without_enc('selection', 'set', - *(args.collect{|item| tagid(item)})) + *(args.collect{|item| tagid(item)})) self end def selection_add(*args) tk_send_without_enc('selection', 'add', - *(args.collect{|item| tagid(item)})) + *(args.collect{|item| tagid(item)})) self end def selection_remove(*args) tk_send_without_enc('selection', 'remove', - *(args.collect{|item| tagid(item)})) + *(args.collect{|item| tagid(item)})) self end @@ -177,7 +177,7 @@ class Tk::BWidget::ListBox::Item @listbox = lbox else fail RuntimeError, - "expect Tk::BWidget::ListBox or Tk::BWidget::ListBox::Item for 1st argument" + "expect Tk::BWidget::ListBox or Tk::BWidget::ListBox::Item for 1st argument" end if args[-1].kind_of?(Hash) diff --git a/ext/tk/lib/tkextlib/bwidget/messagedlg.rb b/ext/tk/lib/tkextlib/bwidget/messagedlg.rb index 55cc4ba0d..d7b2bbc32 100644 --- a/ext/tk/lib/tkextlib/bwidget/messagedlg.rb +++ b/ext/tk/lib/tkextlib/bwidget/messagedlg.rb @@ -65,22 +65,22 @@ class Tk::BWidget::MessageDlg @keys.update(slot) if @info - # update @info - slot.each{|k, v| - if TkComm::GET_CONFIGINFO_AS_ARRAY - if (inf = @info.assoc(k)) - inf[-1] = v - else - @info << [k, '', '', '', v] - end - else - if (inf = @info[k]) - inf[-1] = v - else - @info[k] = ['', '', '', v] - end - end - } + # update @info + slot.each{|k, v| + if TkComm::GET_CONFIGINFO_AS_ARRAY + if (inf = @info.assoc(k)) + inf[-1] = v + else + @info << [k, '', '', '', v] + end + else + if (inf = @info[k]) + inf[-1] = v + else + @info[k] = ['', '', '', v] + end + end + } end else # ! Hash @@ -89,20 +89,20 @@ class Tk::BWidget::MessageDlg @keys[slot] = value if @info - # update @info - if TkComm::GET_CONFIGINFO_AS_ARRAY - if (inf = @info.assoc(slot)) - inf[-1] = value - else - @info << [slot, '', '', '', value] - end - else - if (inf = @info[slot]) - inf[-1] = value - else - @info[slot] = ['', '', '', value] - end - end + # update @info + if TkComm::GET_CONFIGINFO_AS_ARRAY + if (inf = @info.assoc(slot)) + inf[-1] = value + else + @info << [slot, '', '', '', value] + end + else + if (inf = @info[slot]) + inf[-1] = value + else + @info[slot] = ['', '', '', value] + end + end end end @@ -113,50 +113,50 @@ class Tk::BWidget::MessageDlg if winfo_exist? @info = super() if TkComm::GET_CONFIGINFO_AS_ARRAY - @info << ['relative', 'parent'] + @info << ['relative', 'parent'] else - @info['relative'] = 'parent' + @info['relative'] = 'parent' end end if TkComm::GET_CONFIGINFO_AS_ARRAY if @info - if winfo_exist? - # update @keys - @info.each{|inf| @keys[inf[0]] = inf[-1] if inf.size > 2 } - end + if winfo_exist? + # update @keys + @info.each{|inf| @keys[inf[0]] = inf[-1] if inf.size > 2 } + end else - @info = [] - @keys.each{|k, v| - @info << [k, '', '', '', v] - } - @info << ['relative', 'parent'] + @info = [] + @keys.each{|k, v| + @info << [k, '', '', '', v] + } + @info << ['relative', 'parent'] end if slot - @info.asoc(slot.to_s).dup + @info.asoc(slot.to_s).dup else - @info.dup + @info.dup end else # ! TkComm::GET_CONFIGINFO_AS_ARRAY if @info - if winfo_exist? - # update @keys - @info.each{|k, inf| @keys[k] = inf[-1] if inf.size > 2 } - end + if winfo_exist? + # update @keys + @info.each{|k, inf| @keys[k] = inf[-1] if inf.size > 2 } + end else - @info = {} - @keys.each{|k, v| - @info[k] = ['', '', '', v] - } - @info['relative'] = 'parent' + @info = {} + @keys.each{|k, v| + @info[k] = ['', '', '', v] + } + @info['relative'] = 'parent' end if slot - @info[slot.to_s].dup + @info[slot.to_s].dup else - @info.dup + @info.dup end end end diff --git a/ext/tk/lib/tkextlib/bwidget/notebook.rb b/ext/tk/lib/tkextlib/bwidget/notebook.rb index 26c11ac0d..e0cc04d30 100644 --- a/ext/tk/lib/tkextlib/bwidget/notebook.rb +++ b/ext/tk/lib/tkextlib/bwidget/notebook.rb @@ -24,7 +24,7 @@ class Tk::BWidget::NoteBook class Event_for_Tabs < TkEvent::Event def self._get_extra_args_tbl [ - TkComm.method(:string) # page idenfier + TkComm.method(:string) # page idenfier ] end end diff --git a/ext/tk/lib/tkextlib/bwidget/passwddlg.rb b/ext/tk/lib/tkextlib/bwidget/passwddlg.rb index 399353367..7136ae8d7 100644 --- a/ext/tk/lib/tkextlib/bwidget/passwddlg.rb +++ b/ext/tk/lib/tkextlib/bwidget/passwddlg.rb @@ -21,7 +21,7 @@ class Tk::BWidget::PasswdDlg def create login, passwd = simplelist(tk_call(self.class::TkCommandNames[0], - @path, *hash_kv(@keys))) + @path, *hash_kv(@keys))) [login, passwd] end end diff --git a/ext/tk/lib/tkextlib/bwidget/tree.rb b/ext/tk/lib/tkextlib/bwidget/tree.rb index f657e7148..9a49a96bb 100644 --- a/ext/tk/lib/tkextlib/bwidget/tree.rb +++ b/ext/tk/lib/tkextlib/bwidget/tree.rb @@ -27,7 +27,7 @@ class Tk::BWidget::Tree class Event_for_Items < TkEvent::Event def self._get_extra_args_tbl [ - TkComm.method(:string) # item idenfier + TkComm.method(:string) # item idenfier ] end end @@ -147,7 +147,7 @@ class Tk::BWidget::Tree def selection_add(*args) tk_send_without_enc('selection', 'add', - *(args.collect{|node| tagid(node)})) + *(args.collect{|node| tagid(node)})) self end @@ -162,30 +162,30 @@ class Tk::BWidget::Tree def selection_include?(*args) bool(tk_send_without_enc('selection', 'get', - *(args.collect{|node| tagid(node)}))) + *(args.collect{|node| tagid(node)}))) end def selection_range(*args) tk_send_without_enc('selection', 'range', - *(args.collect{|node| tagid(node)})) + *(args.collect{|node| tagid(node)})) self end def selection_remove(*args) tk_send_without_enc('selection', 'remove', - *(args.collect{|node| tagid(node)})) + *(args.collect{|node| tagid(node)})) self end def selection_set(*args) tk_send_without_enc('selection', 'set', - *(args.collect{|node| tagid(node)})) + *(args.collect{|node| tagid(node)})) self end def selection_toggle(*args) tk_send_without_enc('selection', 'toggle', - *(args.collect{|node| tagid(node)})) + *(args.collect{|node| tagid(node)})) self end @@ -218,16 +218,16 @@ class Tk::BWidget::Tree::Node @tree = tree parent = args.shift if parent.kind_of?(Tk::BWidget::Tree::Node) - if parent.tree.path != @tree.path - fail RuntimeError, 'tree of parent node is not match' - end + if parent.tree.path != @tree.path + fail RuntimeError, 'tree of parent node is not match' + end end elsif tree.kind_of?(Tk::BWidget::Tree::Node) @tree = tree.tree parent = tree.parent else fail RuntimeError, - "expect Tk::BWidget::Tree or Tk::BWidget::Tree::Node for 1st argument" + "expect Tk::BWidget::Tree or Tk::BWidget::Tree::Node for 1st argument" end if args[-1].kind_of?(Hash) |
