mirror of
https://github.com/PabloMK7/citra.git
synced 2025-10-11 20:10:03 +00:00
service/apt: Add and implement more service commands. (#6721)
* service/apt: Add and implement more service commands. * service/apt: Implement power button. * Address review comments and fix GetApplicationRunningMode bug.
This commit is contained in:
parent
51996c54f0
commit
bb364d9bc0
31 changed files with 939 additions and 221 deletions
|
@ -521,6 +521,11 @@ InstallStatus InstallFromNus(u64 title_id, int version) {
|
|||
#endif
|
||||
}
|
||||
|
||||
u64 GetTitleUpdateId(u64 title_id) {
|
||||
// Real services seem to just discard and replace the whole high word.
|
||||
return (title_id & 0xFFFFFFFF) | (static_cast<u64>(TID_HIGH_UPDATE) << 32);
|
||||
}
|
||||
|
||||
Service::FS::MediaType GetTitleMediaType(u64 titleId) {
|
||||
u16 platform = static_cast<u16>(titleId >> 48);
|
||||
u16 category = static_cast<u16>((titleId >> 32) & 0xFFFF);
|
||||
|
|
|
@ -118,6 +118,13 @@ InstallStatus InstallCIA(const std::string& path,
|
|||
*/
|
||||
InstallStatus InstallFromNus(u64 title_id, int version = -1);
|
||||
|
||||
/**
|
||||
* Get the update title ID for a title
|
||||
* @param titleId the title ID
|
||||
* @returns The update title ID
|
||||
*/
|
||||
u64 GetTitleUpdateId(u64 title_id);
|
||||
|
||||
/**
|
||||
* Get the mediatype for an installed title
|
||||
* @param titleId the installed title ID
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue