Commit graph

156 commits

Author SHA1 Message Date
lat9nq
e85f105a75 yuzu qt: Start games from context menu
This connects the BootGame function to the context menu. In addition,
there is an option to boot without using the custom configuration.
2021-06-07 20:27:51 -04:00
Maide
416bc9dce5 [game_list] Correct light theme loading (#6408)
Correct light theme loading

The setLayout call in game list instantiation will call resizing signals with default values in light theme, which was then being erroneously saved. setLayout doesn't seem to call resizing for any other theme, so I'm not sure why that happens.
2021-06-03 19:07:38 -04:00
bunnei
5e19cefd59 Merge pull request #6402 from Kelebek1/UI
game_list: Stop the columns resizing on NAND install
2021-06-03 00:24:45 -07:00
bunnei
3aa1dc5030 Merge pull request #6403 from Kewlan/game-list-for-loop-optimization
game_list: Minor for loop optimizations
2021-06-02 15:27:54 -07:00
Kewlan
84dbd57545 game_list: Minor for loop optimizations
There's no need to check the first and last rows since they'll always be the Favorites and AddDir rows.
Also change the name of the clear_all variable for consistency.
2021-06-02 16:19:55 +02:00
Kelebek1
81f77ddfe7 Stop the columns resizing on NAND install 2021-06-02 06:27:08 +01:00
lat9nq
d8a19d286b yuzu qt: Handle per-game configs for title id 0
Currently with programs that have a 0 title id, yuzu loads the custom
configuration 0000000000000000.ini for per-game configs. This is not
ideal since many homebrews share this id. Instead for these programs, we
load a config that is simply the file name and `.ini` appended to it.
2021-05-25 20:10:41 -04:00
Morph
37f456bb09 Merge pull request #6263 from Kewlan/folder-swap-expand-state
game_list: Fix dir move up/down expand state
2021-05-02 07:43:45 -04:00
Kewlan
9098ceeef3 game_list: Fix dir move up/down expand state 2021-04-30 12:18:38 +02:00
Kewlan
8522d5848f game_list: Update filter results when removing directories 2021-04-30 00:05:23 +02:00
Kewlan
886fdb2687 game_list: Mark games as favorite to make them appear at the top.
Icons are from Icons8.
2021-04-15 07:15:42 +02:00
FearlessTobi
a4e67c9402 game_list: Fix folder reordering
The bug(s) happened because we swapped the contents on values.game_dirs, but the pointer each item had to their respective game_dir wasn't updated. This made it so that the item had the wrong game_dir associated with it after a "move up" or "move down" operation. It can be observed by choosing "open directory location" after such operation.

Changed from raw pointer to an index because it's equivalent but a bit clearer, but the change is not essential.

Co-Authored-By: Vitor K <29167336+vitor-k@users.noreply.github.com>
2021-01-18 01:22:54 +01:00
Lioncash
1c11424586 yuzu: Migrate off of setMargin() to setContentsMargins()
setMargin() has been deprecated since Qt 5, and replaced with
setContentsMargins(). We can move over to setContentsMargins() to stay
forward-compatible with Qt 6.0.
2021-01-13 07:29:59 -05:00
ReinUsesLisp
6ed317da95 qt/game_list: Give GameListSearchField::KeyReleaseEater a parent
This fixes a memory leak as KeyReleaseEater's destructor was never
called.
2020-09-29 16:23:16 -03:00
Lioncash
ab1b7eefc8 game_list: Make game list function naming consistent
Makes the naming consistent with the rest of the functions that are
present.
2020-09-23 11:28:11 -04:00
Lioncash
2827ce5194 game_list: Eliminate redundant argument copies
Several functions can be taken by const reference to avoid copies
2020-09-23 11:20:12 -04:00
bunnei
0e803716d2 Merge pull request #4381 from Morph1984/fix-open-folder-installed-title
main: Fix Open Save/Mod Locations for installed titles
2020-08-18 12:54:06 -04:00
Lioncash
f9fe50958e yuzu: Resolve -Wextra-semi warnings
While we're in the same area, we can ensure GameDir member variables are
always initialized to consistent values.
2020-08-16 03:58:29 -04:00
Morph
714a04ebd8 main: Fix Open Save/Mod Locations for installed titles
Previously NAND/SDMC installed titles would open device saves when they are supposed to be user saves. This is due to the control nca not being read and thus returns 0 for both GetDefaultNormalSaveSize() and GetDeviceSaveDataSize(). Fix this by utilizing the patch manager to read the control nca.
2020-08-04 21:14:20 -04:00
Morph
d15eb82edc game_list: Limit context menu options for homebrew
Hides the following options when the title id is 0:
- Open Save Location
- Open Mod Data Location
- Open Transferable Shader Cache
- All removal options except Remove Custom Configuration
2020-07-29 06:50:30 -04:00
Morph
c756d76945 game_list: Add "Remove" context menu
Adds the following actions:
- Remove Installed Update
- Remove All Installed DLC
- Remove Shader Cache
- Remove Custom Configuration
- Remove All Installed Contents
2020-07-29 06:50:30 -04:00
Lioncash
f13c3a81e7 CMakeLists: Make use of /std:c++latest on MSVC
Provides the buildbot with one builder that is always tracking the
latest version of the C++ standard, allowing us to progressively rectify
our code and amend any differences between standards over time instead
of waiting for a complete standard change, potentially breaking a lot of
code all at once.
2020-07-11 04:45:40 -04:00
bunnei
3439618956 yuzu: game_list: Fix 'Open Save Data Location' for device saves. 2020-05-11 12:54:30 -04:00
FearlessTobi
afde397c81 yuzu: Fixes to game list sorting
Should fix citra-emu/citra#4593.
As the issue might not be entirely clear, I'll offer a short explanation from what I understood from it and found from experimentation.

Currently yuzu offers the user the option to change the text that's displayed in the "Name" column in the game list. Generally, it is expected that the items are sorted based on the displayed text, but yuzu would sort them by title instead.

Made it so that an access to SortRole returns the same as DisplayRole.
There shouldn't be any UI changes, only change in behaviour.

Also fixes a bug with directory sorting, where having the directories out of order would enable you to try to "move up" to the addDirectory button, which would crash the emulator.

Co-Authored-By: Vitor K <vitor-k@users.noreply.github.com>
2020-04-06 03:12:17 +02:00
ReinUsesLisp
5b425010bd yuzu/game_list: Silence -Wswitch and -Wunused-variable 2019-10-04 23:41:22 +00:00
fearlessTobi
84b839d021 Limit the size of directory icons, fix text when icon size is none 2019-09-04 16:47:33 +02:00
fearlessTobi
8289656196 Change QList to QVector 2019-09-04 16:47:33 +02:00
fearlessTobi
56f0da852a Separate UserNand and Sdmc directories 2019-09-04 16:47:32 +02:00
fearlessTobi
51734c36f7 Address more trivial review comments 2019-09-04 16:47:32 +02:00
fearlessTobi
5eb2368b6b Address trivial review comments 2019-09-04 16:47:32 +02:00
fearlessTobi
890b0ce5f6 yuzu: Add support for multiple game directories
Ported from https://github.com/citra-emu/citra/pull/3617.
2019-09-04 16:47:32 +02:00
Lioncash
7c15a53048 yuzu/CMakeLists: Remove qt5_wrap_ui macro usage
We can simply enable CMAKE_AUTOUIC and let CMake take care of handling
the UI code generation for targets.

As part of letting CMake automatically handle the header file parsing,
we must not name includes with "ui_*" unless they're related to the
output of the Qt UIC compiler. Because of this, we need to rename
ui_settings, given it would conflict with this restriction.
2019-08-09 17:54:08 -04:00
Zach Hilman
5f6dba8ece game_list: Accept *.kip as a file extension of executables 2019-06-05 00:33:05 -04:00
Lioncash
b254ac5a1e yuzu/game_list: Specify string conversions explicitly
Allows the game list code to compile successfully with implicit string
conversions disabled.
2019-05-20 15:30:50 -04:00
FreddyFunk
27f51145b5 Fix Clang Format 2019-04-12 16:40:35 +02:00
FreddyFunk
9ddb70acb2 ui_settings: Rename game directory variables 2019-04-11 19:55:56 +02:00
bunnei
53c9e7aab2 Merge pull request #1957 from DarkLordZach/title-provider
file_sys: Provide generic interface for accessing game data
2019-04-09 19:16:37 -04:00
Zach Hilman
ec383a021b game_list: Register content with ContentProvider 2019-03-26 22:05:37 -04:00
unknown
b1e56cc6b2 frontend: Open transferable shader cache for a selected game in the gamelist 2019-02-08 09:05:51 +01:00
bunnei
e3e62ddf7e Merge pull request #1848 from FreddyFunk/QJsonArray
game_list: Remove a reference of a reference
2019-01-12 02:01:13 -05:00
Zach Hilman
cb527149ee qt: Add Properties menu to game list right-click 2018-12-04 13:34:50 -05:00
Frederic Laing
5b61b0124c game_list: Remove a reference of a reference 2018-12-03 19:26:36 +01:00
Bartosz Kaszubowski
d9193f8718 remove border from GameList 2018-11-30 23:35:08 +01:00
Zach Hilman
defffa3ec3 game_list: Make add-ons column optional
As the add-ons column takes the most processing time out of any (as it needs to search registration for updates/dlc, patch control NCAs, search for mods, etc.), an option was added to disable it. This does not affect the application of add-ons. In large game collections, this decreases game list refresh time by as much as 70%.
2018-11-01 20:27:12 -04:00
bunnei
7163b7d506 Merge pull request #1568 from lioncash/dir
game_list: Use QFileInfo instead of common's file functions
2018-10-24 17:13:51 -04:00
Lioncash
849265a3de game_list: Use QFileInfo instead of common's file functions
We can just use the facilities that Qt provides instead of pulling in
stuff from common. While we're at it, we can also simplify the nearby
logging statement's argument by just calling .toStdString()
2018-10-24 08:40:22 -04:00
Lioncash
17c920b7a4 game_list: Make game list column headers translatable
These are user-facing strings, so they should be marked as translatable
2018-10-24 08:20:35 -04:00
bunnei
a5f39e4de1 Merge pull request #1360 from FearlessTobi/port-3979
Port citra-emu/citra#3979 game_list: move SearchField to game_list_p.h and fix untranslated text
2018-09-27 17:09:11 -04:00
Zach Hilman
600867c594 qt: Add UI elements for LayeredFS and related tools 2018-09-21 19:53:33 -04:00
zhupengfei
4dc46e8bae game_list: move SearchField to game_list_p.h and fix untranslated text
I have tested and made sure the text is translatable, but this would require a translation update to take effect.
2018-09-21 18:47:41 +02:00