X-Git-Url: https://main.carlh.net/gitweb/?a=blobdiff_plain;f=src%2Fwx%2Fplayhead_to_frame_dialog.cc;h=b4c4b1030bd2b787d171228546e643f784c5af8c;hb=9ff22e1694a53f09a84b01685b64dcb83e830365;hp=1ae049d26ce9ea2429bc57e189c21e6724b7f48b;hpb=564780ded57e506f82971e71679a5645223bcff2;p=dcpomatic.git diff --git a/src/wx/playhead_to_frame_dialog.cc b/src/wx/playhead_to_frame_dialog.cc index 1ae049d26..b4c4b1030 100644 --- a/src/wx/playhead_to_frame_dialog.cc +++ b/src/wx/playhead_to_frame_dialog.cc @@ -1,5 +1,5 @@ /* - Copyright (C) 2016 Carl Hetherington + Copyright (C) 2016-2020 Carl Hetherington This file is part of DCP-o-matic. @@ -21,15 +21,19 @@ #include "playhead_to_frame_dialog.h" #include +using std::string; using dcp::locale_convert; +using namespace dcpomatic; -PlayheadToFrameDialog::PlayheadToFrameDialog (wxWindow* parent, int fps) +PlayheadToFrameDialog::PlayheadToFrameDialog (wxWindow* parent, DCPTime time, int fps) : TableDialog (parent, _("Go to frame"), 2, 1, true) , _fps (fps) { add (_("Go to"), true); _frame = add (new wxTextCtrl (this, wxID_ANY, wxT (""))); _frame->SetFocus (); + _frame->SetValue (std_to_wx(locale_convert(time.frames_round(fps) + 1))); + _frame->SetSelection (-1, -1); layout (); }