Game controller input is now enabled whenever a compatible device is
connected. The keymapper's keymaps are refreshed when a joystick is added
or removed.
Fixes#10366.
Without an explicit size the layout system does not have enough
constraints to produce nice looking dialogs. Up until now the workaround
was to set explicit an size for some of the widget. This worked well
enough except when resizing down the window up until the widget size
constraints could no longer be enforced. At that point, produced layouts
looked too squished.
If the autosave slot doesn't yet have any file in it, when the
GMM save dialog is open, the autosave slot will show a default
'Autosave' entry which is write-only, to prevent users
accidentally making a savegame in that slot
Resolves a bug with displaying the wrong (previous) translation when switch theme language
Previously, a translated string was stored in cloudmanager _storages config items, which would become stale if the theme language was changed.
The testbed configuration dialog was previously re-using the browser
dialog. That dialog is defined to overlay the game list from the launcher
screen. However, while in the testbed engine the dimensions of
the layout of the launcher dialog may have been lost, causing the
configuration dialog to fail to layout.
Some dialogs overlay the launcher's game list. However, the launcher is
not always shown and as such is not always layed out. Laying out the
dependent dialogs would fail. This problem was indroduced with the
dynamic layout system. Previously the dialogs were layed out eagerly on
theme initialization. Which is no longer possible as dialogs now need to
be initialized to be layed out.
Previously it was only possible to specify whether items where aligned
to the start or centered in the cross direction of the layouts. It is
now additionally possible to align the items to the far end of the cross
direction or to resize them to match the size of the layout.
Terminology and behavior are loosely based on CSS's flexbox containers.
Prior to this change, a GUI layout was only affected by the screen size.
Now, a layout can additionally be influenced by the GUI dialog and widgets
that uses it. This capability is leveraged to implement the following
features:
* Layout elements that are not bound to a GUI widget do not take space.
This means that dialogs where the widgets shown depend on for example
a feature being enabled at configure time no longer have blank spaces.
* Widgets can define a minimal required size for their contents not to be
cut. For now this is only used for buttons so their width is always
sufficient for their caption not to be cut. This mechanism could be
applied to other widget types in the future.
The engineId, gameId and description come from static data in the game
engines. When the game engines are compiled as dynamic plugins, the QGD
structure may outlive the engine plugin. Making a copy ensures the data
remains available.
Fixes#11292.
DropdownButtonWidget is a button split in two parts vertically. Clicking
the left part triggers a default action. Clicking the right part shows a
list of other actions the user can choose from.
Using this widget on the launcher lets 'Mass add' be a secondary action
of the 'Add' button, removing the necessity of pressing the shift key to
access the feature.
Qualified game names have the following form: engineId:gameId.
Unqualified game names are still supported as long as they are not
ambiguous. However they are considered deprecated and are no longer
displayed by the --list-games command.
The engine ID identifies which engine should be used to launch the target.
Also remove the 'single ID' system. Different games from engines that used
that system now have different game IDs.
Also-By: Matthew Hoops <clone2727@gmail.com>
The height of the tab widget was reduced by 2px in
eabb81829f. However, that change caused
the tab nav buttons to be drawn slightly outside of the tabs with the
low resolution layout.
The changes in 1dce33dd9f introduced a
case where the width of widgets would not be set. This commit reverts
the offending changes and introduces a different fix for the original
issue.
Only recompute the width/height of a stack if it is not explicitly set.
Fixes#11214.
* Testing if a widget can be centered was ignoring the padding.
* Only resize a layout based on its content if it was not explicitely
sized by its parent. Fixes the logo causing incorrect layout
computations when the window width is lower than the image width.
Selecting whether a clipping variant of a draw call needs to be used is
no longer the responsibility to the caller. The clipping rect is now
part of the state of the renderer.
Also fix some of the draw calls to better apply the clipping rect.
* Delete multiple empty rows
* Make getVolume non-virtual and leave just the implementation
in base class
* Resolve warning about signed / unsigned comparison in
gui-manager
* Clear availableVoices when updating voices on linux
* By default set language to transMan language on windows
(if the transMan is available)
* Remove freeVoices method from Windows ttsMan, it isn't needed
anymore
- Add comment to tts initialization on Windows
- Correctly free the voicesInfo in linux ttsMan
- Remove popState method from linux-text-to-speech.h and
windows-text-to-speech.h
- Add tts to help in configure
- Refactor language setting in gui-manager.cpp
It counted with english being the default language in
ttsMan constructors, which isn't true anymore.
The ScummVM was crashing because of an assert, when there was less
voices availaible, than what was set in the ConfMan.
Now the voice just falls back to 0th voice, if there are not
enough voices.
Unfortunatedly the encoding used by ScummVM breaks the
speech-dispatcher, so after trying to say non-ascii character
the connection has to be restarted. So for now I am restricting
the GUI TTS to english only.
This removes the usage of memset to clear complex structures and replaces
them with constructor methods for the structures which will be executed
when these are instantiated.
Calling reflowLayout() not only updates the layout (as setupCloudTab()
was already doing), but also recalculates scrollbar. The issue was that
old layout didn't need a scrollbar, but updated layout did. But,
ScrollContainer was not notified, and thus scrollbar didn't appear
(until user tried to reselect the Storage via popup).
This comment for fall through to prevent the compiler warning about
this has to be at the point of fallthrough i.e. outside the grouping
brackets to be effective.
Well, it ain't a fix, because it's not exactly correct for any of the
themes. Yet it's the best for all of them. If I put what seems to be
correct, "modern" theme gets ruined, because it has this mystical 2px
offset in tabs/scrollcontainers.
- removed +1px in ListWidget, added in lordhoto's 2007 commit 68eb28a
(aka r29971 in svn) `Fix for bug #1670082 "GUI: Modern theme gfx glitch
in launcher".`, because it made clip this last line of scrollbar in all
themes, which doesn't look good. In 2007 theme was written in .ini,
which is not the case now. I don't see any glitches after removing this
"fix";
- fixed how scrollbar top and bottom scroll buttons are drawn in
ThemeEngine::drawScrollbar: there were these weird magic numbers, but in
reality extra space that buttons should occupy is hardcoded in
scrollbar.cpp (ScrollBarWidget) and is just +1px.
- added missing 'd' in "%d" in SavesSyncRequest;
- removed trailing ',' in enum in gui/options.h;
- fixed #endif to have // before USE_LIBCURL in gui/options.h.
GlobalOptionsDialog is now also a CommandSender, so it could send
command "scroll to the top" when storage is disconnected in Cloud tab
(layout updates, that's why scrolling is needed).
All local webserver-related settings are now shown in a separate, "Wi-Fi
Sharing" tab (shown if built with USE_SDL_NET). Cloud tab is only shown
if actual cloud storages are built (USE_LIBCURL).
- StorageWizardDialog is removed, along with bmps it was using;
- EditTextWidget now accepts custom font in constructor;
- ScrollContainer scrollbar now jumps to top when content height changes
so it's "overscrolled";
- IndexPageHandler now does not awaits for `code` GET-parameter, as
local webserver is no longer used to connect Storages;
- CloudManager and all corresponding Storages are updated to support
disconnecting and to notify about successful connection.
* The list of candidates now includes unknown variants. When an unknown
variant is selected, the unknown game dialog is shown.
* On the unknown game dialog, users are given the choice to add the game
when that is possible, or to cancel.
The goal of those changes is to make the unknown game dialog less
confusing for users, especially when both known and unknown games
variants are found.
The GUI system was originally written completely by me, as is easily
verifiable by inspecting the commit logs of the gui subdirectory, or e.g.
specific files like gui/widget.cpp.
The redirect rule on the web site expected only two query items, one
with the engine name and another one with the description. However it
was a bit lax in its regex and we could pass additional query items
as part of either the engine name or description. The unknown game
dialog was abusing it to pass a summary.
The rewrite rule for the URL on the web site has now been fixed to
avoid such abuse. And instead it also adds a summary. So the
unknown name dialog should no longer provide one.
The code is still disabled, but it is now in a working state and
can be tested by removing the #if 0 and changing the URL to a test
server with a redirect rule.