Commit Graph

185 Commits

Author SHA1 Message Date
Shawn Hoffman cff4806d8d windows: fix build if pch were to be disabled 2020-08-22 16:18:24 -07:00
Jordan Woyak 13ee6bd7bb BTEmu/Wiimote: Cleanups/Fixes. 2020-08-16 11:38:13 -05:00
OatmealDome fae8f8d68b MainWindow: Attach quit emulation sheet to RenderWidget on macOS 2020-08-03 05:48:57 -04:00
JosJuice 5cad82137d Allow translations and custom names in GameFile::GetNetPlayName
There is no longer any major reason for why this function would
need to return the same result for all players.
2020-08-02 22:46:53 +02:00
JosJuice a41166bb37 Make netplay's "same game" check more robust
Instead of comparing the game ID, revision, disc number and name,
we can compare a hash of important parts of the disc including
all the aforementioned data but also additional data such as the
FST. The primary reason why I'm making this change is to let us
catch more desyncs before they happen, but this should also fix
https://bugs.dolphin-emu.org/issues/12115. As a bonus, the UI can
now distinguish the case where a client doesn't have the game at
all from the case where a client has the wrong version of the game.
2020-08-02 22:46:53 +02:00
JosJuice 2e8c5b4521 DolphinQt: Show a warning when launching an NKit disc image
It is my opinion that nobody should use NKit disc images without
being aware of the drawbacks of them. Since it seems like almost
nobody who is using NKit disc images knows what NKit is (hmm, now
how could that have happened...?), I am adding a warning to Dolphin
so that you can't run NKit disc images without finding out about the
drawbacks. In case someone really does want to use NKit disc images,
the warning has a "Don't show this again" option. Unfortunately, I
can't retroactively add the warning where it's most needed:
in Dolphin 5.0, which does not support Wii NKit disc images.
2020-07-29 21:05:57 +02:00
JosJuice e2ae2b3b0b Add new file format RVZ based on WIA 2020-06-17 13:47:34 +02:00
JosJuice 8da5d0c4fe Add an early version of WIABlobReader
It can currently only read the first 0x80 bytes of a disc image,
which is enough for identifying it but not for doing anything else.
2020-06-17 13:43:51 +02:00
Stenzek ff92357b63 Core: Use window instead of surface for ControllerInterface updates
Fixes crashes with Vulkan on macOS.
2020-05-24 17:39:56 +10:00
Léo Lam 7c0ef725ab
Merge pull request #8744 from cristian64/save_restore_netplay_browser_settings
DolphinQt: Saving and restoring NetPlay Session Browser dialog's settings.
2020-05-04 00:50:26 +02:00
Sepalani 39d34e133f Debugger: Add a Thread widget
DebugInterface: Add GetThreads

WatchWidget: Update widget on AddWatch
2020-05-03 20:48:30 +04:00
Christian Aguilera 16f0864a4f DolphinQt: Saving and restoring NetPlay Session Browser dialog's settings. 2020-05-03 17:45:52 +02:00
Sepalani 5e33cd48da Debugger: Add a Network widget
Display socket table, SSL context and options
2020-04-27 21:47:00 +04:00
JosJuice 55f787b898 Remove unused function Host_UpdateProgressDialog 2020-04-03 12:53:38 +02:00
JosJuice c6ee767851 DolphinQt: Run tasks that use progress dialogs on separate threads 2020-04-03 12:53:38 +02:00
Pokechu22 c59120f089 Fix Load Wii System Menu not updating after performing a disc update
For a fresh install, the button was completely disabled even after the disc update; otherwise, the text on it was just out of date.
2020-03-17 19:59:48 -07:00
Léo Lam 466c079bf4
Merge pull request #8604 from Techjar/netplay-index-direct
Core/NetPlayServer: Fix session not being added to index on direct connection type
2020-03-15 22:22:00 +01:00
Stenzek 86db015c23 Common: Add a render_window field to WindowSystemInfo
We need this because we need to pass the layer to MoltenVK, not
the view handle. But the input subsystem still needs the window.
2020-03-11 23:09:30 +10:00
Techjar 06a9f6ef82 Core/NetPlayServer: Fix session not being added to index on direct connection type 2020-02-17 21:05:32 -05:00
Tilka 5dfc9196ab
Merge pull request #8548 from jordan-woyak/wiimote-source-cleanup
Core/WiimoteReal: Wii remote connection pool and source change cleanup.
2020-01-25 23:04:50 +00:00
Jordan Woyak 956339df4e Core/WiimoteReal: Make wiimote source type an enum class and add Get/SetWiimoteSource functions. Add connected real Wii Remotes to a pool when a slot is not available. 2020-01-05 10:15:22 -06:00
Pokechu22 11bd132650 Implement RTC flag, which is counter-intuitively disc drive related 2020-01-04 11:43:26 -08:00
Silent 85c2841643
Make "Do you want to stop emulation?" application modal and disallow multiple instances at once
Fixes numerous issues with this dialog spawning multiple times
and putting Dolphin in a weird state.
2019-11-16 19:51:55 +01:00
Sepalani beeb68d541 RegisterWidget: Fix view in code/memory 2019-10-06 12:25:46 +04:00
Silent b6df0bff93
Make --batch run Dolphin in headless mode, provided --exec is also passed 2019-08-11 20:58:04 +02:00
Connor McLaughlin 1bd8f03362
Merge pull request #8271 from lioncash/qstring
DolphinQt: Replace unnecessary QStringLiterals with alternatives where applicable
2019-08-08 12:25:30 +10:00
spycrab 04764f8b7f Fix saving states freezing up emulation
Only for about half a second but noticeable nonetheless
2019-08-01 21:33:12 +02:00
Lioncash fef1b84f0a DolphinQt: Replace QStringLiteral with alternatives where applicable
QStringLiterals generate a buffer so that during runtime there's very
little cost to constructing a QString. However, this also means that
duplicated strings cannot be optimized out into a single entry that gets
referenced everywhere, taking up space in the binary.

Rather than use QStringLiteral(""), we can just use QString{} (the
default constructor) to signify the empty string. This gets rid of an
unnecessary string buffer from being created, saving a tiny bit of
space.

While we're at it, we can just use the character overloads of particular
functions when they're available instead of using a QString overload.
The characters in this case are Latin-1 to begin with, so we can just
specify the characters as QLatin1Char instances to use those overloads.
These will automatically convert to QChar if needed, so this is safe.
2019-07-30 09:06:03 -04:00
Vincent Duvert 2f63b71bde QtGui: Handle file open events
Handle file open events received by Dolphin. This allows Wii/GC files to be
opened when double-clicked or dropped on the Dolphin application on macOS.
2019-06-15 11:27:29 +02:00
Connor McLaughlin 0177c6c2c7
Merge pull request #8146 from Techjar/netplay-network-opts
Qt/NetPlayDialog: Change network mode options to radio buttons
2019-06-08 20:05:35 +10:00
Lioncash c0c0e412e0 Core/ConfigManager: Use forward declarations where applicable
Avoids dragging in IniFile, EXI device and SI device headers in this header which is
quite widely used throughout the codebase.

This also uncovered a few cases where indirect inclusions were being
relied upon, which this also fixes.
2019-06-07 19:54:39 -04:00
Techjar b0b4b69d6e Qt/NetPlayDialog: Change network mode options to radio buttons
This changes the Host Input Authority and Golf Mode checkboxes into a
set of radio buttons, consisting of Fair Input Delay, Host Input
Authority, and Golf Mode. This represents the 3 network modes we have.

Although Golf Mode is just an extension of Host Input Authority, it's
more logical to the user to present it as a separate option, rather
than enabling the Golf Mode checkbox only when Host Input Authority is
enabled. This also eliminates the need to first enable Host Input
Authority before Golf Mode can be enabled.

This also adds tooltips to provide brief descriptions of the options,
as well as reintroducing tooltips that were previously removed.
2019-05-31 02:33:41 -04:00
JMC47 6ea43235d5
Merge pull request #7841 from iwubcode/config-mgr-onion
Config: Move the 'Display' settings from ConfigManager to the layered config system
2019-04-21 00:01:47 -04:00
spycrab 23986d48f7
Merge pull request #7945 from spycrab/np_browser
Qt/NetPlay: Implement session/server browser
2019-04-06 12:36:29 +02:00
spycrab 094bf0d2ff Qt/NetPlay: Integrate NetPlayIndex 2019-04-06 12:27:30 +02:00
JMC47 a7ee00ae25
Merge pull request #7960 from Techjar/netplay-fix-segfault-on-exit
Qt/MainWindow: Fix segfault on exit while NetPlay is open
2019-04-05 11:48:07 -04:00
Techjar 1a12876330 NetPlay: Implement golf mode
This is an extension of host input authority that allows switching the
host (who has zero latency) on the fly, at the further expense of
everyone else's latency. This is useful for turn-based games where the
latency of players not on their turn doesn't matter.

To become the so-called golfer, the player simply presses a hotkey.
When the host is the golfer, latency is identical to normal host input
authority.
2019-04-05 07:01:03 -04:00
Techjar ab6583b430 Qt/MainWindow: Fix segfault on exit while NetPlay is open 2019-04-05 03:12:25 -04:00
Techjar e2f1da5210 NetPlay: Move host input authority logic to client
This is a prerequisite for golf mode, as the client needs to be in
control of sending pad states.
2019-04-02 08:17:13 -04:00
iwubcode 840afc2ad4 Config: Move the 'Display' settings from ConfigManager to the layered config system 2019-03-30 18:43:02 -05:00
JosJuice 6a18bf4d2e
Merge pull request #7935 from JosJuice/cli-arg-movie
DolphinQt: Add support for the --movie parameter
2019-03-27 18:34:24 +01:00
JosJuice 6451496776 DolphinQt: Add support for the --movie parameter
Regression from DolphinWX.
2019-03-27 14:26:17 +01:00
spycrab f7897778ff NetPlayChatUI: Add activate chat hotkey 2019-03-26 18:13:32 +01:00
Tilka 0a1aacb5d0
Merge pull request #7906 from jordan-woyak/leak-fix
DolphinQt/InputCommon: Fix a few memory leaks.
2019-03-21 23:26:54 +00:00
Jordan Woyak 94c4975b5d DolphinQt: Make Ctrl+F show the game list search and select the search text if already open. Escape closes. 2019-03-21 17:06:16 -05:00
Jordan Woyak 725d34b2f0 DolphinQt/InputCommon: Fix a few memory leaks. 2019-03-17 18:31:41 -05:00
JosJuice 185b1cf90c DolphinQt: Fix OnStopRecording/OnExportRecording logic 2019-03-13 17:35:20 +01:00
JosJuice 6c89957cf1 DolphinQt: Save movie when closing emulation
Missing feature from DolphinWX.
2019-03-13 15:40:36 +01:00
spycrab 70da86f1c3 Qt: Use ModalMessageBox everywhere 2019-03-04 21:53:02 +01:00
Tilka 8d59d1bb11
Merge pull request #7798 from ShFil119/impr/empty
Use empty instead of size
2019-02-13 01:59:43 +00:00
Filip Gawin 49fe9f5db1 Use empty instead of size 2019-02-13 00:03:49 +01:00
Jordan Woyak 0d1fbe7bbc WiimoteEmu: Major renaming and cleanup. 2019-02-02 19:40:31 -06:00
Stenzek 31a5dd15a9 DolphinQt: Connect Host::RequestStop() to MainWindow::RequestStop()
The fact that this wasn't connected was causing fifoplayer to hang if
looping was disabled.
2019-02-02 13:36:46 +10:00
JMC47 7907633126
Merge pull request #7715 from Techjar/qt-delete-unparented
Qt/MainWindow: Directly delete unparented dialogs
2019-01-28 06:42:07 -05:00
Techjar 408029e8a3 Qt/MainWindow: Don't unpause after confirming shutdown
There's no good reason to do this, as it just causes running signals to
be sent as the core is shutting down.
2019-01-26 07:27:37 -05:00
Stenzek c9c0b85056 VideoBackends: Store a backbuffer 'scale'
This is a scaling factor, used for hi-dpi configurations.
2019-01-25 11:15:57 +10:00
Techjar 47cc5b02e3 Qt/MainWindow: Directly delete unparented dialogs
Calling deleteLater in MainWindow's destructor doesn't work, as the
event loop will stop before it gets around to deleting these dialogs.
Seeing as this is a QObject destructor, we should already be on the
event loop anyways, so simply using delete should be safe.
2019-01-19 04:37:07 -05:00
Léo Lam 3627ef8a04
Merge pull request #7696 from TryTwo/Debugger_Restore_Tabbed_Docking
Qt/Debugger restore tabbed docking
2019-01-17 13:40:02 +01:00
Léo Lam a8bc6f9899
Merge pull request #7693 from jordan-woyak/hotplug-callback-fix
ControllerInterface: Hotplug callback fixes.
2019-01-16 21:00:48 +01:00
TryTwo b557faa386 Debugger restore tabbed docking 2019-01-11 14:32:27 -07:00
Jordan Woyak b425f86121 ControllerInterface: Allow hotplug callbacks to be unregistered and don't reload the entire config from the ini file on hotplug, just update the control references. This should fix a crash on shutdown on Android. 2019-01-10 18:32:16 -06:00
JosJuice 0c622929ba Add M3U file support for automatic disc switching 2019-01-04 09:24:42 +01:00
JosJuice bd665aad5d Automatic disc change for 2-disc games 2019-01-04 09:24:38 +01:00
spycrab 75b8824c95
Merge pull request #7658 from spycrab/debugger_show
Qt/Debugger: Add Show in Code / Show in Memory
2018-12-29 15:08:51 +01:00
spycrab 3e3f9565ec Qt/Debugger: Add Show in Code / Show in Memory 2018-12-28 20:30:38 +01:00
spycrab fc998093cc
Merge pull request #7600 from spycrab/resource_pack
Implement resource packs
2018-12-23 16:04:05 +01:00
spycrab 71d53c922f Implement resource packs 2018-12-19 11:03:09 +01:00
Léo Lam 2eb85c8fcf
Merge pull request #7594 from TryTwo/NestedDocks
Add nested docking to increase layout choices while debugging.
2018-12-05 17:14:46 +01:00
Techjar 577f6a5fb1 Qt: Disable controller configuration while NetPlay is running
Doing pretty much anything in the controller config breaks NetPlay
(desync and/or deadlock), as saving the settings reconfigures
controller interfaces, which NetPlay doesn't expect.
2018-11-29 07:31:45 -05:00
TryTwo c18aa36eab Add nested docking to increase layout choices while debugging. 2018-11-27 11:14:46 -07:00
Techjar ef89e4e70c NetPlay: Sync power button event
This fixes the deadlock on shutdown when Wii Remotes are in use.
2018-11-12 22:32:18 -05:00
Stenzek 52828901ef Core: Switch controller interface to render widget on booting
Previously, the Qt frontend would initialize the controller
interface on starting, resulting in the cursor position being
relative to the main window, instead of the render window.
2018-10-29 11:46:06 +10:00
Stenzek a7f334dc2a ControllerInterface: Don't crash on non-X11 QPA 2018-10-29 11:46:06 +10:00
Pierre Bourdon 9095233d21
Merge pull request #7483 from Zexaron/netplay_save-host-settings
Netplay: Properly save hosting settings
2018-10-29 01:44:41 +01:00
Pierre Bourdon 2071dea9b7
Merge pull request #7497 from stenzek/lazy-initialize
Qt/MainWindow: Lazy initialize child windows
2018-10-28 23:51:23 +01:00
Pierre Bourdon 98b0efb6de
Merge pull request #7499 from JosJuice/purge-game-list-cache
DolphinQt: Implement "Purge Game List Cache"
2018-10-28 17:00:04 +01:00
JosJuice 8bbec31295 DolphinQt: Implement "Purge Game List Cache"
This is a missing feature from DolphinWX.
2018-10-25 08:29:54 +02:00
Stenzek eb284b5d66 VideoBackends: Pass window system info from host on creation 2018-10-20 21:11:34 +10:00
Stenzek a3961750a7 Drop Host_GetRenderSurface and pass display to backend 2018-10-20 21:11:34 +10:00
Stenzek ea77899ddd Qt/MainWindow: Maintain pointer to hotkey window
Prevents multiple hotkey windows from being opened.
2018-10-14 22:24:31 +10:00
Stenzek 211a9bf6d2 Qt/MainWindow: Lazy initialize child windows 2018-10-14 21:46:59 +10:00
Zexaron 550aa93ed0 NetPlay: Properly save Hosting GUI settings 2018-10-13 10:35:42 +02:00
Antonio Maiorano bf18f19b0a Make the progress dialog look better (used for e.g. shader compiling)
* Removed the Cancel button since the code doesn't react to it anyway.
* Only show a window title, not the help icon (?), and disable the close button
* Set the title to "Dolphin" instead of repeating the label text
2018-10-03 21:35:10 -04:00
spycrab 77ebd721e3 Qt: Fix widgets being visible when they shouldn't be 2018-08-20 00:39:57 +02:00
Pierre Bourdon 0fdb6f4267
Merge pull request #7249 from yourWaifu/discord-rpc-join
Add Discord Join Net Play functionally
2018-08-19 13:43:33 +02:00
Sleepy Flower Girl 158c0d54b1 Force IPv4 on external IP addresses 2018-08-13 21:17:38 -04:00
spycrab 9739ad9f48 Qt/TAS: Make TAS input windows independent 2018-08-13 14:15:09 +02:00
Sleepy Flower Girl c2aedb7649 Adds a UI for accepting Discord join requests in Dolphin
also did these things
fixed crash from joining user that isn't hosting via a direct connection
current game stat can now pass to override the current game in config
uses ip endpoint from dolphin.org
2018-08-06 16:12:03 -04:00
Stenzek dca1096664 DolphinQt: Add .dff to open file filter 2018-08-03 17:39:17 +10:00
Sleepy Flower Girl b7c241ea4c Add Discord Join Net Play functionally 2018-07-31 22:24:10 -04:00
spycrab 81c3400681
Merge pull request #7269 from lioncash/qt
DolphinQt/MainWindow: Replace includes with forward declarations
2018-07-30 11:56:31 +02:00
Techjar cfeffdcf42 Fix more segfaults on NetPlay quit
Basically everything here was race conditions in Qt callbacks, so I changed the client/server instances to std::shared_ptr and added null checks. It checks that the object exists in the callback, and the shared_ptr ensures it doesn't get destroyed until we're done with it.

MD5 check would also cause a segfault if you quit without cancelling it first, which was pretty silly.
2018-07-21 00:04:14 -04:00
Techjar 4407854e9c NetPlay save data synchronization
This adds the functionality of sending the host's save data (raw memory
cards, as well as GCI files and Wii saves with a matching GameID) to
all other clients. The data is compressed using LZO1X to greatly reduce
its size while keeping compression/decompression fast. Save
synchronization is enabled by default, and toggleable with a checkbox
in the NetPlay dialog.

On clicking start, if the option is enabled, game boot will be delayed
until all players have received the save data sent by the host. If any
player fails to receive it properly, boot will be cancelled to prevent
desyncs.
2018-07-19 18:09:20 -04:00
Lioncash a9003aadc6
DolphinQt/MainWindow: Replace includes with forward declarations
Reduces the amount of dependencies dragged in by the main window's
header. This also removes MainWindow.h includes elsewhere where they
aren't necessary, reducing the amount of UI files that need to be
recompiled if the main window's header changes.
2018-07-15 18:46:26 -04:00
Lioncash 9b2ffb6221 Qt/GameList: Replace includes with forward declarations where applicable
Avoids dragging in a bunch of includes from the header files, and also
reduces the amount of files that need to be recompiled if one of those
included headers' source content is ever changed.
2018-07-10 16:03:38 -04:00
Mat M 9487892c18
Merge pull request #7226 from lioncash/netplay
Core: Namespace NetPlay utilities under the NetPlay namespace
2018-07-09 00:38:12 -04:00
Michael M e7cbee235c Convert Dolphin.Core.DefaultISO to use new-style config 2018-07-06 19:28:19 -07:00
Lioncash 675260b0f7
Core: Namespace NetPlay utilities under the NetPlay namespace
Previously there was only one function under the NetPlay namespace,
which is kind of silly considering we have all of these other types
and functions existing outside of the namespace.

This moves the rest of them into the namespace.

This gets some general names, like Player, for example, out of the global namespace.
2018-07-06 19:53:23 -04:00
spycrab 13ba24c5a6 Move DolphinQt2 to DolphinQt 2018-07-07 00:48:38 +02:00
Anthony Serna 2ee84a20fe [UI] Remove DolphinQt 2016-01-05 19:42:02 -06:00