mirror of
https://github.com/wheremyfoodat/Panda3DS.git
synced 2025-04-19 20:19:13 +12:00
Clear up PR
This commit is contained in:
parent
1a13795d5d
commit
042763a7d8
5 changed files with 14 additions and 111 deletions
|
@ -475,7 +475,7 @@ if(NOT BUILD_HYDRA_CORE)
|
|||
qt_add_resources(AlberCore "app_images"
|
||||
PREFIX "/"
|
||||
FILES
|
||||
docs/img/rsob_icon.png docs/img/rstarstruck_icon.png docs/icon/NewPand.svg
|
||||
docs/img/rsob_icon.png docs/img/rstarstruck_icon.png
|
||||
)
|
||||
else()
|
||||
set(FRONTEND_SOURCE_FILES src/panda_sdl/main.cpp src/panda_sdl/frontend_sdl.cpp src/panda_sdl/mappings.cpp)
|
||||
|
@ -487,9 +487,7 @@ if(NOT BUILD_HYDRA_CORE)
|
|||
elseif(BUILD_HYDRA_CORE)
|
||||
target_compile_definitions(AlberCore PRIVATE PANDA3DS_HYDRA_CORE=1)
|
||||
include_directories(third_party/hydra_core/include)
|
||||
add_library(Alber SHARED src/hydra_core.cpp
|
||||
src/panda_qt/main.cpp
|
||||
)
|
||||
add_library(Alber SHARED src/hydra_core.cpp)
|
||||
target_link_libraries(Alber PUBLIC AlberCore)
|
||||
endif()
|
||||
|
||||
|
|
|
@ -1,81 +0,0 @@
|
|||
<svg width="1000" height="1000" viewBox="0 0 1000 1000" fill="none" xmlns="http://www.w3.org/2000/svg">
|
||||
<g clip-path="url(#clip0_1_2)">
|
||||
<rect x="1000" y="1000" width="1000" height="1000" rx="75" transform="rotate(-180 1000 1000)" fill="url(#paint0_linear_1_2)"/>
|
||||
<rect x="182.077" y="573.388" width="634.936" height="333.265" rx="60" fill="#FF8F8F"/>
|
||||
<rect x="182.077" y="573.388" width="634.936" height="261.927" fill="#FF8F8F"/>
|
||||
<circle cx="245.265" cy="655.94" r="44.843" fill="#EE7F7F"/>
|
||||
<circle cx="244.755" cy="655.43" r="32.1035" fill="#F8F2EF"/>
|
||||
<rect x="206.536" y="771.105" width="26.4981" height="77.4561" rx="4" transform="rotate(-90 206.536 771.105)" fill="#EE7F7F"/>
|
||||
<rect x="232.015" y="719.128" width="26.4981" height="77.4561" rx="4" fill="#EE7F7F"/>
|
||||
<rect x="243.226" y="773.143" width="4.07664" height="16.3065" rx="1" fill="#F8F2EF"/>
|
||||
<rect x="243.226" y="726.262" width="4.07664" height="16.3065" rx="1" fill="#F8F2EF"/>
|
||||
<rect x="213.671" y="759.894" width="4.07664" height="16.3065" rx="1" transform="rotate(-90 213.671 759.894)" fill="#F8F2EF"/>
|
||||
<rect x="260.552" y="759.894" width="4.07664" height="16.3065" rx="1" transform="rotate(-90 260.552 759.894)" fill="#F8F2EF"/>
|
||||
<circle cx="716.626" cy="619.76" r="13.7586" fill="#FAC5C7"/>
|
||||
<circle cx="750.767" cy="656.959" r="16.3065" fill="#F8F2EF"/>
|
||||
<circle cx="750.767" cy="721.166" r="16.3065" fill="#F8F2EF"/>
|
||||
<circle cx="785.419" cy="689.572" r="16.3065" fill="#F8F2EF"/>
|
||||
<circle cx="717.135" cy="689.572" r="16.3065" fill="#F8F2EF"/>
|
||||
<path d="M306.414 592.752H688.599V886.653C688.599 897.699 679.644 906.653 668.599 906.653H326.414C315.368 906.653 306.414 897.699 306.414 886.653V592.752Z" fill="#EE7F7F"/>
|
||||
<rect x="322.721" y="602.944" width="351.61" height="264.981" rx="6" fill="#EE7F7F"/>
|
||||
<rect x="326.797" y="608.039" width="342.438" height="254.79" fill="white"/>
|
||||
<circle cx="716.626" cy="795.055" r="9.68201" fill="#EE7F7F"/>
|
||||
<circle cx="716.626" cy="834.802" r="9.68201" fill="#EE7F7F"/>
|
||||
<rect x="821.089" y="554.024" width="643.089" height="333.265" rx="60" transform="rotate(-180 821.089 554.024)" fill="#F8F2EF"/>
|
||||
<rect x="821.089" y="554.024" width="643.089" height="261.924" transform="rotate(-180 821.089 554.024)" fill="#F8F2EF"/>
|
||||
<rect x="271.763" y="258.468" width="455.564" height="283.326" rx="11" fill="#F1E9E5"/>
|
||||
<rect x="283.992" y="271.717" width="432.124" height="255.809" fill="white"/>
|
||||
<ellipse cx="378.265" cy="369.556" rx="35.161" ry="52.9963" fill="#30212A"/>
|
||||
<ellipse cx="621.844" cy="369.556" rx="35.161" ry="52.9963" fill="#30212A"/>
|
||||
<circle cx="373.169" cy="345.606" r="10.7012" fill="white"/>
|
||||
<circle cx="373.169" cy="345.606" r="10.7012" fill="white"/>
|
||||
<circle cx="615.729" cy="345.606" r="10.7012" fill="white"/>
|
||||
<circle cx="615.729" cy="345.606" r="10.7012" fill="white"/>
|
||||
<path d="M504.987 451.394C501.385 455.83 494.615 455.83 491.013 451.394L470.942 426.673C466.166 420.791 470.352 412 477.929 412H518.071C525.648 412 529.834 420.791 525.058 426.673L504.987 451.394Z" fill="#30212A"/>
|
||||
<path d="M499.035 454.684C499.035 454.684 513.408 526.642 549.896 482.978" stroke="#30212A" stroke-width="5" stroke-linecap="round"/>
|
||||
<path d="M496.777 454.684C496.777 454.684 482.403 526.642 445.916 482.978" stroke="#30212A" stroke-width="5" stroke-linecap="round"/>
|
||||
<circle cx="519.418" cy="237.065" r="6.11495" fill="#5E5757"/>
|
||||
<circle cx="498.526" cy="236.556" r="10.7012" fill="#5E5757"/>
|
||||
<circle cx="498.526" cy="236.556" r="6.62453" fill="#F5F5F5" fill-opacity="0.5"/>
|
||||
<circle cx="346.671" cy="239.613" r="8.66285" fill="#EBDFDA"/>
|
||||
<circle cx="650.38" cy="239.613" r="8.66285" fill="#EBDFDA"/>
|
||||
<circle cx="241.188" cy="372.614" r="4.07664" fill="#5E5757"/>
|
||||
<circle cx="206.536" cy="372.614" r="4.07664" fill="#5E5757"/>
|
||||
<circle cx="223.862" cy="389.939" r="4.07664" fill="#5E5757"/>
|
||||
<circle cx="223.862" cy="372.614" r="4.07664" fill="#5E5757"/>
|
||||
<circle cx="223.862" cy="355.288" r="4.07664" fill="#5E5757"/>
|
||||
<circle cx="788.477" cy="372.614" r="4.07664" fill="#5E5757"/>
|
||||
<circle cx="753.825" cy="372.614" r="4.07664" fill="#5E5757"/>
|
||||
<circle cx="771.151" cy="389.939" r="4.07664" fill="#5E5757"/>
|
||||
<circle cx="771.151" cy="372.614" r="4.07664" fill="#5E5757"/>
|
||||
<circle cx="771.151" cy="355.288" r="4.07664" fill="#5E5757"/>
|
||||
<rect x="764.017" y="251.334" width="14.2682" height="14.2682" rx="2" fill="#EBDFDA"/>
|
||||
<rect x="218.766" y="251.334" width="14.2682" height="14.2682" rx="2" fill="#EBDFDA"/>
|
||||
<rect x="218.766" y="513.257" width="14.2682" height="14.2682" rx="2" fill="#EBDFDA"/>
|
||||
<rect x="764.017" y="513.257" width="14.2682" height="14.2682" rx="2" fill="#EBDFDA"/>
|
||||
<rect x="178" y="549.947" width="67.2645" height="38.7281" rx="12" fill="#EE7F7F"/>
|
||||
<rect x="178" y="544.851" width="67.2645" height="38.7281" rx="12" fill="#FF8F8F"/>
|
||||
<rect x="753.825" y="549.947" width="67.2645" height="38.7281" rx="12" fill="#EE7F7F"/>
|
||||
<rect x="753.825" y="544.851" width="67.2645" height="38.7281" rx="12" fill="#FF8F8F"/>
|
||||
<rect x="758.921" y="592.752" width="517.733" height="42.8047" rx="12" transform="rotate(-180 758.921 592.752)" fill="#F1E9E5"/>
|
||||
<rect x="758.921" y="586.637" width="517.733" height="42.8047" rx="12" transform="rotate(-180 758.921 586.637)" fill="#F8F2EF"/>
|
||||
<rect x="782.362" y="560.139" width="9.17243" height="10.1916" rx="2" fill="#5E5757"/>
|
||||
<rect x="478.652" y="876.078" width="39.7472" height="23.4407" rx="11.5" fill="#EBDFDA"/>
|
||||
<rect x="480.69" y="878.116" width="35.6706" height="19.364" rx="9.68201" fill="white"/>
|
||||
<path d="M493.939 892.385V886.403L498.016 883.212L502.093 886.403V892.385" stroke="#5E5757" stroke-width="5" stroke-linecap="round"/>
|
||||
<path d="M319.462 116.519C375.48 123.556 373.977 225.777 373.977 225.777L259.121 226.363C259.121 226.363 263.445 109.482 319.462 116.519Z" fill="#F8F2EF"/>
|
||||
<path d="M356.556 213.298C348.578 221.257 280.143 219.639 273.638 213.148C267.132 206.658 282.981 131.434 316.947 131.495C350.913 131.556 364.533 205.338 356.556 213.298Z" fill="#30212A"/>
|
||||
<path d="M680.445 119.519C624.427 126.556 625.93 228.777 625.93 228.777L740.786 229.363C740.786 229.363 736.462 112.482 680.445 119.519Z" fill="#F8F2EF"/>
|
||||
<path d="M643.351 216.298C651.329 224.257 719.764 222.639 726.269 216.148C732.775 209.658 716.926 134.434 682.96 134.495C648.994 134.556 635.374 208.338 643.351 216.298Z" fill="#30212A"/>
|
||||
</g>
|
||||
<defs>
|
||||
<linearGradient id="paint0_linear_1_2" x1="1500" y1="1000" x2="1500" y2="2376" gradientUnits="userSpaceOnUse">
|
||||
<stop stop-color="#FFCFB4"/>
|
||||
<stop offset="0.855142" stop-color="#FFCBCE"/>
|
||||
<stop offset="1" stop-color="#FC8D82"/>
|
||||
</linearGradient>
|
||||
<clipPath id="clip0_1_2">
|
||||
<rect width="1000" height="1000" fill="white"/>
|
||||
</clipPath>
|
||||
</defs>
|
||||
</svg>
|
Before Width: | Height: | Size: 6.5 KiB |
|
@ -29,12 +29,11 @@ struct EmulatorConfig {
|
|||
// Default to 3% battery to make users suffer
|
||||
int batteryPercentage = 3;
|
||||
|
||||
std::string romsPath = "";
|
||||
|
||||
// Default ROM path to open in Qt and misc frontends
|
||||
std::filesystem::path defaultRomPath = "";
|
||||
std::filesystem::path filePath;
|
||||
|
||||
EmulatorConfig(const std::filesystem::path& path);
|
||||
void load();
|
||||
void save();
|
||||
std::string getRomsPath();
|
||||
};
|
|
@ -40,7 +40,7 @@ void EmulatorConfig::load() {
|
|||
|
||||
discordRpcEnabled = toml::find_or<toml::boolean>(general, "EnableDiscordRPC", false);
|
||||
usePortableBuild = toml::find_or<toml::boolean>(general, "UsePortableBuild", false);
|
||||
romsPath = toml::find_or(general, "RomsPath","");
|
||||
defaultRomPath = toml::find_or<std::string>(general, "DefaultRomPath", "");
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -121,7 +121,7 @@ void EmulatorConfig::save() {
|
|||
|
||||
data["General"]["EnableDiscordRPC"] = discordRpcEnabled;
|
||||
data["General"]["UsePortableBuild"] = usePortableBuild;
|
||||
data["General"]["RomsPath"] = romsPath;
|
||||
data["General"]["DefaultRomPath"] = defaultRomPath.string();
|
||||
data["GPU"]["EnableShaderJIT"] = shaderJitEnabled;
|
||||
data["GPU"]["Renderer"] = std::string(Renderer::typeToString(rendererType));
|
||||
data["GPU"]["EnableVSync"] = vsyncEnabled;
|
||||
|
@ -137,9 +137,4 @@ void EmulatorConfig::save() {
|
|||
std::ofstream file(path, std::ios::out);
|
||||
file << data;
|
||||
file.close();
|
||||
} std::string EmulatorConfig::getRomsPath() {
|
||||
return EmulatorConfig::romsPath;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
|
|
@ -3,18 +3,15 @@
|
|||
#include <QDesktopServices>
|
||||
#include <QFileDialog>
|
||||
#include <QString>
|
||||
#include <QIcon>
|
||||
#include <cmath>
|
||||
#include <cstdio>
|
||||
#include <fstream>
|
||||
|
||||
|
||||
#include "cheats.hpp"
|
||||
#include "input_mappings.hpp"
|
||||
|
||||
MainWindow::MainWindow(QApplication* app, QWidget* parent) : QMainWindow(parent), keyboardMappings(InputMappings::defaultKeyboardMappings()), screen(this) {
|
||||
setWindowTitle("Panda3DS");
|
||||
setWindowIcon(QIcon(":docs/icon/NewPand.svg"));
|
||||
setWindowTitle("Alber");
|
||||
// Enable drop events for loading ROMs
|
||||
setAcceptDrops(true);
|
||||
resize(800, 240 * 4);
|
||||
|
@ -142,23 +139,18 @@ void MainWindow::swapEmuBuffer() {
|
|||
}
|
||||
|
||||
void MainWindow::selectROM() {
|
||||
if (emu->getConfig().getRomsPath() == "") {
|
||||
auto path =
|
||||
QFileDialog::getOpenFileName(this, tr("Select 3DS ROM to load"),"", tr("Nintendo 3DS ROMs (*.3ds *.cci *.cxi *.app *.3dsx *.elf *.axf)"));
|
||||
} else {
|
||||
QString Rompath = QString::fromStdString(emu->getConfig().getRomsPath());
|
||||
auto path =
|
||||
QFileDialog::getOpenFileName(this, tr("Select 3DS ROM to load"), Rompath, tr("Nintendo 3DS ROMs (*.3ds *.cci *.cxi *.app *.3dsx *.elf *.axf)"));
|
||||
auto path = QFileDialog::getOpenFileName(
|
||||
this, tr("Select 3DS ROM to load"), QString::fromStdU16String(emu->getConfig().defaultRomPath.u16string()),
|
||||
tr("Nintendo 3DS ROMs (*.3ds *.cci *.cxi *.app *.3dsx *.elf *.axf)")
|
||||
);
|
||||
|
||||
if (!path.isEmpty()) {
|
||||
std::filesystem::path* p = new std::filesystem::path(path.toStdU16String());
|
||||
|
||||
EmulatorMessage message{.type = MessageType::LoadROM};
|
||||
message.path.p = p;
|
||||
sendMessage(message);
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
void MainWindow::selectLuaFile() {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue