Rename option "Always show visual tools" to "Only show visual tools when mouse is over video" as the old name said nothing about when they wouldn't be shown.

Originally committed to SVN as r6754.
This commit is contained in:
Thomas Goyne 2012-05-05 02:11:15 +00:00
parent 06e23b9296
commit 18f158a364
5 changed files with 10 additions and 6 deletions

View File

@ -535,7 +535,7 @@
"Maximized" : false "Maximized" : false
}, },
"Visual" : { "Visual" : {
"Always Show": true "Autohide": false
} }
}, },

View File

@ -164,9 +164,13 @@ Audio::Audio(wxTreebook *book, Preferences *parent): OptionPage(book, parent, _(
Video::Video(wxTreebook *book, Preferences *parent): OptionPage(book, parent, _("Video")) { Video::Video(wxTreebook *book, Preferences *parent): OptionPage(book, parent, _("Video")) {
wxFlexGridSizer *general = PageSizer(_("Options")); wxFlexGridSizer *general = PageSizer(_("Options"));
OptionAdd(general, _("Show keyframes in slider"), "Video/Slider/Show Keyframes"); OptionAdd(general, _("Show keyframes in slider"), "Video/Slider/Show Keyframes");
CellSkip(general);
OptionAdd(general, _("Only show visual tools when mouse is over video"), "Tool/Visual/Autohide");
CellSkip(general);
OptionAdd(general, _("Seek video to line start on selection change"), "Video/Subtitle Sync"); OptionAdd(general, _("Seek video to line start on selection change"), "Video/Subtitle Sync");
OptionAdd(general, _("Always show visual tools"), "Tool/Visual/Always Show"); CellSkip(general);
OptionAdd(general, _("Automatically open audio when opening video"), "Video/Open Audio"); OptionAdd(general, _("Automatically open audio when opening video"), "Video/Open Audio");
CellSkip(general);
const wxString czoom_arr[24] = { "12.5%", "25%", "37.5%", "50%", "62.5%", "75%", "87.5%", "100%", "112.5%", "125%", "137.5%", "150%", "162.5%", "175%", "187.5%", "200%", "212.5%", "225%", "237.5%", "250%", "262.5%", "275%", "287.5%", "300%" }; const wxString czoom_arr[24] = { "12.5%", "25%", "37.5%", "50%", "62.5%", "75%", "87.5%", "100%", "112.5%", "125%", "137.5%", "150%", "162.5%", "175%", "187.5%", "200%", "212.5%", "225%", "237.5%", "250%", "262.5%", "275%", "287.5%", "300%" };
wxArrayString choice_zoom(24, czoom_arr); wxArrayString choice_zoom(24, czoom_arr);

View File

@ -95,7 +95,7 @@ VideoDisplay::VideoDisplay(
wxWindow* parent, wxWindow* parent,
agi::Context *c) agi::Context *c)
: wxGLCanvas (parent, -1, attribList, wxDefaultPosition, wxDefaultSize, 0, wxPanelNameStr) : wxGLCanvas (parent, -1, attribList, wxDefaultPosition, wxDefaultSize, 0, wxPanelNameStr)
, alwaysShowTools(OPT_GET("Tool/Visual/Always Show")) , autohideTools(OPT_GET("Tool/Visual/Autohide"))
, con(c) , con(c)
, w(8) , w(8)
, h(8) , h(8)
@ -220,7 +220,7 @@ void VideoDisplay::Render() try {
} }
} }
if ((mouse_pos || alwaysShowTools->GetBool()) && tool) if ((mouse_pos || !autohideTools->GetBool()) && tool)
tool->Draw(); tool->Draw();
SwapBuffers(); SwapBuffers();

View File

@ -68,7 +68,7 @@ class VideoDisplay : public wxGLCanvas {
/// Signals the display is connected to /// Signals the display is connected to
std::list<agi::signal::Connection> slots; std::list<agi::signal::Connection> slots;
const agi::OptionValue* alwaysShowTools; const agi::OptionValue* autohideTools;
agi::Context *con; agi::Context *con;

View File

@ -200,7 +200,7 @@ void VisualTool<FeatureType>::OnMouseEvent(wxMouseEvent &event) {
return; return;
} }
if (event.Entering() && !OPT_GET("Tool/Visual/Always Show")->GetBool()) if (event.Entering() && OPT_GET("Tool/Visual/Autohide")->GetBool())
need_render = true; need_render = true;
if (!dragging) { if (!dragging) {