[Android] Unified xenia-app with windowed apps and build prerequisites
This commit is contained in:
@@ -18,7 +18,7 @@ project("xenia-ui-d3d12")
|
||||
group("demos")
|
||||
project("xenia-ui-window-d3d12-demo")
|
||||
uuid("3b9686a7-0f04-4e17-8b00-aeb78ae1107c")
|
||||
kind("WindowedApp")
|
||||
single_library_windowed_app_kind()
|
||||
language("C++")
|
||||
links({
|
||||
"fmt",
|
||||
|
||||
37
src/xenia/ui/file_picker_android.cc
Normal file
37
src/xenia/ui/file_picker_android.cc
Normal file
@@ -0,0 +1,37 @@
|
||||
/**
|
||||
******************************************************************************
|
||||
* Xenia : Xbox 360 Emulator Research Project *
|
||||
******************************************************************************
|
||||
* Copyright 2022 Ben Vanik. All rights reserved. *
|
||||
* Released under the BSD license - see LICENSE in the root for more details. *
|
||||
******************************************************************************
|
||||
*/
|
||||
|
||||
#include <memory>
|
||||
|
||||
#include "xenia/ui/file_picker.h"
|
||||
|
||||
namespace xe {
|
||||
namespace ui {
|
||||
|
||||
// TODO(Triang3l): An asynchronous file picker with a callback, starting an
|
||||
// activity for an ACTION_OPEN_DOCUMENT or an ACTION_OPEN_DOCUMENT_TREE intent.
|
||||
// This intent, however, provides a content URI, not the file path directly.
|
||||
// Accessing the file via the Storage Access Framework doesn't require the
|
||||
// READ_EXTERNAL_STORAGE permission, unlike opening a file by its path directly.
|
||||
// A file descriptor can be opened for the URI using
|
||||
// Context.getContentResolver().openFileDescriptor (it will return a
|
||||
// ParcelFileDescriptor, and a FileDescriptor can be obtained using its
|
||||
// getFileDescriptor() method).
|
||||
|
||||
class AndroidFilePicker : public FilePicker {
|
||||
public:
|
||||
bool Show(Window* parent_window) override { return false; }
|
||||
};
|
||||
|
||||
std::unique_ptr<FilePicker> FilePicker::Create() {
|
||||
return std::make_unique<AndroidFilePicker>();
|
||||
}
|
||||
|
||||
} // namespace ui
|
||||
} // namespace xe
|
||||
@@ -22,7 +22,7 @@ project("xenia-ui-vulkan")
|
||||
group("demos")
|
||||
project("xenia-ui-window-vulkan-demo")
|
||||
uuid("97598f13-3177-454c-8e58-c59e2b6ede27")
|
||||
kind("WindowedApp")
|
||||
single_library_windowed_app_kind()
|
||||
language("C++")
|
||||
links({
|
||||
"fmt",
|
||||
|
||||
Reference in New Issue
Block a user