Commit graph

1606 commits

Author SHA1 Message Date
Lioncash
609cb04f3f acc: Replace profile_manager include with a forward declaration
This is only used in a shared_ptr, so we can forward declare it.
2018-08-20 19:48:57 -04:00
Lioncash
eb88fedc5d acc: Simplify WriteBuffer call within LoadImage()
We have an overload of WriteBuffer that accepts containers that satisfy
the ContiguousContainer concept, which std::array does, so we only need
to pass in the array itself.
2018-08-20 19:48:57 -04:00
Lioncash
f5b132676f acc: Correct IProfile's constructor initializer list order
Arranges them in the order the members would be initialized
2018-08-20 19:48:57 -04:00
Lioncash
0fcdf37917 acc: Remove unused DEFAULT_USER_ID
This is no longer used, so it can be removed.
2018-08-20 19:48:57 -04:00
Lioncash
350f6e0aa4 profile_manager: Use INVALID_UUID in the initializer of last_opened_user
Makes it a little bit more self-documenting.
2018-08-20 19:48:57 -04:00
Lioncash
9d8f19d7bf profile_manager: Remove unnecessary memcpy in GetProfileBaseAndData()
Given the source and destination types are the same std::array type, we
can simply use regular assignment to perform the same behavior.
2018-08-20 19:48:57 -04:00
Lioncash
38cd4e9c61 profile_manager: Use type aliases for username data, profile data, and user arrays
Avoids the need to repeatedly specify the whole array type in multiple
places.
2018-08-20 19:48:57 -04:00
Lioncash
f9a26d468c profile_manager: Take ProfileInfo by const reference where applicable
ProfileInfo is quite a large struct in terms of data, and we don't need
to perform a copy in these instances, so we can just pass constant
references instead.
2018-08-20 19:48:57 -04:00
Lioncash
1277556c69 profile_manager: Make array parameter to CreateNewUser a const reference
This doesn't modify the passed in array, so this can be a const
reference.
2018-08-20 19:48:57 -04:00
Lioncash
dfdf4a46fe profile_manager: Remove unnecessary static
This can just be constexpr like the others
2018-08-20 19:48:57 -04:00
Lioncash
69dd37d874 profile_manager: Simplify UUID's two param constructor, operator==, and operator bool
We can use the constructor initializer list and just compare the
contained u128's together instead of comparing each element
individually. Ditto for comparing against an invalid UUID.
2018-08-20 19:48:57 -04:00
Lioncash
f13a66b963 profile_manager: Move UUID generation function to the cpp file
This avoids needing to dump the contents of <random> into other files
that include the profile manager header.
2018-08-20 19:48:53 -04:00
Lioncash
9e9a4bb3a7 profile_manager: Remove unnecessary std::move in AddToProfiles() and CreateNewUser()
Moving a const reference isn't possible, so this just results in a copy
(and given ProfileInfo is composed of trivial types and aggregates, a
move wouldn't really do anything).
2018-08-20 17:18:31 -04:00
bunnei
185b35bfcd
Merge pull request #1117 from ogniK5377/CheckFreeCommunicationPermission
Added CheckFreeCommunicationPermission
2018-08-20 11:00:26 -04:00
bunnei
943771e703
Merge pull request #1017 from ogniK5377/better-account
New account backend to allow for future extended support
2018-08-20 10:59:15 -04:00
David Marcec
8a88110060 Added CheckFreeCommunicationPermission
This fixes save files not loading in splatoon 2
2018-08-20 18:14:49 +10:00
greggameplayer
2003771789 Implement SetIdleTimeDetectionExtension & GetIdleTimeDetectionExtension (#1059)
* Used by Mario Tennis Aces
2018-08-17 00:23:08 -04:00
greggameplayer
cef35e7c9c
correct coding style 2018-08-16 23:46:06 +02:00
greggameplayer
928e78dced Implement GetDefaultDisplayResolutionChangeEvent
Require by Toki Tori and Toki Tori 2+
2018-08-16 23:25:54 +02:00
bunnei
c594ec3417
Merge pull request #1005 from DarkLordZach/registered-fmt
file_sys: Add support for registration format
2018-08-15 23:11:58 -04:00
bunnei
c00b374e78
Merge pull request #1078 from lioncash/message
lm: Handle threads and modules within the logger
2018-08-15 18:53:47 -04:00
bunnei
cee6a7ab55
Merge pull request #1080 from lioncash/ret
sm/controller: Correct return value of QueryPointerBufferSize
2018-08-15 18:25:05 -04:00
Lioncash
aac5792a2b kernel/server_session: Add IsSession() member function
Allows querying the inverse of IsDomain() to make things more readable.
This will likely also be usable in the event of implementing
ConvertDomainToSession().
2018-08-15 06:50:50 -04:00
Lioncash
5752454629 sm/controller: Correct return value of QueryPointerBufferSize
This should be returning a u16 according to Switch Brew.
2018-08-15 06:16:10 -04:00
Lioncash
b74df62959 lm: Use LOG_DEBUG for printing out trace logs
Using LOG_TRACE here isn't a good idea because LOG_TRACE is only enabled
when yuzu is compiled in debug mode. Debug mode is also quite slow, and
so we're potentially throwing away logging messages that can provide
value when trying to boot games.
2018-08-15 01:07:41 -04:00
Lioncash
e0b0f4eece lm: Handle threads and modules within the logger
The thread field serves to indicate which thread a log is related to and
provides the length of the thread's name, so we can print that out,
ditto for modules.

Now we can know what threads are potentially spawning off logging
messages (for example Lydie & Suelle bounces between MainThread and
LoadingThread when initializing the game).
2018-08-15 01:05:50 -04:00
bunnei
409d2e07c2
Merge pull request #1056 from lioncash/mm
mm_u: Move interface class into the cpp file
2018-08-14 21:47:07 -04:00
bunnei
d1520410a3
Merge pull request #1055 from lioncash/init
audout_u: Correct IAudioOut initializer list order
2018-08-14 08:03:33 -04:00
Lioncash
b6c47b578f mm_u: Forward all old variants of functions to the new ones
Ensures both variants go through the same interface, and while we're at
it, add Finalize to provide the inverse of Initialize for consistency.
2018-08-13 18:59:10 -04:00
Lioncash
9d09d92c56 mm_u: Move implementation class into the cpp file
Now if changes are ever made to the behavior of the class, it doesn't
involve rebuilding everything that includes the mm_u header.
2018-08-13 18:59:07 -04:00
Lioncash
57d007e545 audout_u: Correct IAudioOut initializer list order
Orders elements in the precise order they'll be initialized.
2018-08-13 18:23:59 -04:00
David Marcec
76fad8410d Registered missing channel devices 2018-08-13 14:03:50 +10:00
David Marcec
92492ee23b Added missing channel devices 2018-08-13 14:00:27 +10:00
Lioncash
cf0a7cd1c1 vfs: Make type hierarchy objects classes instead of structs
struct should be used when the data type is very simple or otherwise has
no invariants associated with it. Given these are used to form a
hierarchy, class should be used instead.
2018-08-12 16:55:40 -04:00
bunnei
4cafc24a4e
Merge pull request #1035 from ogniK5377/audio-dev-revision-info
GetAudioDeviceServiceWithRevisionInfo (Used by Bloodstained: Curse of the Moon)
2018-08-12 14:56:11 -04:00
bunnei
68c44ca0ee
Merge pull request #1028 from ogniK5377/aoa
Added GetAudioRendererSampleRate, GetAudioRendererSampleCount & GetAudioRendererMixBufferCount
2018-08-12 13:33:08 -04:00
David Marcec
66f4f86a82 GetAudioDeviceServiceWithRevisionInfo
As we're not handling any anything about the revision data for GetAudioDeviceServiceWithRevisionInfo, it's currently marked as stubbed. However for games this shouldn't affect the result. Proper revision info would be more for homebrew.
2018-08-12 22:47:39 +10:00
Lioncash
63a70c253e hid: disable clang-format around tables
Prevents clang-format from butchering them.
2018-08-12 05:57:33 -04:00
Lioncash
9e74d6238e hid: Stub DisconnectNpad()
This is required by ARMS.
2018-08-12 05:56:28 -04:00
David Marcec
094f6003e0 Pushed the requested sample rate instead of our fixed sample rate 2018-08-12 14:58:36 +10:00
David Marcec
e5ee0afe6f Added GetAudioRendererSampleRate, GetAudioRendererSampleCount & GetAudioRendererMixBufferCount
GetAudioRendererSampleRate is set as a "STUB" as a game could check if the sample rate it sent and the sample rate it wants don't match. Just a thought of something which could happen so keeping it as stub for the mean time
2018-08-12 14:46:12 +10:00
David Marcec
ecfbe7d9c8 Stub UpdateUserPresence
Needed for Retro City Rampage to go in game
2018-08-12 14:00:44 +10:00
Zach Hilman
c0257cf52f filesystem: Add Open and Register functions for BISFactory 2018-08-11 22:50:48 -04:00
bunnei
249341d08f friend: Stub DeclareCloseOnlinePlaySession.
- Used by Splatoon 2.
2018-08-11 21:34:14 -04:00
bunnei
261a4f0311 friend: Fix CreateFriendService to return an IFriendService interface. 2018-08-11 21:29:58 -04:00
David Marcec
10f494eefe Better UUID randomness 2018-08-12 02:31:43 +10:00
David Marcec
448290bee4 Removed un-needed count from ListOpenUsers and ListAllUsers 2018-08-12 02:11:04 +10:00
David Marcec
2592e41301 Added better explanations in the profile manager 2018-08-12 01:51:31 +10:00
David Marcec
0b6f8ba51e Code cleanup for profile manager 2018-08-12 01:34:22 +10:00
David Marcec
d0b2950434 Removed const from ProfileBase Invalidate 2018-08-12 00:41:17 +10:00