Changeset 2733

Show
Ignore:
Timestamp:
01/22/07 04:40:25 (2 years ago)
Author:
ed
Message:

Added some code to work around an issue with wxPython 2.8 on the Mac. Previously the code would trap the error raised by an invalid page number, but this was producing a segfault on OS X after upgrading to 2.8.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/dabo/ui/uiwx/dPageFrameMixin.py

    r2583 r2733  
    335335    def _getSelectedPage(self): 
    336336        try: 
    337             ret = self.GetPage(self.GetSelection()) 
     337            sel = self.GetSelection() 
     338            if sel < 0: 
     339                ret = None 
     340            else: 
     341                ret = self.GetPage(sel) 
    338342        except: 
    339343            ret = None