Changeset 2697

Show
Ignore:
Timestamp:
01/16/07 08:44:07 (2 years ago)
Author:
ed
Message:

Updated the dev copy of dPageFrame.py to match the stable update.

Files:

Legend:

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

    r2541 r2697  
    125125        dd.SetSelection(pos) 
    126126         
    127          
    128          
    129          
     127 
     128import random 
    130129class _dPageFrame_test(dPageFrame): 
    131130    def initProperties(self): 
    132131        self.Width = 400 
    133132        self.Height = 175 
     133        self.TabPosition = random.choice(("Top", "Bottom", "Left", "Right")) 
    134134     
    135135    def afterInit(self): 
    136136        self.appendPage(caption="Introduction") 
    137137        self.appendPage(caption="Chapter I") 
    138         self.appendPage(caption="Chapter 2") 
    139      
    140     def beforePageChange(self, fromPage, toPage): 
    141         # Don't allow the user to go from page 0 to page 2 
    142         if fromPage == 0 and toPage == 2: 
    143             return False 
    144         else: 
    145             return True 
     138        self.Pages[0].BackColor = "darkred" 
     139        self.Pages[1].BackColor = "darkblue" 
    146140     
    147141    def onPageChanged(self, evt): 
     
    153147        self.Width = 400 
    154148        self.Height = 175 
     149        self.TabPosition = random.choice(("Top", "Bottom", "Left", "Right")) 
    155150     
    156151    def afterInit(self): 
    157152        self.appendPage(caption="Introduction") 
    158153        self.appendPage(caption="Chapter I") 
    159         self.appendPage(caption="Chapter 2") 
     154        self.Pages[0].BackColor = "darkred" 
     155        self.Pages[1].BackColor = "darkblue" 
    160156     
    161157    def onPageChanged(self, evt): 
     
    167163        self.Width = 400 
    168164        self.Height = 175 
     165        self.TabPosition = random.choice(("Top", "Bottom", "Left", "Right")) 
    169166     
    170167    def afterInit(self): 
    171168        self.appendPage(caption="Introduction") 
    172169        self.appendPage(caption="Chapter I") 
    173         self.appendPage(caption="Chapter 2") 
     170        self.Pages[0].BackColor = "darkred" 
     171        self.Pages[1].BackColor = "darkblue" 
    174172     
    175173    def onPageChanged(self, evt): 
     
    177175 
    178176 
     177         
    179178if __name__ == "__main__": 
    180179    import test