Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit f48c919

Browse files
author
Steve Chaplin
committed
SC
svn path=/trunk/matplotlib/; revision=2984
1 parent af196d0 commit f48c919

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

examples/dynamic_image_gtkagg.py

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,13 +2,16 @@
22
"""
33
An animated image
44
"""
5-
import sys, time, os, gc
5+
import time
6+
7+
import gobject
8+
import gtk
9+
610
import matplotlib
711
matplotlib.use('GTKAgg')
812
from matplotlib import rcParams
913

1014
from pylab import *
11-
import gobject, gtk
1215

1316
fig = figure(1)
1417
a = subplot(111)
@@ -33,10 +36,9 @@ def updatefig(*args):
3336
cnt += 1
3437
if cnt==50:
3538
print 'FPS', cnt/(time.time() - tstart)
36-
return gtk.FALSE
39+
return False
3740
return True
3841

39-
4042
cnt = 0
4143

4244
gobject.idle_add(updatefig)

0 commit comments

Comments
 (0)