Commit graph

18199 commits

Author SHA1 Message Date
Léo Lam
d0169fe8db Boot: Re-use the disc volume
Saves some disc IO.
2017-06-06 16:31:16 +02:00
Léo Lam
6f6a18b1b0 Boot: Remove unneeded manual HLE function scan
Not needed. And the symbols would get overwritten by the symbol map
load that is just below.
2017-06-06 16:30:55 +02:00
Léo Lam
065261dbad Boot: Unify the ELF and DOL code paths
They're essentially the same. To achieve this, this commit unifies
DolReader and ElfReader into a common interface for boot executable
readers, so the only remaining difference between ELF and DOL is
how which volume is inserted.
2017-06-06 16:30:54 +02:00
Léo Lam
22992ae41e Boot: Clean up the boot code
* Move out boot parameters to a separate struct, which is not part
  of SConfig/ConfigManager because there is no reason for it to
  be there.

* Move out file name parsing and constructing the appropriate params
  from paths to a separate function that does that, and only that.

* For every different boot type we support, add a proper struct with
  only the required parameters, with descriptive names and use
  std::variant to only store what we need.

* Clean up the bHLE_BS2 stuff which made no sense sometimes. Now
  instead of using bHLE_BS2 for two different things, both for storing
  the user config setting and as a runtime boot parameter,
  we simply replace the Disc boot params with BootParameters::IPL.

* Const correctness so it's clear what can or cannot update the config.

* Drop unused parameters and unneeded checks.

* Make a few checks a lot more concise. (Looking at you, extension
  checks for disc images.)

* Remove a mildly terrible workaround where we needed to pass an empty
  string in order to boot the GC IPL without any game inserted.
  (Not required anymore thanks to std::variant and std::optional.)

The motivation for this are multiple: cleaning up and being able to add
support for booting an installed NAND title. Without this change, it'd
be pretty much impossible to implement that.

Also, using std::visit with std::variant makes the compiler do
additional type checks: now we're guaranteed that the boot code will
handle all boot types and no invalid boot type will be possible.
2017-06-06 16:27:52 +02:00
Léo Lam
4d2fb9b9ba Core: Replace BOOT_MIOS with an explicit "is MIOS" flag
I didn't know better back then, but the boot type is only supposed to
be used for the actual boot params. It shouldn't be used or changed
after booting.
2017-06-06 16:21:58 +02:00
shuffle2
096399d371 quick UB fix for 3c0bdd74 2017-06-06 03:49:01 -07:00
Leo Lam
c0495d1d11 Merge pull request #5559 from JosJuice/discio-rename
DiscIO: Remove C/I/S prefixes from class names
2017-06-06 12:47:33 +02:00
JosJuice
b2af07a7b7 DiscIO: Remove C/I/S prefixes from class names
These prefixes were inconsistent with the rest of Dolphin.

I'm also renaming VolumeWiiCrypted to VolumeWii because of 1113b13.
2017-06-06 12:31:59 +02:00
shuffle2
3c0bdd7473 Merge pull request #5558 from Tilka/fix_warnings
Interpreter: simplify srawx/srawix
2017-06-06 03:28:19 -07:00
shuffle2
3d6c278892 Merge pull request #5556 from shuffle2/jloehr-FixWiimoteReportSizeOnWindows
fix wiimote report size on windows
2017-06-06 03:26:14 -07:00
Tillmann Karras
7702771d61 Interpreter: simplify srawx/srawix
This also avoids -Wint-in-bool-context warnings in GCC 7.
2017-06-06 11:05:33 +01:00
shuffle2
1113b131f2 Merge pull request #5548 from JosJuice/volume-wii-unencrypted
Reimplement support for unencrypted Wii discs
2017-06-06 01:37:52 -07:00
Shawn Hoffman
2b0c600be5 windows: make IORead return number of valid bytes according to ReportID 2017-06-06 01:21:30 -07:00
JosJuice
d41bb375f1 Fix UB string comparisons
Also replacing auto& with const char* so that it's easier
to see that these strings aren't std::strings.
2017-06-06 09:02:29 +02:00
shuffle2
367fba8e06 Merge pull request #5199 from ligfx/default_gci_folder
Make EXIDEVICE_MEMORYCARDFOLDER the default for slot A
2017-06-05 21:56:04 -07:00
shuffle2
442e614021 Merge pull request #5536 from sepalani/getstring
HLE: Prevent GetStringVA to strip newlines
2017-06-05 21:31:09 -07:00
shuffle2
c8166951a0 Merge pull request #5418 from MerryMage/config-again-and-again
VideoConfig: Port to layered configuration system
2017-06-05 21:11:04 -07:00
Sepalani
f28f23af1d StringUtil: StringPopBackIf added 2017-06-06 05:08:51 +01:00
shuffle2
192fec50b9 Merge pull request #5276 from ligfx/macosheadless
Add headless support on macOS
2017-06-05 20:49:02 -07:00
Sepalani
1209959012 HLE: Prevent GetStringVA to strip newlines 2017-06-06 04:31:01 +01:00
shuffle2
9a9b0eed72 Merge pull request #5552 from sepalani/hle-print-warnings
HLE_OS: Fix missing-declarations warnings
2017-06-05 20:29:31 -07:00
Sepalani
190f7cbc4f HLE_OS: Fix missing-declarations warnings 2017-06-06 04:23:54 +01:00
shuffle2
2d941ad1e7 Merge pull request #5294 from sepalani/mem-view-ascii
MemoryView: Prevent non-ascii characters
2017-06-05 20:21:02 -07:00
shuffle2
2f73bc1735 Merge pull request #5293 from sepalani/mem-ascii
MemoryView: Fix empty string
2017-06-05 20:20:24 -07:00
shuffle2
0b00477c8a Merge pull request #5311 from ligfx/mixerdpl2
AudioCommon: Move DPL2 decoding into Mixer
2017-06-05 20:09:18 -07:00
shuffle2
98eb192226 Merge pull request #5312 from ligfx/cleanupupdatedrawrectangle
RenderBase: clean up UpdateDrawRectangle
2017-06-05 20:03:56 -07:00
shuffle2
3fed604ad9 Merge pull request #4878 from ligfx/geckodownloadcodes
Move GeckoCodeDiag download logic to GeckoCodeConfig (and make it use Curl)
2017-06-05 20:00:30 -07:00
Michael Maltese
97e6ba773b Move DSP::CodesToHeader to DSPTool
It's the only place it's used, and highly-specific to DSPTool's needs.
2017-06-05 19:28:40 -07:00
Michael Maltese
1765e54ab3 DSPCodeUtil: remove GenRandomCode
It was only used in a specific DSPTool test, which was removed because
non-deterministic tests aren't really useful.
2017-06-05 19:28:40 -07:00
shuffle2
b9b3b1dc19 Merge pull request #5347 from JosJuice/do-not-translate-button-names
Don't translate button names
2017-06-05 19:05:09 -07:00
shuffle2
bc8024ed21 Merge pull request #5549 from Starsam80/qt-title
Qt: Add the version to the window title
2017-06-05 18:49:50 -07:00
shuffle2
d51be949a9 Merge pull request #5524 from ligfx/llegba
Update free DSP ROM and coefficients to support GBA ucode
2017-06-05 18:40:20 -07:00
shuffle2
cd78a7249f Merge pull request #5408 from sepalani/assemble
CodeView: Assemble menu item added
2017-06-05 18:26:33 -07:00
shuffle2
065c3d78b7 Merge pull request #5486 from sepalani/hle-print
HLE: More printf logs added
2017-06-05 17:29:13 -07:00
shuffle2
497afbffab Merge pull request #5488 from ligfx/qtreordercolumns
DolphinQt2: reorder list columns to match DolphinWX
2017-06-05 17:17:08 -07:00
shuffle2
10e54c8a8e Merge pull request #5490 from ligfx/qtcontrollergridlayout
DolphinQt2: use GridLayout for ControllersWindow
2017-06-05 17:16:27 -07:00
shuffle2
b8f2e24dd5 Merge pull request #5546 from ligfx/qtdynamicthemes
DolphinQt2: live updates to UI theme
2017-06-05 17:15:17 -07:00
Michael Maltese
6b084e21dc SettingsWindow: update icons when theme changes 2017-06-05 17:04:29 -07:00
Michael Maltese
d6db515165 SettingsWindow: cleanup includes 2017-06-05 17:04:29 -07:00
Michael Maltese
4be07b4eb2 ToolBar: update icons when theme changes 2017-06-05 17:04:29 -07:00
Michael Maltese
9bdbd02efc GameListModel: update icons when theme changes 2017-06-05 17:04:29 -07:00
Michael Maltese
5a4ee87d6a DolphinQt2: Settings: emit ThemeChanged signal 2017-06-05 17:04:29 -07:00
Michael Maltese
328333dfb6 RenderWidget: hide cursor 2017-06-05 16:49:28 -07:00
Michael Maltese
833e38ed56 Settings: emit HideCursorChanged() 2017-06-05 16:49:28 -07:00
Michael Maltese
14da8232f6 ConfigManager: remove bAutoHideCursor
It's not used, and sounds like the same thing as `HideCursor`?
2017-06-05 16:49:28 -07:00
Michael Maltese
688f5ed267 DolphinQt2: move Path from toolbar to a pane 2017-06-05 16:46:10 -07:00
Michael Maltese
b296393644 GameList: when list is empty, double-click to add path
Simpler than opening the Paths window, and how DolphinWX does it.
2017-06-05 16:46:10 -07:00
Michael Maltese
20f54fd9ed DolphinQt2: add DoubleClickEventFilter
This is an easy way to get a `doubleClicked` signal for any type
of widget without creating custom classes for each one.
2017-06-05 16:46:10 -07:00
Michael Maltese
47e8cb97b4 DolphinQt2: move path signals from PathDialog to Settings 2017-06-05 16:46:10 -07:00
Michael Maltese
548522877a DolphinQt2: make Settings a singleton
With this, we can get signals when properties change.
2017-06-05 16:46:10 -07:00