mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-02-12 23:48:58 +01:00
Android: Convert EmulationActivity to Kotlin
This commit is contained in:
parent
252d3f353a
commit
03675f7677
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@ -50,7 +50,7 @@ class RiivolutionBootActivity : AppCompatActivity() {
|
|||||||
binding.textSdRoot.text = getString(R.string.riivolution_sd_root, "$loadPath/Riivolution")
|
binding.textSdRoot.text = getString(R.string.riivolution_sd_root, "$loadPath/Riivolution")
|
||||||
binding.buttonStart.setOnClickListener {
|
binding.buttonStart.setOnClickListener {
|
||||||
if (patches != null) patches!!.saveConfig()
|
if (patches != null) patches!!.saveConfig()
|
||||||
EmulationActivity.launch(this, path, true)
|
EmulationActivity.launch(this, path!!, true)
|
||||||
}
|
}
|
||||||
|
|
||||||
lifecycleScope.launch {
|
lifecycleScope.launch {
|
||||||
|
@ -319,7 +319,8 @@ public final class EmulationFragment extends Fragment implements SurfaceHolder.C
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
if (!EmulationActivity.getHasUserPausedEmulation() && !NativeLibrary.IsShowingAlertMessage())
|
if (!EmulationActivity.Companion.getHasUserPausedEmulation() &&
|
||||||
|
!NativeLibrary.IsShowingAlertMessage())
|
||||||
{
|
{
|
||||||
Log.debug("[EmulationFragment] Resuming emulation.");
|
Log.debug("[EmulationFragment] Resuming emulation.");
|
||||||
NativeLibrary.UnPauseEmulation();
|
NativeLibrary.UnPauseEmulation();
|
||||||
|
@ -196,7 +196,7 @@ public final class MenuFragment extends Fragment implements View.OnClickListener
|
|||||||
|
|
||||||
private void updatePauseUnpauseVisibility()
|
private void updatePauseUnpauseVisibility()
|
||||||
{
|
{
|
||||||
boolean paused = EmulationActivity.getHasUserPausedEmulation();
|
boolean paused = EmulationActivity.Companion.getHasUserPausedEmulation();
|
||||||
|
|
||||||
mBinding.menuUnpauseEmulation.setVisibility(paused ? View.VISIBLE : View.GONE);
|
mBinding.menuUnpauseEmulation.setVisibility(paused ? View.VISIBLE : View.GONE);
|
||||||
mBinding.menuPauseEmulation.setVisibility(paused ? View.GONE : View.VISIBLE);
|
mBinding.menuPauseEmulation.setVisibility(paused ? View.GONE : View.VISIBLE);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user