]>
git.saurik.com Git - wxWidgets.git/blob - wxPython/demo/AnimateCtrl.py
   7     'bitmaps/AG00178_.gif', 
   8     'bitmaps/BD13656_.gif',   
   9     'bitmaps/AG00185_.gif', 
  10     'bitmaps/AG00039_.gif', 
  11     'bitmaps/AG00183_.gif', 
  12     'bitmaps/AG00028_.gif', 
  15 #---------------------------------------------------------------------- 
  17 class TestPanel(wx
.Panel
): 
  18     def __init__(self
, parent
, log
): 
  20         wx
.Panel
.__init
__(self
, parent
, -1) 
  22         sizer 
= wx
.FlexGridSizer(2,3,5,5) 
  24             ani 
= wx
.animate
.Animation(opj(name
)) 
  25             ctrl 
= wx
.animate
.AnimationCtrl(self
, -1, ani
) 
  26             ctrl
.SetUseWindowBackgroundColour() 
  28             sizer
.AddF(ctrl
, wx
.SizerFlags().Border(wx
.ALL
, 10)) 
  30         border 
= wx
.BoxSizer() 
  31         border
.AddF(sizer
, wx
.SizerFlags(1).Expand().Border(wx
.ALL
, 20)) 
  35 #---------------------------------------------------------------------- 
  37 def runTest(frame
, nb
, log
): 
  38     win 
= TestPanel(nb
, log
) 
  41 #---------------------------------------------------------------------- 
  45 overview 
= """<html><body> 
  46 <h2><center>wx.animate.AnimationCtrl</center></h2> 
  48 wx.animate.AnimationCtrl is like a wx.StaticBitmap but is able to 
  49 display an animation by extracing frames from a multi-image GIF file. 
  56 if __name__ 
== '__main__': 
  59     run
.main(['', os
.path
.basename(sys
.argv
[0])] + sys
.argv
[1:])