add Listbox.activate()
This commit is contained in:
parent
b61b28b07d
commit
46f92d2eba
|
@ -1031,6 +1031,8 @@ class Listbox(Widget):
|
|||
self['selectmode'] = 'single'
|
||||
else:
|
||||
self.tk.call('tk_listboxSingleSelect', self._w)
|
||||
def activate(self, index):
|
||||
self.tk.call(self._w, 'activate', index)
|
||||
def curselection(self):
|
||||
return self.tk.splitlist(self.tk.call(
|
||||
self._w, 'curselection'))
|
||||
|
|
|
@ -1031,6 +1031,8 @@ class Listbox(Widget):
|
|||
self['selectmode'] = 'single'
|
||||
else:
|
||||
self.tk.call('tk_listboxSingleSelect', self._w)
|
||||
def activate(self, index):
|
||||
self.tk.call(self._w, 'activate', index)
|
||||
def curselection(self):
|
||||
return self.tk.splitlist(self.tk.call(
|
||||
self._w, 'curselection'))
|
||||
|
|
Loading…
Reference in New Issue