From e1c77fa8f14da1bdbc7e88db2b2c2683cac8c851 Mon Sep 17 00:00:00 2001 From: Robin Dunn Date: Thu, 10 Oct 2002 17:51:13 +0000 Subject: [PATCH] Add some test code, and testing if CVS is allowing commits again. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/WX_2_4_BRANCH@17485 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- wxPython/demo/wxListBox.py | 29 ++++++++++++++++++----------- 1 file changed, 18 insertions(+), 11 deletions(-) diff --git a/wxPython/demo/wxListBox.py b/wxPython/demo/wxListBox.py index f2f8bf7056..c6499d80e2 100644 --- a/wxPython/demo/wxListBox.py +++ b/wxPython/demo/wxListBox.py @@ -90,7 +90,9 @@ class TestListBox(wxPanel): def EvtListBox(self, event): - self.log.WriteText('EvtListBox: %s\n' % event.GetString()) + self.log.WriteText('EvtListBox: %s, %s, %s\n' % + (event.GetString(), event.IsSelection(), event.GetSelection())) + lb = event.GetEventObject() data = lb.GetClientData(lb.GetSelection()) if data is not None: @@ -127,14 +129,19 @@ def runTest(frame, nb, log): - - - - - - - -overview = """\ -A listbox is used to select one or more of a list of strings. The strings are displayed in a scrolling box, with the selected string(s) marked in reverse video. A listbox can be single selection (if an item is selected, the previous selection is removed) or multiple selection (clicking an item toggles the item on or off independently of other selections). - +overview = """ +A listbox is used to select one or more of a list of +strings. The strings are displayed in a scrolling box, with the +selected string(s) marked in reverse video. A listbox can be single +selection (if an item is selected, the previous selection is removed) +or multiple selection (clicking an item toggles the item on or off +independently of other selections). + """ + + +if __name__ == '__main__': + import sys,os + import run + run.main(['', os.path.basename(sys.argv[0])]) +