summaryrefslogtreecommitdiff
path: root/src/wx/timeline.h
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2014-06-10 14:13:54 +0100
committerCarl Hetherington <cth@carlh.net>2014-06-10 14:13:54 +0100
commit40183875ff823b8981b4369eddfe9bbb13938b03 (patch)
tree8f670febe988d53f869a7e6213693100d0d69923 /src/wx/timeline.h
parentf85629b7a8e0e01ef593d0ce9a0d2cf85bb91b71 (diff)
Fix crash when opening the timeline window with no content (#369).
Reported-by: Corvo
Diffstat (limited to 'src/wx/timeline.h')
-rw-r--r--src/wx/timeline.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/wx/timeline.h b/src/wx/timeline.h
index ef1d10797..7b4d75d09 100644
--- a/src/wx/timeline.h
+++ b/src/wx/timeline.h
@@ -52,7 +52,7 @@ public:
return 48;
}
- double pixels_per_time_unit () const {
+ boost::optional<double> pixels_per_time_unit () const {
return _pixels_per_time_unit;
}
@@ -96,7 +96,7 @@ private:
ViewList _views;
boost::shared_ptr<TimeAxisView> _time_axis_view;
int _tracks;
- double _pixels_per_time_unit;
+ boost::optional<double> _pixels_per_time_unit;
bool _left_down;
wxPoint _down_point;
boost::shared_ptr<ContentView> _down_view;