Commit Graph

255 Commits

Author SHA1 Message Date
Lioncash 794d0a9d7c Core: Move SI source files to their own directory 2017-01-20 19:33:24 -05:00
Léo Lam 49b9c723e2 Put IOS devices in a namespace and drop WII_IPC_HLE prefix 2017-01-18 21:42:33 +01:00
Léo Lam 24199293d3 IOS: Reorganise the source files and IPC_HLE→IOS
IPC_HLE is actually IOS HLE. The actual IPC emulation is not in
IPC_HLE, but in HW/WII_IPC.cpp. So calling IPC_HLE IOS is more
accurate. (If IOS LLE gets ever implemented, it'll likely be at
a lower level -- Starlet LLE.)

This also totally gets rid of the IPC_HLE prefix in file names, and
moves some source files to their own subdirectories to make the file
hierarchy cleaner.

We're going to get ~14 additional source files with the USB PR,
and this is really needed to keep things from becoming a total pain.
2017-01-18 20:43:10 +01:00
Lioncash 722162b54a IPC_HLE: Namespace IOS HLE
Gets all of the IOS HLE code out of the global scope.
2017-01-17 20:46:58 -05:00
Mat M e7359f247b Merge pull request #4595 from aldelaro5/add-debugger-hotkeys
Add debugger hotkeys
2017-01-05 14:33:10 -05:00
PEmu1 2dae72f817 Clarify GameCube Controller in TAS Input 2017-01-03 18:03:17 -08:00
aldelaro5 cc7c410cf1 Add debugging hotkeys
They are separated into 3 groups and will only be shown in the input config dialog if the emulator was in debug mode.
2017-01-02 18:16:52 -05:00
Léo Lam ec729e2ee3 Stop Movie/Netplay before triggering STM shutdown
This fixes a bug which caused Movie (input recording or playback) or
netplay not to be stopped. DolphinWX previously triggered a STM power
event, and then the STM directly stopped the emulation; the code
which stops Movie/Netplay was completely skipped.

This is fixed by moving it /before/ sending the shutdown event.
2016-12-24 00:44:30 +01:00
Anthony ca91b6df52 Merge pull request #4521 from JosJuice/tgc
Add TGC disc image compatibility
2016-12-20 17:45:39 -06:00
Léo Lam adcfefecde DolphinWX: Fix booting from DVD
OnBootDrive used the "drives" member std::vector for drive paths, but
since PR #4363, this vector is not populated anymore, so we were
accessing it out of bounds.

Actually, drives was not needed in the first place, since we can
get the wxMenu from the event, and from there, get the label directly.
2016-12-19 10:45:33 +01:00
JosJuice 9bd514ed1c Add TGC disc image compatibility 2016-12-18 18:57:36 +01:00
Anthony 7a5bb46016 Merge pull request #4030 from clinchergt/fix-setfocus-rendertowindow
Fix focus bug when using the "render to main window" feature
2016-12-09 15:39:31 -06:00
aldelaro5 32a0dae257 Completely redo All configuration dialog
Hotkeys

Make a new class that inherits from InputConfigDialog with a specialised constructor.  The changes are mainly the top portion and it now uses tabs to categorise the hotkeys.

Redo the GCPad configuration dialog

The layout is similar, but it now allows flexibility to change it more easily.

Redo the GC Keyboard configuration dialog

Same layout.

Redo completely the Wiimote configuration dialog

Separated the controls into 2 tabs to make them less imposing overall.

Redo the Nunchuk configuration dialog

Similar layout, except for 2 control group sizers.

Redo the Classic controller configuration dialog

Same layout.

Redo the Guitar input configuration dialog

Stacked 2 sets of group together.

Redo the Turntable configuration dialog

More stacked groups and the window is much less wide.
2016-11-28 08:26:34 -05:00
aldelaro5 00f680b830 Add flexibility to InputConfigDialog
Removed the unecessary forced tabbed layout, removed the layout part of the constructor and remade some method in preparation for tabbed styled input dialog such as the new hotkey configuration one.  It breaks every inputconfigDialog, but this will get fixed in the next commits.

Also moved to a folder since there will be many more files created in the next commits so it gives better separation.
2016-11-28 08:26:27 -05:00
Jules Blok c21efa0cad D3D: Move exclusive mode switching to UI thread.
This prevents deadlocks when switching to exclusive mode.
And it also allows the CPU thread to block until we've completed the switch.
2016-11-11 20:36:04 +01:00
Jules Blok 03878a44e1 Merge pull request #4433 from Armada651/the-emu-that-runs-faster-than-its-race-condition
FrameTools: Avoid deadlock in UpdateGUI().
2016-11-10 16:50:13 +01:00
Lioncash be04215857 FrameTools: Clean up variable naming in UpdateLoadWiiMenuItem 2016-11-08 21:22:17 -05:00
Lioncash 2acf3570e0 PathConfigPane: Eliminate main frame global usage 2016-11-08 21:19:24 -05:00
Jules Blok de50fead5c FrameTools: Avoid deadlock in UpdateGUI(). 2016-11-09 01:45:30 +01:00
Lioncash 5022c0dfb5 DolphinWX: Move common wxUpdateUIEvent functions to WxEventUtils 2016-11-06 09:02:59 -05:00
Lioncash c2d00d25fe DolphinWX: Make the main config dialog modeless 2016-11-06 08:04:54 -05:00
Lioncash 5d4c714662 CodeWindow: Hide GetMenuBar()
This eliminates public usage of the GetMenuBar() function in CodeWindow.
The benefit of this is it also gets rid of the need to perform direct
access across the config dialog and the main frame. It also gets rid of
the use of the main_frame global.

GetMenuBar() will be removed entirely from CodeWindow in a follow-up that
also removes any related remnants of code made obsolete with its removal.
2016-11-04 00:09:47 -04:00
Lioncash 5ae6c21c2e CodeWindow: Eliminate explicit menu item updating from CodeWindow
Gets rid of more menu-related code from CodeWindow and puts it back in
CFrame where it belongs.

This turns the previous menu update function within CodeWindow into one
that simply updates the debugger font for its managed controls. It also
improves how the font is actually updated. Previously, fonts would change,
however this wouldn't actually reflect onto the respective controls until
a refresh or update event occurred. Since codeview, callstack, symbols,
callers, and calls windows are all managed by a wxAuiManager instance,
calling Update() on it after the font has been set will reflect font
changes immediately.
2016-11-04 00:01:45 -04:00
Markus Wick 4f5d0cd450 Merge pull request #4391 from Pringo/wii-remote
Change "Wiimote" to "Wii Remote" in Interface
2016-10-31 12:49:16 +01:00
Mat M 1eed48974d Merge pull request #4380 from lioncash/wx-toolbar
DolphinWX: Move toolbar creation to a wxToolBar subclass
2016-10-29 08:28:27 -04:00
Anthony 41563c55cd Merge pull request #4394 from aldelaro5/fix-focus-detection-linux
Fix window focus detection on Linux (rebase from #3843)
2016-10-29 00:35:18 -05:00
aldelaro5 63546b4f2e Fix unnecessary Center PC calls in the CodeWindow
This not only fixes a regression where toggling a breakpoint using the CodeWindow would cause a Center PC, but it also removes several redundant JumpToAddress(PC) calls.
2016-10-29 01:08:27 -04:00
RenaKunisaki 2005b4430f Fix window focus detection on Linux
On Linux, the FindFocus method from wx simply doesn't work, it would on some environment report that dolphin has the focus while it doesn't have it.  This is why an alternative method has to be used which is to set a focus flag whenever the render frame gets activated.
2016-10-28 18:47:08 -04:00
Lioncash 5e8ccb15ff DolphinWX: Move toolbar creation to a wxToolBar subclass 2016-10-27 21:56:08 -04:00
Pringo 4bd5674b85 Change "Wiimote" to "Wii Remote" in Interface
The usage of "Wii Remote" and "Wiimote" in the interface is inconsistent. "Wiimote" is also not a real word nor is it an official product name. Therefore I have changed instances of "Wiimote" in the UI to instead say "Wii Remote". I also made a couple of minor grammatical changes as well.

This is mostly a resubmission of #4338 but there are some minor other changes as well.
2016-10-25 19:49:41 -07:00
JosJuice a2644cd102 Merge pull request #4363 from lioncash/wx-menu
DolphinWX: Move main menu creation into a wxMenuBar subclass
2016-10-21 21:44:56 +02:00
Lioncash f871b2177e DolphinWX: Move main menu creation into a wxMenuBar subclass
Keeps the actual GUI elements separate from the frame code.
2016-10-20 09:54:29 -04:00
Léo Lam a0a246bf3e Only attempt a graceful shutdown when there's a STM hook
For Wii graceful shutdown to work, the emulated software has to open
the STM event hook and install a hook. Without this, there is no way
to inform them about the shutdown, so trying to do a graceful shutdown
and requiring the use of the shutdown fallback (exiting a second time
to force) is pointless.
2016-10-15 22:28:07 +02:00
Léo Lam 48ff76d495 DolphinWX: Update GUI properly after unpausing
If an unpause was forced by the graceful shutdown code, the UI was
previously not updated.
2016-10-15 21:58:55 +02:00
Lioncash 6a67b571cc DolphinWX: Move creation of debugger menu items into CFrame
Unifies the creation of all the menus into the main frame class.
Now it isn't spread out across the main frame and the code window.

This doesn't alter the placement of the handling functions, as this would
involve unrelated changes, since it would require modifying where
window-related variables are placed. This will be amended in a follow up
changeset.
2016-10-10 19:53:33 -04:00
Lioncash 6420a1c715 Frame: Separate menu creation into individual functions
Keeps related menu items together based on top level menu. This will be
more convenient in the future when debugger menu bar item handling is
moved to CFrame, as it won't be a huge amount of code in one function.

This also makes it easier to locate menu bar code whenever it needs to be
changed.
2016-10-10 16:45:31 -04:00
shuffle2 c8cb1fa7d7 Merge pull request #4319 from leoetlino/sysconf
Don't read/store settings directly from/to SYSCONF (and fix config restore)
2016-10-09 02:34:52 -07:00
anthony b427ead0cc Remove Frameskip 2016-10-08 11:49:51 -05:00
Léo Lam afd2f58e29 Don't read/store settings directly from/to SYSCONF
Instead of directly reading/storing settings from/to the SYSCONF, we
now store Wii settings to Dolphin's own configuration, and apply them
on boot. This prevents issues with settings not being saved, being
overridden and lost (if the user opens a dialog that writes to the
SYSCONF while a game is running).

This also fixes restoring settings from the config cache after a
graceful shutdown; for some reason, settings were only restored
after a normal shutdown.

Fixes issue 9825 and 9826
2016-10-08 14:37:55 +02:00
degasus 0c67297ea0 ConfigManager: Drop SkipIdle option.
This option is safe + deterministic, so let's always enable it.
2016-10-04 08:31:43 +02:00
EmptyChaos 27d295ec7e WX: HiDPI: FrameAUI / Debugger
Changes:
  - MemoryWindow was cleaned up and gives more feedback on searches.

Some bugs were fixed as well:
  - A complex bug that allowed tearing off tabs and opening multiple
    copies of a debug panel which lead to segfaults
  - Another segfault related to right-click menus on code/memory views
    when those tools were floating in their own window.
2016-10-04 13:47:22 +11:00
EmptyChaos 107d4afb08 WX: HiDPI: Dolphin Main UI (CFrame) 2016-10-04 13:47:21 +11:00
Léo Lam 4b47997cf8 Add ability to passthrough a Bluetooth adapter
This adds the ability to passthrough a whole Bluetooth adapter and skip
the majority of the Bluetooth emulation code. We use libusb to send HCI
commands, receive HCI events and transfer ACL data directly to the
first adapter that is found or to a specific adapter (if configured to)

This is possible because the Wii's Bluetooth module is actually just
a pretty standard Bluetooth adapter…

…except for two vendor-specific commands, for which replies are faked,
and also for the sync button. This adds a hotkey that works in the
exact same way as the sync button would on a Wii: it triggers an HCI
event, which emulated software interpret as a command to perform
a BT inquiry.

This commit also changes the UI code to expose passthrough mode
and WII_IPC_HLE to be a bit more thread safe (for the device map).
2016-10-03 23:06:23 +02:00
shuffle2 8107a19ddc Merge pull request #4048 from EmptyChaos/wx-cheat-notice
WX: ISOProperties: Add notice when cheats are disabled (Issue 9690)
2016-10-02 22:06:26 -07:00
shuffle2 5e8bc4aa1d Merge pull request #4244 from leoetlino/stm-shutdown
Shut down Wii software gracefully
2016-10-02 20:25:13 -07:00
shuffle2 8fcc3b04e0 Merge pull request #4227 from ligfx/clean_objc
Don't force compile everything as Objective-C++ on macOS
2016-10-02 19:42:04 -07:00
Léo Lam 9b72b5f144 Shut down Wii software gracefully
This adds support for triggering the power event (in the STM), so that
stopping emulation first triggers a shutdown event, which notably gives
emulated software time to save game data (issue 8979) and clean up
SYSCONF (to disconnect Wiimotes and update their state in the SYSCONF).

On the first press, the stop button/hotkey/whatever will trigger a STM
power event. On a second try, we will forcefully stop emulation, just
like how it was working before.
2016-10-01 13:06:04 +02:00
Stenzek 6a99cbd9fc VideoCommon: Call Renderer::SurfaceChanged on render parent resize
This is needed because for some reason the WSI for NV Vulkan drivers
doesn't return VK_ERROR_OUT_OF_DATE_KHR, so there is no other way to know
that a resize has occured apart from polling, which is a poor solution for
X11 (since it is blocking).
2016-10-01 01:09:12 +10:00
Michael Maltese cd19c9fa22 Don't force compile everything as Objective-C++ on macOS 2016-09-18 17:33:51 -07:00
JosJuice 22b5d89bf1 Merge pull request #4056 from Pringo/master
Update Menu Ellipses Usage
2016-09-16 20:28:51 +02:00