From 60377791510ffe8d2f6e97335c0c5948baff8900 Mon Sep 17 00:00:00 2001 From: Robin Dunn Date: Mon, 6 Apr 2020 12:52:43 -0700 Subject: [PATCH] Try different usages of creating the animation and control --- demo/AnimateCtrl.py | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/demo/AnimateCtrl.py b/demo/AnimateCtrl.py index 336d5d32..f2260263 100644 --- a/demo/AnimateCtrl.py +++ b/demo/AnimateCtrl.py @@ -32,8 +32,15 @@ class TestPanel(wx.Panel): sizer = wx.FlexGridSizer(cols=3, hgap=5, vgap=5) for name in GIFNames: - ctrl = AnimationCtrl(self) - ctrl.LoadFile(opj(name)) + if False: + ctrl = AnimationCtrl(self) + ani = ctrl.CreateAnimation() + ani.LoadFile(opj(name)) + ctrl.SetAnimation(ani) + else: + ctrl = AnimationCtrl(self) + ctrl.LoadFile(opj(name)) + ctrl.SetBackgroundColour(self.GetBackgroundColour()) ctrl.Play() sizer.Add(ctrl, 0, wx.ALL, 10)