mirror of
				https://github.com/PabloMK7/citra.git
				synced 2025-10-31 05:40:04 +00:00 
			
		
		
		
	qt: Allow toggling whether to enter system setup on home menu boot. (#6574)
This commit is contained in:
		
							parent
							
								
									691e09473e
								
							
						
					
					
						commit
						4ddb2116bf
					
				
					 5 changed files with 163 additions and 120 deletions
				
			
		|  | @ -898,6 +898,17 @@ void Module::SetEULAVersion(const EULAVersion& version) { | |||
|     SetConfigInfoBlock(EULAVersionBlockID, sizeof(data), 0xE, &data); | ||||
| } | ||||
| 
 | ||||
| void Module::SetSystemSetupNeeded(bool setup_needed) { | ||||
|     u32 block = setup_needed ? 0 : 1; | ||||
|     SetConfigInfoBlock(SystemSetupRequiredBlockID, sizeof(block), 0xC, &block); | ||||
| } | ||||
| 
 | ||||
| bool Module::IsSystemSetupNeeded() { | ||||
|     u32 block; | ||||
|     GetConfigInfoBlock(SystemSetupRequiredBlockID, sizeof(block), 0xC, &block); | ||||
|     return (block & 0xFFFF) == 0; | ||||
| } | ||||
| 
 | ||||
| std::shared_ptr<Module> GetModule(Core::System& system) { | ||||
|     auto cfg = system.ServiceManager().GetService<Service::CFG::Module::Interface>("cfg:u"); | ||||
|     if (!cfg) | ||||
|  |  | |||
|  | @ -460,6 +460,18 @@ public: | |||
|      */ | ||||
|     EULAVersion GetEULAVersion(); | ||||
| 
 | ||||
|     /**
 | ||||
|      * Sets whether system initial setup is needed in config savegame. | ||||
|      * @param setup_needed Whether system initial setup is needed. | ||||
|      */ | ||||
|     void SetSystemSetupNeeded(bool setup_needed); | ||||
| 
 | ||||
|     /**
 | ||||
|      * Gets whether system initial setup is needed from config savegame. | ||||
|      * @returns Whether system initial setup is needed. | ||||
|      */ | ||||
|     bool IsSystemSetupNeeded(); | ||||
| 
 | ||||
|     /**
 | ||||
|      * Writes the config savegame memory buffer to the config savegame file in the filesystem | ||||
|      * @returns ResultCode indicating the result of the operation, 0 on success | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue