Kaydet (Commit) aa8a96a1 authored tarafından Kurt B. Kaiser's avatar Kurt B. Kaiser

Correct an ancient bug in an unused path by removing that path: register() is

now idempotent.
üst 469b2a52
......@@ -29,13 +29,9 @@ class WidgetRedirector:
tk.call("rename", orig, w)
def register(self, name, function):
if self.dict.has_key(name):
previous = dict[name]
else:
previous = OriginalCommand(self, name)
self.dict[name] = function
setattr(self.widget, name, function)
return previous
return OriginalCommand(self, name)
def unregister(self, name):
if self.dict.has_key(name):
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment