Commit Graph

76 Commits

Author SHA1 Message Date
Hubert Maier
bcfacb98e8 JANITORIAL: Fix avaliable typo in editgamedialog.cpp 2024-05-18 13:52:31 +02:00
Lars Sundström
3c36c1fbc3 GUI: Put backend options tab elements into a ScrollContainer
The backend options tab is for backend specific options. The backends
supporting it implements the function buildBackendOptionsWidget which
defines the options elements and layout.

The backend options tab layout may differ depending on the current
domain. The options in the "Global options" tab applies to all games
while the options in the "Game options" tab only applies to a specific
game. The options in the "Global config" options tab can be set during
game play. Some options, e.g. graphics cannot be changed while running
the game while backend options can.

The first version of the backend options tab was a non-scrollable
container. The "Game options" tab includes an "Override Global options
checkbox" which, when checked, enables the options defined by the
backend.

The number of iOS7 backend options increased rapidly which caused some
options to fall outside the tab container on screens with limited
space in height. An attempt to fix that was made by the same creator
of this commit in the commit: 8db736f155

The attempt was not perfect in any way, else this commit wouldn't
exist... The "Override Global options checkbox" on the "Game options"
tab became misplaced. It also required the backend to add padding
to GUI elements it shouldn't know of.

To fix this properly put the backend options tab in a single Scroll-
Container. This way the "Override Global options checkbox" can be
properly placed related to the backend options widgets. All backend
options can also be accessed in every backend options tab layout,
Global options, Game options and Global config thanks to the scrollbar
automatically provided by the ScrollContainer.

Update all themes with the new layout.
2024-03-11 01:03:37 +01:00
Le Philousophe
4591a74b82 GUI: Don't display save and extra path when it's the default one 2024-03-02 12:59:03 +01:00
Le Philousophe
ed9ded9e83 GUI: Migrate GUI to Path class 2023-12-24 13:19:25 +01:00
Thierry Crozat
8f9cdff4a7 GUI: Add function in GuiManager to query if low-res GUI should be used
The same condition was scattered around in the code to switch between
normal labels and images and their lowres counterparts. Factorizing
that condition in a function will allow changing it easily.
2023-10-09 21:04:08 +01:00
Thierry Crozat
aa7572ef1e GUI: Fix testing width for lowres labels on HiDPI screens 2023-10-09 21:04:08 +01:00
Cameron Cawley
2c8a7d3900 ENGINES: Remove support for GUI options in MetaEngineDetection subclasses 2022-11-16 23:58:54 +01:00
Orgad Shaneh
aba347ed9e GUI: Make character validation less ugly 2022-11-02 22:15:16 +00:00
Eugene Sandulenko
3aef14fa99 GUI: Initial code for making game options work with shader controls 2022-10-08 23:39:18 +02:00
Eugene Sandulenko
ff00d3feea GUI: Move shader controls to Graphics tab and hide behind radiobutton 2022-10-08 23:39:18 +02:00
Cameron Cawley
64c359b5cb GUI: Replace the options for selecting shaders 2022-10-08 23:39:18 +02:00
BLooperZ
b67b88e6d9 GUI: Support unicode and BiDi in editable widget 2022-08-02 22:04:54 +02:00
Die4Ever
42a27fda40 GUI: tabs with scrollbars for more pages 2022-01-23 20:28:55 +02:00
Die4Ever
4ef38a9255 GUI: tabs with scrollbars 2022-01-23 20:28:55 +02:00
Die4Ever
30a8d927a1 GUI: tabs with scrollbars 2022-01-23 20:28:55 +02:00
Eugene Sandulenko
abea37c9bb
ALL: Update ScummVM project license to GPLv3+ 2021-12-26 18:48:43 +01:00
Eugene Sandulenko
109beb4f86 GUI: Explicitely use Common:: namespace 2021-11-12 14:46:34 +01:00
Cameron Cawley
2f99746d8d ENGINES: Allow implementing registerDefaultSettings in the MetaEngine class 2021-09-18 11:57:29 +02:00
Cameron Cawley
6edcd3c21c GUI: Fix displaying dynamic engine options widgets in the Edit Game dialog 2021-08-23 00:07:11 +03:00
antoniou
d62202801a GUI: Check for writable for save game path
This is done in Global Options, but it was skipped here in Game domain scope

This resulted in allowing bad paths (without write access) in this field
2021-07-13 16:51:56 +03:00
Cameron Cawley
b2d41daabc GUI: Add improved scaler selection to the Options dialog 2021-06-23 21:29:53 +02:00
antoniou79
ae5277f942 GUI: Update domain name for backendOptions upon renaming Game id
Without this, the ports using backendOptions Widget could error trying to access the domain with the old name

For example, the Android port, upon editing and renaming the Game Id, would error with a message like "E/ScummVM: ConfigManager::removeKey(onscreen_control, bladerunner-final-win) called on non-existent domain". This is because in its AndroidOptionsWidget::save() method (called within OptionsDialog::apply()), there were calls to removeKey() which internally was using the stale/old _domain (domain name before the renaming)
2021-06-20 22:50:12 +03:00
lb_ii
a59108911d GUI: Use AchMan to get achievements descriptions 2021-06-10 01:56:23 +03:00
lb_ii
3ea4faeab7 GUI: Add Statistics dialog to game options 2021-06-01 02:20:53 +03:00
Thierry Crozat
982ccb12eb COMMON: Add GUIO_NOLANG GUI option to hide the lang selector 2021-04-19 23:10:12 +01:00
Cameron Cawley
76b25ec1c3 GUI: Add a checkbox to allow overriding the global backend settings 2021-03-15 16:52:52 +02:00
Thierry Crozat
67720ef658 JANITORIAL: Remove obselete references to MetaEngineConnect
At some point when splitting the MetaEngine to a detection
plugin and a static meta engine, the former was called
MetaEngine while the latter was called MetaEngineConnect.
Thus was then later change to MetaEngineDetection and
MetaEngine. But some references were left to the former
names in comments and documentation.
2021-02-14 14:32:36 +00:00
Cameron Cawley
11724f9df1 GUI: Add a tab for backend-specific options 2020-11-22 16:35:03 +00:00
Cameron Cawley
c877097b49 ALL: Remove use of "" in Common::U32String constructors 2020-11-16 16:56:58 +00:00
Torbjörn Andersson
9acdbe42af
GUI: Update "edit game" for new graphics options (#2512)
Make the new graphics options in "edit game" disabled until the user
asks to override the global settings. (Most of these were added during
the ScummVM/ResidualVM merger, I guess.)
2020-10-12 18:44:15 +02:00
Eugene Sandulenko
7ff34bc9ec PLUGINS: MetaEngineStatic -> MetaEngineDetection 2020-10-11 23:14:39 +02:00
aryanrawlani28
71a820caff ENGINES: Begin class renaming of ME & AME
- ME -> MetaEngineStatic (static parts)
- MEC -> MetaEngine (dynamic parts)
2020-10-03 14:56:36 +02:00
aryanrawlani28
c48719404a BASE: PLUGINS: Rename plugin matching helpers
- give*From* -> get*From*
2020-10-03 14:56:36 +02:00
aryanrawlani28
81ba5d5627 ENGINES: ME & MEC: Allow MEC to build engine options widget.
- Rename the one in ME to avoid ambiguity.
- ME is named *static & MEC is named *dynamic.
- This change means that engines  can build 2 types of option widgets.
- The "Engine" tab is created statically regardless if an engine plugin is present or not.
- The in-game options are built using the MEC.
- With this commit, engines/dialogs is no longer dependant on MetaEngine, and instead used MEC all over.
2020-10-03 14:56:36 +02:00
aryanrawlani28
1616d7d515 ENGINES: ME & MEC: Move achievements-related code to MetaEngineConnect
- Adjust accordingly for dialogs.
2020-10-03 14:56:36 +02:00
aryanrawlani28
0cc8719417 BASE: ENGINES: Adapt to keymaps moving to engine plugins
- Also improvise usage of MetaEngineConnect in main.cpp a bit.
2020-10-03 14:56:36 +02:00
aryanrawlani28
68d01321d6 GUI: U32: Downscale changes of U32, fix review issues
This commit addresses a range of changes, within scummvm subproject.

- Audio files, like mididrv, remove U32String based name and identifier, because ASCII only.
- mididrv.cpp had some wrong format for warning messages, fix those
- Message dialogs were modified to use default arguments more often, but reverting back to the orignal to minimize changes.
- SetTooltip has a fake constructor that takes in a string, and use it.
- U32Format had some break statements missing, add those.
- RemapWidget: Use fake constructor for setLabel and setTooltip, to make minimal changes
- SDL: setting text in clipboard no longer uses SDL_iconv_string
- TTS: Override base class "say" with strings, so tts->say can be used with normal strings too.
- About dialog: fix incorrect code for u32string variables
- Fix some extra brackets
- Some buttons were incorrectly removed from using translated labels, revert those
- Message Dialog: Pass default and alt buttons as const references
- Saveload Dialog: Use translations in missing places, use const-references. Also, use translations in a correct manner.
- Use const references for tooltip in GraphicsWidget, EditTextWidget, error.cpp
- DomainEditTextWidget: Use U32String for text
2020-08-30 14:43:41 +02:00
aryanrawlani28
d12c6c4338 GUI: U32: Code cleanup
- Remove extra parantheses leftover from temp code
- SaveLoadDialog - do not encode when setting labels
- Remove mapping variable from ThemeEngine::loadScalableFont (and use default 0)
- Remove incorrect u32 constructor wrapper from confman.set in eventrecorder.cpp
2020-08-30 14:43:41 +02:00
aryanrawlani28
160a1320cc GUI: U32: Rename more temp code and fix issues
- Remove convertFromU32.. where necessary
- Replace convertFromU32 to .encode() for better readability
- Fix spacing issues in tabs
- Fix spacing issues in popups
- Fix weird font rendering in certain menus.
- Fix dialog changing sizes by huge amount when changing languages
- Some minor changes from String::format to U32String::Format
2020-08-30 14:43:41 +02:00
aryanrawlani28
96912f4adb GUI: U32: Rename some references of strings to use U32() & not helper method 2020-08-30 14:43:41 +02:00
aryanrawlani28
f800ca4ada GUI: U32: Convert majority of code to use U32
This commit also includes some additional major changes.

- Return U32String from TransMan getTranslation()
- Change tooltips to be U32Strings
- Remove temporary code of convertToU32String
- U32 Support various dialogs (Browser, FileBrowser, Messages, Chooser, etc)
- U32 for music plugins
- U32 for OSD messages
- Add some helper functions to ustr.cpp
- Change default tooltips from nullptr & 0 -> ""
- Some runtime exceptions may occur when changing languages due to incorrect String::Format
2020-08-30 14:43:41 +02:00
aryanrawlani28
5f2af6b93e GUI: U32: Add u32 support to Editables and Dialogs
- Editable widgets
- Lists
- SaveLoad Dialogs
- Browser Dialogs
2020-08-30 14:43:41 +02:00
aryanrawlani28
aafade4507 GUI: U32: Shift most widgets to draw with u32
- ButtonWidgets (Button, Radio, Checkbox, dropdown)
- StaticTextWidgets
- PopUpWidgets
- Tabs
- Add a temporary overloaded drawDDText function to make other widgets draw normally
2020-08-30 14:43:41 +02:00
aryanrawlani28
7e27af8148 GUI: Code cleanup 2020-06-22 00:03:02 +02:00
aryanrawlani28
f3e4e3e009 GUI: Code & comment cleanup, fix review issues 2020-06-22 00:03:02 +02:00
aryanrawlani28
732e79b1cf GUI: RTL: Add disabled code for tab drawing 2020-06-22 00:03:02 +02:00
lolbot-iichan
c09abee01c GUI: Add GUI for per-game achievements tab 2020-04-29 10:31:36 +02:00
Bastien Bouclet
f7efd3cd7f GUI: Fix error when renaming a target in the edit game dialog
The OptionsContainerWidget keeps a copy of the name of the game domain
that needs to be updated when the target is renamed.

Ideally, OptionsContainerWidget would simply keep a pointer to the
ConfigurationManager::Domain object, however that's not currently
possible as the ConfigurationManager defaults are global instead of
being per domain. As a result they are not accessible from the Domain
object.

Fixes #11416.
2020-04-11 08:16:21 +02:00
Bastien Bouclet
bcfb7145fa GUI: Allow engines to define a fully custom tab in the edit game dialog
By implementing MetaEngine::buildEngineOptionsWidget, engines can
instantiate a container widget that will be shown in the Engine tab of
the edit game dialog. The default implementation retains the existing
behavior and shows the extra GUI options.
2020-03-28 07:38:39 +01:00
Cameron Cawley
7488e17c0a GUI: Allow shaders to be selected for individual targets 2020-03-09 18:01:14 -05:00