Compare commits
11 Commits
android-82
...
android-83
Author | SHA1 | Date | |
---|---|---|---|
4cc399d120 | |||
75180bdc9d | |||
195d0a93b5 | |||
3491ba4a06 | |||
5326ea63e5 | |||
9335cf8857 | |||
4e855be38b | |||
69ba29e518 | |||
3d03e8b806 | |||
ff9d8dd0b3 | |||
38b939b2e9 |
@ -1,3 +1,11 @@
|
||||
| Pull Request | Commit | Title | Author | Merged? |
|
||||
|----|----|----|----|----|
|
||||
|
||||
|
||||
End of merge log. You can find the original README.md below the break.
|
||||
|
||||
-----
|
||||
|
||||
<!--
|
||||
SPDX-FileCopyrightText: 2018 yuzu Emulator Project
|
||||
SPDX-License-Identifier: GPL-2.0-or-later
|
||||
|
@ -247,7 +247,12 @@ object NativeLibrary {
|
||||
|
||||
external fun setAppDirectory(directory: String)
|
||||
|
||||
external fun installFileToNand(filename: String): Int
|
||||
/**
|
||||
* Installs a nsp or xci file to nand
|
||||
* @param filename String representation of file uri
|
||||
* @param extension Lowercase string representation of file extension without "."
|
||||
*/
|
||||
external fun installFileToNand(filename: String, extension: String): Int
|
||||
|
||||
external fun initializeGpuDriver(
|
||||
hookLibDir: String?,
|
||||
|
@ -181,12 +181,14 @@ class SettingsActivity : AppCompatActivity() {
|
||||
private fun setInsets() {
|
||||
ViewCompat.setOnApplyWindowInsetsListener(
|
||||
binding.navigationBarShade
|
||||
) { view: View, windowInsets: WindowInsetsCompat ->
|
||||
) { _: View, windowInsets: WindowInsetsCompat ->
|
||||
val barInsets = windowInsets.getInsets(WindowInsetsCompat.Type.systemBars())
|
||||
|
||||
val mlpShade = view.layoutParams as MarginLayoutParams
|
||||
mlpShade.height = barInsets.bottom
|
||||
view.layoutParams = mlpShade
|
||||
// The only situation where we care to have a nav bar shade is when it's at the bottom
|
||||
// of the screen where scrolling list elements can go behind it.
|
||||
val mlpNavShade = binding.navigationBarShade.layoutParams as MarginLayoutParams
|
||||
mlpNavShade.height = barInsets.bottom
|
||||
binding.navigationBarShade.layoutParams = mlpNavShade
|
||||
|
||||
windowInsets
|
||||
}
|
||||
|
@ -515,7 +515,7 @@ class MainActivity : AppCompatActivity(), ThemeProvider {
|
||||
if (documents.isNotEmpty()) {
|
||||
IndeterminateProgressDialogFragment.newInstance(
|
||||
this@MainActivity,
|
||||
R.string.install_game_content
|
||||
R.string.installing_game_content
|
||||
) {
|
||||
var installSuccess = 0
|
||||
var installOverwrite = 0
|
||||
@ -523,7 +523,12 @@ class MainActivity : AppCompatActivity(), ThemeProvider {
|
||||
var errorExtension = 0
|
||||
var errorOther = 0
|
||||
documents.forEach {
|
||||
when (NativeLibrary.installFileToNand(it.toString())) {
|
||||
when (
|
||||
NativeLibrary.installFileToNand(
|
||||
it.toString(),
|
||||
FileUtil.getExtension(it)
|
||||
)
|
||||
) {
|
||||
NativeLibrary.InstallFileToNandResult.Success -> {
|
||||
installSuccess += 1
|
||||
}
|
||||
|
@ -102,7 +102,7 @@ public:
|
||||
m_native_window = native_window;
|
||||
}
|
||||
|
||||
int InstallFileToNand(std::string filename) {
|
||||
int InstallFileToNand(std::string filename, std::string file_extension) {
|
||||
jconst copy_func = [](const FileSys::VirtualFile& src, const FileSys::VirtualFile& dest,
|
||||
std::size_t block_size) {
|
||||
if (src == nullptr || dest == nullptr) {
|
||||
@ -134,12 +134,12 @@ public:
|
||||
m_system.GetFileSystemController().CreateFactories(*m_vfs);
|
||||
|
||||
[[maybe_unused]] std::shared_ptr<FileSys::NSP> nsp;
|
||||
if (filename.ends_with("nsp")) {
|
||||
if (file_extension == "nsp") {
|
||||
nsp = std::make_shared<FileSys::NSP>(m_vfs->OpenFile(filename, FileSys::Mode::Read));
|
||||
if (nsp->IsExtractedType()) {
|
||||
return InstallError;
|
||||
}
|
||||
} else if (filename.ends_with("xci")) {
|
||||
} else if (file_extension == "xci") {
|
||||
jconst xci =
|
||||
std::make_shared<FileSys::XCI>(m_vfs->OpenFile(filename, FileSys::Mode::Read));
|
||||
nsp = xci->GetSecurePartitionNSP();
|
||||
@ -607,8 +607,10 @@ void Java_org_yuzu_yuzu_1emu_NativeLibrary_setAppDirectory(JNIEnv* env, jobject
|
||||
}
|
||||
|
||||
int Java_org_yuzu_yuzu_1emu_NativeLibrary_installFileToNand(JNIEnv* env, jobject instance,
|
||||
[[maybe_unused]] jstring j_file) {
|
||||
return EmulationSession::GetInstance().InstallFileToNand(GetJString(env, j_file));
|
||||
jstring j_file,
|
||||
jstring j_file_extension) {
|
||||
return EmulationSession::GetInstance().InstallFileToNand(GetJString(env, j_file),
|
||||
GetJString(env, j_file_extension));
|
||||
}
|
||||
|
||||
void JNICALL Java_org_yuzu_yuzu_1emu_NativeLibrary_initializeGpuDriver(JNIEnv* env, jclass clazz,
|
||||
|
@ -22,7 +22,7 @@
|
||||
|
||||
<View
|
||||
android:id="@+id/navigation_bar_shade"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="1px"
|
||||
android:background="@android:color/transparent"
|
||||
android:clickable="false"
|
||||
|
@ -32,7 +32,8 @@
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center"
|
||||
android:focusable="false">
|
||||
android:focusable="false"
|
||||
android:clickable="false">
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:id="@+id/loading_layout"
|
||||
@ -155,7 +156,7 @@
|
||||
android:id="@+id/in_game_menu"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_gravity="start|bottom"
|
||||
android:layout_gravity="start"
|
||||
app:headerLayout="@layout/header_in_game"
|
||||
app:menu="@menu/menu_in_game"
|
||||
tools:visibility="gone" />
|
||||
|
@ -107,6 +107,7 @@
|
||||
<string name="share_log_missing">No log file found</string>
|
||||
<string name="install_game_content">Install game content</string>
|
||||
<string name="install_game_content_description">Install game updates or DLC</string>
|
||||
<string name="installing_game_content">Installing content…</string>
|
||||
<string name="install_game_content_failure">Error installing file(s) to NAND</string>
|
||||
<string name="install_game_content_failure_description">Please ensure content(s) are valid and that the prod.keys file is installed.</string>
|
||||
<string name="install_game_content_failure_base">Installation of base games isn\'t permitted in order to avoid possible conflicts.</string>
|
||||
|
@ -187,6 +187,8 @@ public:
|
||||
this->SetValue(input == "true");
|
||||
} else if constexpr (std::is_same_v<Type, float>) {
|
||||
this->SetValue(std::stof(input));
|
||||
} else if constexpr (std::is_same_v<Type, AudioEngine>) {
|
||||
this->SetValue(ToEnum<AudioEngine>(input));
|
||||
} else {
|
||||
this->SetValue(static_cast<Type>(std::stoll(input)));
|
||||
}
|
||||
|
Reference in New Issue
Block a user