timeline: fix position rectangle missing on first click

Regression caused by previous commit.
This commit is contained in:
René Stadler 2012-09-24 02:23:22 +02:00 committed by Stefan Sauer
parent 985ef29bb3
commit af308379b4

View file

@ -700,8 +700,7 @@ class TimelineWidget (gtk.DrawingArea):
def __have_position (self):
if ((self.__position_ts_range is not None) and
(self.process is not None) and
if ((self.process is not None) and
(self.process.freq_sentinel is not None) and
(self.process.freq_sentinel.ts_range is not None)):
return True
@ -725,7 +724,7 @@ class TimelineWidget (gtk.DrawingArea):
def __draw_position (self, drawable, clip = None):
if not self.__have_position ():
if not self.__have_position () or self.__position_ts_range is None:
return
start_ts, end_ts = self.__position_ts_range