Fix crash on creating new film. Fix setup of ratio selector.
authorCarl Hetherington <cth@carlh.net>
Sun, 16 Jun 2013 16:10:59 +0000 (17:10 +0100)
committerCarl Hetherington <cth@carlh.net>
Sun, 16 Jun 2013 16:10:59 +0000 (17:10 +0100)
src/lib/film.cc
src/wx/film_editor.cc
src/wx/film_viewer.cc

index 75ec700e0092e5bb35487f43556e4c93b1600b4e..b50fe67d11ade014230d833da685a461cb9b8bc1 100644 (file)
@@ -101,7 +101,7 @@ Film::Film (string d)
        , _colour_lut (0)
        , _j2k_bandwidth (200000000)
        , _dci_metadata (Config::instance()->default_dci_metadata ())
-       , _dcp_video_frame_rate (0)
+       , _dcp_video_frame_rate (24)
        , _dcp_audio_channels (MAX_AUDIO_CHANNELS)
        , _dirty (false)
 {
index afd79b08dfbbdacd1d089d04aa535912cd8530bc..c9664212425e6cb916f71f32163e2ecb884ba0aa 100644 (file)
@@ -596,8 +596,6 @@ FilmEditor::film_changed (Film::Property p)
                break;
        case Film::CONTENT:
                setup_content ();
-               setup_ratios ();
-//             setup_ratio ();
                setup_subtitle_control_sensitivity ();
                setup_show_audio_sensitivity ();
                break;
@@ -714,7 +712,7 @@ FilmEditor::film_content_changed (weak_ptr<Content> weak_content, int property)
                                ++i;
                                ++n;
                        }
-                       
+
                        if (i == ratios.end()) {
                                checked_set (_ratio, -1);
                        } else {
@@ -1152,7 +1150,7 @@ FilmEditor::setup_content ()
        }
 
        if (selected_summary.empty () && !content.empty ()) {
-               /* Select the item of content if non was selected before */
+               /* Select the item of content if none was selected before */
                _content->SetItemState (0, wxLIST_STATE_SELECTED, wxLIST_STATE_SELECTED);
        }
 }
index c7a44364fc407dff03278bad6e270f0846caeffc..db2ab9dfe2e6009decb499f40559fb3c36e9795a 100644 (file)
@@ -420,7 +420,7 @@ FilmViewer::film_content_changed (weak_ptr<Content>, int p)
                /* Force an update to our frame */
                wxScrollEvent ev;
                slider_moved (ev);
-       } else if (p == VideoContentProperty::VIDEO_CROP) {
+       } else if (p == VideoContentProperty::VIDEO_CROP || p == VideoContentProperty::VIDEO_RATIO) {
                update_from_decoder ();
        }               
 }