diff --git a/aegisub/src/libresrc/default_config.json b/aegisub/src/libresrc/default_config.json index e9edd849b..7598a5f62 100644 --- a/aegisub/src/libresrc/default_config.json +++ b/aegisub/src/libresrc/default_config.json @@ -535,7 +535,7 @@ "Maximized" : false }, "Visual" : { - "Always Show": true + "Autohide": false } }, diff --git a/aegisub/src/preferences.cpp b/aegisub/src/preferences.cpp index 9b8b43833..82c629e73 100644 --- a/aegisub/src/preferences.cpp +++ b/aegisub/src/preferences.cpp @@ -164,9 +164,13 @@ Audio::Audio(wxTreebook *book, Preferences *parent): OptionPage(book, parent, _( Video::Video(wxTreebook *book, Preferences *parent): OptionPage(book, parent, _("Video")) { wxFlexGridSizer *general = PageSizer(_("Options")); 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, _("Always show visual tools"), "Tool/Visual/Always Show"); + CellSkip(general); 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%" }; wxArrayString choice_zoom(24, czoom_arr); diff --git a/aegisub/src/video_display.cpp b/aegisub/src/video_display.cpp index fcf8193bc..a7504a453 100644 --- a/aegisub/src/video_display.cpp +++ b/aegisub/src/video_display.cpp @@ -95,7 +95,7 @@ VideoDisplay::VideoDisplay( wxWindow* parent, agi::Context *c) : wxGLCanvas (parent, -1, attribList, wxDefaultPosition, wxDefaultSize, 0, wxPanelNameStr) -, alwaysShowTools(OPT_GET("Tool/Visual/Always Show")) +, autohideTools(OPT_GET("Tool/Visual/Autohide")) , con(c) , w(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(); SwapBuffers(); diff --git a/aegisub/src/video_display.h b/aegisub/src/video_display.h index 819fcd5a0..2adb7fac4 100644 --- a/aegisub/src/video_display.h +++ b/aegisub/src/video_display.h @@ -68,7 +68,7 @@ class VideoDisplay : public wxGLCanvas { /// Signals the display is connected to std::list slots; - const agi::OptionValue* alwaysShowTools; + const agi::OptionValue* autohideTools; agi::Context *con; diff --git a/aegisub/src/visual_tool.cpp b/aegisub/src/visual_tool.cpp index 905dc197b..6493694ba 100644 --- a/aegisub/src/visual_tool.cpp +++ b/aegisub/src/visual_tool.cpp @@ -200,7 +200,7 @@ void VisualTool::OnMouseEvent(wxMouseEvent &event) { return; } - if (event.Entering() && !OPT_GET("Tool/Visual/Always Show")->GetBool()) + if (event.Entering() && OPT_GET("Tool/Visual/Autohide")->GetBool()) need_render = true; if (!dragging) {