From 54e9c19ed53b2aef1e92ad40bb18e7fd0fbd8a1a Mon Sep 17 00:00:00 2001 From: WrinklyNinja Date: Wed, 19 Feb 2014 19:26:03 +0000 Subject: [PATCH] Added tooltips (issue #114). --- src/gui/editor.cpp | 16 +++++++++++++++- src/gui/main.cpp | 5 +++++ 2 files changed, 20 insertions(+), 1 deletion(-) diff --git a/src/gui/editor.cpp b/src/gui/editor.cpp index a693befa..49370cee 100644 --- a/src/gui/editor.cpp +++ b/src/gui/editor.cpp @@ -158,7 +158,7 @@ MiniEditor::MiniEditor(wxWindow *parent, const wxString& title, const std::list< descText = new wxStaticText(this, wxID_ANY, translate("Please submit any edits made for reasons other than personal preference to the BOSS team so that they may be included in the masterlist.")); prioritySpin = new wxSpinCtrl(editingPanel, wxID_ANY, "0"); prioritySpin->SetRange(std::numeric_limits::min(), std::numeric_limits::max()); - filterCheckbox = new wxCheckBox(editingPanel, wxID_ANY, translate("Show only conflicting plugins.")); + filterCheckbox = new wxCheckBox(editingPanel, wxID_ANY, translate("Show only conflicting plugins")); pluginList = new wxListView(this, LIST_Plugins, wxDefaultPosition, wxDefaultSize, wxLC_REPORT | wxLC_SINGLE_SEL); loadAfterList = new wxListView(editingPanel, LIST_LoadAfter, wxDefaultPosition, wxDefaultSize, wxLC_REPORT | wxLC_SINGLE_SEL); @@ -194,6 +194,13 @@ MiniEditor::MiniEditor(wxWindow *parent, const wxString& title, const std::list< Bind(wxEVT_BUTTON, &MiniEditor::OnApply, this, wxID_APPLY); Bind(wxEVT_SIZE, &MiniEditor::OnResize, this); + //Set up tooltips. + pluginList->SetToolTip(translate("Select a plugin to edit its load order metadata.")); + loadAfterList->SetToolTip(translate("Drag and drop a plugin here to make the selected plugin load after it. The \"Show only conflicting plugins\" checkbox must be checked.")); + prioritySpin->SetToolTip(translate("Plugins with higher priorities will load after plugins with smaller priorities that they conflict with, unless one must explicitly load after the other.")); + filterCheckbox->SetToolTip(translate("Filters the plugin list to only display plugins which can be loaded after the currently selected plugin, and which either conflict with it, or, if it loads a BSA, also load BSAs. Also enables drag and drop of plugins into the Load After box.")); + removeBtn->SetToolTip(translate("Only newly-added plugins may be removed here. Use the metadata editor to remove other user-added plugins.")); + //Set up editing panel layout. wxBoxSizer * mainBox = new wxBoxSizer(wxVERTICAL); mainBox->Add(pluginText, 0, wxTOP | wxBOTTOM, 10); @@ -565,6 +572,13 @@ Editor::Editor(wxWindow *parent, const wxString& title, const std::string userli Bind(wxEVT_MENU, &Editor::OnPluginCopyMetadata, this, MENU_CopyMetadata); Bind(wxEVT_MENU, &Editor::OnPluginClearMetadata, this, MENU_ClearMetadata); + //Set up tooltips. + pluginList->SetToolTip(translate("Select a plugin to edit its load order metadata.")); + prioritySpin->SetToolTip(translate("Plugins with higher priorities will load after plugins with smaller priorities that they conflict with, unless one must explicitly load after the other.")); + enableUserEditsBox->SetToolTip(translate("If unchecked, any user-added metadata will be ignored during sorting.")); + editBtn->SetToolTip(translate("Only user-added data may be removed.")); + removeBtn->SetToolTip(translate("Only user-added data may be removed.")); + //Set up layout. wxBoxSizer * bigBox = new wxBoxSizer(wxHORIZONTAL); diff --git a/src/gui/main.cpp b/src/gui/main.cpp index b454ac2d..5ee1abcf 100644 --- a/src/gui/main.cpp +++ b/src/gui/main.cpp @@ -439,6 +439,11 @@ Launcher::Launcher(const wxChar *title, YAML::Node& settings, Game& game, vector Bind(wxEVT_BUTTON, &Launcher::OnViewLastReport, this, OPTION_ViewLastReport); Bind(wxEVT_CLOSE_WINDOW, &Launcher::OnClose, this); + //Set up tooltips. + EditButton->SetToolTip(translate("Opens the Metadata Editor, where plugins' sorting metadata, messages, dirty info and Bash Tag suggestions can be edited.")); + SortButton->SetToolTip(translate("Sorts your plugins, then displays a report of the results.")); + ViewButton->SetToolTip(translate("Opens the last report generated for the current game.")); + //Set up initial state. SortButton->SetDefault();