mirror of
				https://github.com/PabloMK7/citra.git
				synced 2025-10-30 21:30:04 +00:00 
			
		
		
		
	Add 3GX plugin loader (#6172)
* Initial plugin loader support * More plugin loader progress * Organize code and more plugin features * Fix clang-format * Fix compilation and add android gui * Fix clang-format * Fix macos build * Fix copy-paste bug and clang-format * More merge fixes * Make suggestions * Move global variable to static member * Fix typo * Apply suggestions * Proper initialization order * Allocate plugin memory from SYSTEM instead of APPLICATION * Do not mark free pages as RWX * Fix plugins in old 3DS mode. * Implement KernelSetState and notif 0x203 * Apply changes * Remove unused variable * Fix dynarmic commit * Sublicense files with MIT License * Remove non-ascii characters from license
This commit is contained in:
		
							parent
							
								
									48ee112ceb
								
							
						
					
					
						commit
						016ce6c286
					
				
					 38 changed files with 1911 additions and 42 deletions
				
			
		|  | @ -657,6 +657,8 @@ void Config::ReadSystemValues() { | |||
|         ReadBasicSetting(Settings::values.init_clock); | ||||
|         ReadBasicSetting(Settings::values.init_time); | ||||
|         ReadBasicSetting(Settings::values.init_time_offset); | ||||
|         ReadBasicSetting(Settings::values.plugin_loader_enabled); | ||||
|         ReadBasicSetting(Settings::values.allow_plugin_loader); | ||||
|     } | ||||
| 
 | ||||
|     qt_config->endGroup(); | ||||
|  | @ -1131,6 +1133,8 @@ void Config::SaveSystemValues() { | |||
|         WriteBasicSetting(Settings::values.init_clock); | ||||
|         WriteBasicSetting(Settings::values.init_time); | ||||
|         WriteBasicSetting(Settings::values.init_time_offset); | ||||
|         WriteBasicSetting(Settings::values.plugin_loader_enabled); | ||||
|         WriteBasicSetting(Settings::values.allow_plugin_loader); | ||||
|     } | ||||
| 
 | ||||
|     qt_config->endGroup(); | ||||
|  |  | |||
|  | @ -308,6 +308,8 @@ void ConfigureSystem::SetConfiguration() { | |||
|     ui->clock_display_label->setText( | ||||
|         QStringLiteral("%1%").arg(Settings::values.cpu_clock_percentage.GetValue())); | ||||
|     ui->toggle_new_3ds->setChecked(Settings::values.is_new_3ds.GetValue()); | ||||
|     ui->plugin_loader->setChecked(Settings::values.plugin_loader_enabled.GetValue()); | ||||
|     ui->allow_plugin_loader->setChecked(Settings::values.allow_plugin_loader.GetValue()); | ||||
| } | ||||
| 
 | ||||
| void ConfigureSystem::ReadSystemSettings() { | ||||
|  | @ -411,6 +413,10 @@ void ConfigureSystem::ApplyConfiguration() { | |||
|         } | ||||
| 
 | ||||
|         Settings::values.init_time_offset = time_offset_days + time_offset_time; | ||||
|         Settings::values.is_new_3ds = ui->toggle_new_3ds->isChecked(); | ||||
| 
 | ||||
|         Settings::values.plugin_loader_enabled.SetValue(ui->plugin_loader->isChecked()); | ||||
|         Settings::values.allow_plugin_loader.SetValue(ui->allow_plugin_loader->isChecked()); | ||||
|     } | ||||
| 
 | ||||
|     ConfigurationShared::ApplyPerGameSetting( | ||||
|  | @ -520,6 +526,13 @@ void ConfigureSystem::SetupPerGameUI() { | |||
|     ui->edit_init_time_offset_days->setVisible(false); | ||||
|     ui->edit_init_time_offset_time->setVisible(false); | ||||
|     ui->button_regenerate_console_id->setVisible(false); | ||||
|     // Apps can change the state of the plugin loader, so plugins load
 | ||||
|     // to a chainloaded app with specific parameters. Don't allow
 | ||||
|     // the plugin loader state to be configured per-game as it may
 | ||||
|     // mess things up.
 | ||||
|     ui->label_plugin_loader->setVisible(false); | ||||
|     ui->plugin_loader->setVisible(false); | ||||
|     ui->allow_plugin_loader->setVisible(false); | ||||
| 
 | ||||
|     connect(ui->clock_speed_combo, qOverload<int>(&QComboBox::activated), this, [this](int index) { | ||||
|         ui->slider_clock_speed->setEnabled(index == 1); | ||||
|  |  | |||
|  | @ -340,6 +340,27 @@ | |||
|           </property> | ||||
|          </widget> | ||||
|         </item> | ||||
|         <item row="13" column="0"> | ||||
|           <widget class="QLabel" name="label_plugin_loader"> | ||||
|             <property name="text"> | ||||
|               <string>3GX Plugin Loader:</string> | ||||
|             </property> | ||||
|           </widget> | ||||
|         </item> | ||||
|         <item row="13" column="1"> | ||||
|           <widget class="QCheckBox" name="plugin_loader"> | ||||
|             <property name="text"> | ||||
|               <string>Enable 3GX plugin loader</string> | ||||
|             </property> | ||||
|           </widget> | ||||
|         </item> | ||||
|         <item row="14" column="1"> | ||||
|           <widget class="QCheckBox" name="allow_plugin_loader"> | ||||
|             <property name="text"> | ||||
|               <string>Allow games to change plugin loader state</string> | ||||
|             </property> | ||||
|           </widget> | ||||
|         </item> | ||||
|        </layout> | ||||
|       </widget> | ||||
|      </item> | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue