Hand-apply c7ce6fcf9bc6b5b1f6d823b7df256f43fefd660c; add a note to the
authorCarl Hetherington <cth@carlh.net>
Wed, 25 Mar 2015 00:00:06 +0000 (00:00 +0000)
committerCarl Hetherington <cth@carlh.net>
Wed, 25 Mar 2015 00:00:06 +0000 (00:00 +0000)
timing panel to try to stop people changing the video frame rate in
the wrong circumstances.

ChangeLog
src/wx/timing_panel.cc

index 9fb6dff1dfe2be04fb1caec9c113d63490f2c6f7..1633b6a03ba4acf9563028b87210d31faf6e4b67 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,9 @@
 2015-03-24  Carl Hetherington  <cth@carlh.net>
 
+       * Hand-apply 31eafa8a121b8d341d198e4fe426ee843cc70167; add a note
+       to the timing panel to try to stop people changing the video frame
+       rate in the wrong circumstances.
+
        * Hand-apply e30fd8d; resurrect JSON server code.
 
        * Hand-apply 7ba9dcdbfe8f0d94ad9887843995c152c45dfe9e from master;
index ab98a5094ea23bbb8391c354fbf1f4a910505ba5..1b1c4b8934f936ea3a45bd9cc80104413a44dcd7 100644 (file)
@@ -1,5 +1,5 @@
 /*
-    Copyright (C) 2012-2013 Carl Hetherington <cth@carlh.net>
+    Copyright (C) 2012-2015 Carl Hetherington <cth@carlh.net>
 
     This program is free software; you can redistribute it and/or modify
     it under the terms of the GNU General Public License as published by
@@ -101,6 +101,30 @@ TimingPanel::TimingPanel (ContentPanel* p)
                grid->Add (s, 1, wxEXPAND);
        }
 
+       grid->AddSpacer (0);
+
+       /* We can't use Wrap() here as it doesn't work with markup:
+        * http://trac.wxwidgets.org/ticket/13389
+        */
+
+       wxString in = _("<i>Only change this if it the content's frame rate has been read incorrectly.</i>");
+       wxString out;
+       int const width = 20;
+       int current = 0;
+       for (size_t i = 0; i < in.Length(); ++i) {
+               if (in[i] == ' ' && current >= width) {
+                       out += '\n';
+                       current = 0;
+               } else {
+                       out += in[i];
+                       ++current;
+               }
+       }
+       
+       t = new wxStaticText (this, wxID_ANY, wxT (""));
+       t->SetLabelMarkup (out);
+       grid->Add (t, 0, wxALIGN_CENTER_VERTICAL | wxLEFT | wxRIGHT, 6);
+
        _position->Changed.connect    (boost::bind (&TimingPanel::position_changed, this));
        _full_length->Changed.connect (boost::bind (&TimingPanel::full_length_changed, this));
        _trim_start->Changed.connect  (boost::bind (&TimingPanel::trim_start_changed, this));