mirror of
https://github.com/UpsilonNumworks/Upsilon.git
synced 2026-03-18 21:30:38 +01:00
[ion/3ds] Make simulator work again
This commit is contained in:
@@ -2,11 +2,13 @@
|
||||
ion_src += $(addprefix ion/src/simulator/3ds/, \
|
||||
main.cpp \
|
||||
callback.cpp \
|
||||
clipboard.cpp \
|
||||
display.cpp \
|
||||
framebuffer.cpp \
|
||||
telemetry_init.cpp \
|
||||
keyboard.cpp \
|
||||
events_keyboard.cpp \
|
||||
events.cpp \
|
||||
driver/display.cpp \
|
||||
driver/language.cpp \
|
||||
driver/led.cpp \
|
||||
@@ -22,8 +24,10 @@ sdl_simu_needs_to_be_removed += $(addprefix ion/src/simulator/shared/, \
|
||||
dummy/led.cpp \
|
||||
dummy/usb.cpp \
|
||||
dummy/battery.cpp \
|
||||
clipboard.cpp \
|
||||
display.cpp:-headless \
|
||||
events_keyboard.cpp:-headless \
|
||||
events.cpp \
|
||||
framebuffer_base.cpp \
|
||||
keyboard_sdl.cpp:-headless \
|
||||
main_sdl.cpp:-headless \
|
||||
|
||||
18
ion/src/simulator/3ds/clipboard.cpp
Normal file
18
ion/src/simulator/3ds/clipboard.cpp
Normal file
@@ -0,0 +1,18 @@
|
||||
#include <ion/clipboard.h>
|
||||
#include <ion.h>
|
||||
#include <string.h>
|
||||
|
||||
namespace Ion {
|
||||
namespace Clipboard {
|
||||
|
||||
uint32_t localClipboardVersion;
|
||||
|
||||
void write(const char * text) {
|
||||
}
|
||||
|
||||
const char * read() {
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
@@ -13,7 +13,7 @@ bool Ion::USB::isEnumerated() {
|
||||
void Ion::USB::clearEnumerationInterrupt() {
|
||||
}
|
||||
|
||||
void Ion::USB::DFU() {
|
||||
void Ion::USB::DFU(bool) {
|
||||
}
|
||||
|
||||
void Ion::USB::enable() {
|
||||
|
||||
23
ion/src/simulator/3ds/events.cpp
Normal file
23
ion/src/simulator/3ds/events.cpp
Normal file
@@ -0,0 +1,23 @@
|
||||
#include "events.h"
|
||||
#include <ion/events.h>
|
||||
|
||||
namespace Ion {
|
||||
namespace Events {
|
||||
|
||||
void didPressNewKey() {
|
||||
}
|
||||
|
||||
char * sharedExternalTextBuffer() {
|
||||
static char buffer[sharedExternalTextBufferSize];
|
||||
return buffer;
|
||||
}
|
||||
|
||||
const char * Event::text() const {
|
||||
if (*this == ExternalText) {
|
||||
return const_cast<const char *>(sharedExternalTextBuffer());
|
||||
}
|
||||
return defaultText();
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
24
ion/src/simulator/3ds/events.h
Normal file
24
ion/src/simulator/3ds/events.h
Normal file
@@ -0,0 +1,24 @@
|
||||
#ifndef ION_SIMULATOR_EVENTS_H
|
||||
#define ION_SIMULATOR_EVENTS_H
|
||||
|
||||
#include <ion/events.h>
|
||||
|
||||
namespace Ion {
|
||||
namespace Simulator {
|
||||
namespace Events {
|
||||
|
||||
void dumpEventCount(int i);
|
||||
void logAfter(int numberOfEvents);
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
namespace Events {
|
||||
|
||||
static constexpr int sharedExternalTextBufferSize = 0;
|
||||
char * sharedExternalTextBuffer();
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
Reference in New Issue
Block a user