Commit Graph

115 Commits

Author SHA1 Message Date
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
Donovan Watteau
18ab6803d6 JANITORIAL: Fix various "an" typos in comments 2023-03-16 14:47:28 +01:00
Le Philousophe
0fdf53f984 ANDROID: Remove platform specific code from shared code 2023-01-20 14:14:03 +01:00
Vladimir Serbinenko
f9d0da86e3 GUI: Fix browsing in presence of files with \1 in names
Currently file containing \1 in its name causes erroring out
with "Wrong string format".

Hades Challenge Mac partiton has such files in the root. So if they are
copied then it's impossible to select folder with Hades Challenge. Many tools
skip (as they are hidden) or rename them while saving original name in
AppleDouble or MacBinary. dumper-companion also renames them but scummvm
transparently decodes punycode back.
2022-11-06 23:22:40 +01:00
Eugene Sandulenko
829c600a02
GUI: Remove remains of the old color lists in *ListWidget 2022-05-29 00:39:35 +02:00
antoniou79
37e74af914 GUI: Fix missing parentheses causing build failure 2022-03-02 15:19:09 +02:00
Antoniou Athanasios
3ee5a99619 ANDROID: More safeguards against empty path in browser 2022-03-02 14:29:56 +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
SupSuper
c9d67e48a9 BACKENDS: Use FSNode::getName in string operations 2021-08-23 21:22:27 +01:00
antoniou
f900cbecdd ANDROID: Fix reset browser_lastpath via button
Also replace literal "scummvm" with Common::ConfigManager::kApplicationDomain in android options
2021-08-12 15:17:32 +03:00
Cameron Cawley
c877097b49 ALL: Remove use of "" in Common::U32String constructors 2020-11-16 16:56:58 +00:00
aryanrawlani28
9bf3f73d8a GUI: U32: Use U32Strings for native dialogs
- Make DialogManager showFileBrowser take in u32
- Show filebrowser with u32 in MacOS and GTK
2020-08-30 14:43:41 +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
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
Thanasis Antoniou
6e7bfc5b78 GUI: Don't store an invalid browser_lastpath in updateListing() 2020-02-11 00:54:56 +02:00
Bastien Bouclet
6e1abf064a GUI: Use nullptr instead of 0 or NULL where appropriate 2020-01-19 15:08:37 +01:00
SupSuper
7552b0c008 GUI: Store title String instead of unsafe pointer 2018-12-16 10:48:13 +00:00
SupSuper
fc504996d3 GUI: Allow user to opt between GUI browser and native browser 2018-12-16 10:48:13 +00:00
SupSuper
fbc9c7d371 BACKENDS: Hook GUI browser to DialogManager 2018-12-16 10:48:13 +00:00
Bastien Bouclet
ac4b2efd3f GUI: Clean up file browser path entry 2018-08-27 06:39:40 +02:00
Chatziargyriou Eleftheria
4188ba1252 GUI: Add editable path in file browser dialog 2018-08-22 00:39:51 +01:00
Bastien Bouclet
5878c618c9 GUI: Remove Dialog::markAsDirty to expose full GUI redraws 2018-01-27 18:12:34 +01:00
Bastien Bouclet
0496ede62f GUI: Implement dirty-checking for widget redraws 2018-01-27 18:12:34 +01:00
Bastien Bouclet
dac70196f0 GUI: Fix hidden files visibility getting out of sync in the files browser
- The checkbox state was not initialized when opening the dialog.
- The visibility state was initialized from ConfMan too early resuling
  in the value being incorrect when multiple file browsers are used.
2016-08-30 21:19:59 +02:00
Johannes Schickel
f5dfe6725a GUI: Make GPL headers consistent in themselves. 2014-02-18 02:39:35 +01:00
Johannes Schickel
0a3e00b307 GUI: Allow user to display hidden files in the browser dialog.
This implements feature request #3600774 "File browser: show hidden files".
2013-01-27 19:13:44 +01:00
strangerke
69b1485a22 GIT: Clean up: Suppress SVN tags, now useless 2011-05-12 01:16:22 +02:00
Ori Avtalion
9414d7a6e2 JANITORIAL: Reduce header dependencies in shared code
Some backends may break as I only compiled SDL
2011-04-28 15:08:58 +03:00
Max Horn
668adaa461 GUI: Rename gui/GuiManager.* to gui/gui-manager.*
svn-id: r54265
2010-11-16 10:19:01 +00:00
Max Horn
427dc1ae93 GUI: Move major widgets to new directory gui/widgets
Also renamed the source/header files, now they are more closely
aligned to how we rename most other source files

svn-id: r54264
2010-11-16 10:11:57 +00:00
Thierry Crozat
1f986e14af i18n: Add lowres context in a few places.
I also changed the english text for the GUI Renderer items in 1x mode
as the text was tool long and cut.

svn-id: r52683
2010-09-12 11:43:51 +00:00
Eugene Sandulenko
01f9006ee7 GUI: Implement tooltips. FR #2821513.
FR #2821513: "GUI: add tooltips".
Added tooltips for Add Game button, clear field buttons and couple
other.

Current problem: Only first call correctly restores text. I could
not find where restore information gets lost.

svn-id: r49774
2010-06-15 10:52:35 +00:00
Eugene Sandulenko
3fafa07ab0 GUI: Added in-place hotkeys for widgets.
Now it is possible to specify hotkeys in place for ButtonWidget
and CheckboxWidget (the only widgets with hotkeys now).

Use de-facto standard with putting hotkey between tildes (~).
Like '~O~pen'. The tildes gets stripped before after hotkey
is extracted.

This is done for giving translators possibility to specify
their own hotkeys.

Old hotkeys defined at widget instance creation are left for
leaving possibility to specify non-printable hotkeys such as
Common::ASCII_ESCAPE.

Translation files were updated respectively.

svn-id: r49766
2010-06-15 10:47:31 +00:00
Eugene Sandulenko
859212df25 Implement translation support for ScummVM GUI.
Based on patch #2903830: "Updated Translation Prototype" by alexbevi
which in turn is based on patch #1739965 by jvprat.

Currently it builds all translations right into ScummVM. Once the
feature will be accepted more widely, i.e. more translations will
pop up, it will be trivial to move translation strings to external
file.

Finished translation: Russian
Unfinished translation: Hungarian

Things which are nice to do:
 - Language code -> language mapping for more user friendness
 - Specifying fonts to be used with language
 - Updating of interface language without restart. It will require
   moving of much code to reflowLayout() methods for each dialog

The .po files must be in single byte encodings. I.e. no support
for Unicode.

svn-id: r49759
2010-06-15 10:44:51 +00:00
Max Horn
c934642bdb COMMON: Move typedef StringList from str.h to new header str-array.h
This removes the dependency on array.h from str.h.
Also, begun migration from the confusing type name "StringList" to
the more appropriate StringArray.

svn-id: r48282
2010-03-18 15:09:24 +00:00
Oystein Eftevaag
9d70103d9c The file selection dialog in OS X now uses Cocoa instead of Carbon, and lives in a separate file due to having to be compiled as Objective-C++. ScummVM can now run in x64 natively on OS X
svn-id: r46581
2009-12-26 13:35:57 +00:00
Johannes Schickel
8f34e4b11c Commit of the 2nd revision of my patch for FR# 2840967 "GUI: Display filenames in "Add games"'s file dialog", since it seems on "Making it easier for users to add games" on -devel the majority of developers, who commented, are for this.
svn-id: r46312
2009-12-09 16:48:33 +00:00
Oystein Eftevaag
b25afc85a6 Build fix for 64-bit OS X
svn-id: r45920
2009-11-15 12:18:13 +00:00
Johannes Schickel
387afcc113 Fix Browser dialog name.
svn-id: r42941
2009-07-30 19:43:53 +00:00
Vicent Marti
108d4cfbd0 Reverted previous commit.
svn-id: r36226
2009-02-06 23:28:08 +00:00
Vicent Marti
30189f09d9 Removed special case when redrawing the dialog stack. Fixes bug #2555710 and several lesser graphical glitches with classic theme.
svn-id: r36225
2009-02-06 22:16:04 +00:00
Johannes Schickel
8ff3f14e29 Fix for bug #2533091 "MAC: Cannot add games in the launcher in fullscreen mode".
svn-id: r36036
2009-01-24 16:27:52 +00:00
Willem Jan Palenstijn
0ab01c756a open browser dialog before manipulating it (fixes assert when pressing 'add game')
svn-id: r35807
2009-01-10 22:31:15 +00:00
Johannes Schickel
690b88f982 Renamed gui/newgui.cpp -> gui/GuiManager.cpp and gui/newgui.h -> gui/GuiManager.h
svn-id: r35668
2009-01-02 03:21:40 +00:00