[Simulator] UI tweaks for last major update. (#4414)

* [Simulator] Debug output: Adjust exclusion filter, help text <kbd> background color, fix help text typos & mark as translatable.

* [Simulator] Radio Outputs: Fix wrong FM highlighted (closes #4408) and current FM not highlighted until switched once; Change highlight color role of active LS/FM so it is always shown (fixes #4393); Active LSs now much more obvious (bold font & sunken frame).

* [Simulator] Rework some SimulatorMainWindow functionality:
    * Fix floating dock widgets appearing behind other applications on Linux (https://github.com/opentx/opentx/issues/4403#issuecomment-277510273);
    * Fix previously-unused floating dock widgets appearing in top-left corner upon subsequent launches of application (https://github.com/opentx/opentx/pull/4385#issuecomment-277315158);
    * Fix various anomalies due to not using a "central widget" in QMainWindow (extra separators appearing, vertical resize not working in some cases), radio widget is now central by default;
    * Add (keep) option to float the radio widget separate from main window, though this may cause the minor visual anomalies mentioned above;
    * Add options to disable radio widget size constraints while docked.
This commit is contained in:
Max Paperno
2017-02-06 18:27:03 +01:00
committed by Bertrand Songis
parent b0eeeb4dbc
commit ded843b989
7 changed files with 280 additions and 124 deletions
+11 -3
View File
@@ -57,15 +57,22 @@ class SimulatorMainWindow : public QMainWindow
QMenu * createPopupMenu();
public slots:
virtual void show();
void start();
void showRadioTitlebar(bool show);
void toggleMenuBar(bool show);
void showMenuBar(bool show);
void showRadioFixedSize(Qt::Orientation orientation, bool fixed);
void showRadioFixedWidth(bool fixed);
void showRadioFixedHeight(bool fixed);
void showRadioDocked(bool dock);
protected slots:
virtual void closeEvent(QCloseEvent *);
virtual void changeEvent(QEvent *e);
void restoreUiState();
void saveUiState();
void toggleMenuBar(bool show);
void setRadioSizePolicy(int fixType);
void toggleRadioDocked(bool dock);
void luaReload(bool);
void openJoystickDialog(bool);
void showHelp(bool show);
@@ -89,8 +96,9 @@ class SimulatorMainWindow : public QMainWindow
QVector<keymapHelp_t> m_keymapHelp;
int m_radioProfileId;
int m_radioSizeConstraint;
bool m_firstShow;
bool m_showRadioTitlebar;
bool m_showRadioDocked;
bool m_showMenubar;
const static quint16 m_savedUiStateVersion;