Changeset 4174

Show
Ignore:
Timestamp:
06/21/08 05:34:23 (5 months ago)
Author:
ed
Message:

In some cases, the Preference window opens so that app.ActiveForm? returns None. If this happens, use the Parent, if any, as the active form.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/dabo/ui/dialogs/PreferenceDialog.py

    r4110 r4174  
    117117        """ 
    118118        af = self.Application.ActiveForm 
     119        if not af or af is self: 
     120            af = self.Parent 
    119121        try: 
    120122            mb = af.MenuBar 
     
    122124        except: 
    123125            menuOK = False 
     126            mb = None 
    124127        if menuOK: 
    125128            pm = af.PreferenceManager.menu