1
0
mirror of https://github.com/RPCS3/rpcs3.git synced 2024-11-22 10:42:36 +01:00

Remove Qt5Network Qt5OpenGL and Qt5QML dependencies

This commit is contained in:
RipleyTom 2020-03-22 00:26:40 +01:00 committed by Ivan
parent 09a8974786
commit af4efafae1
3 changed files with 203 additions and 236 deletions

8
3rdparty/qt5.cmake vendored
View File

@ -1,16 +1,16 @@
add_library(3rdparty_qt5 INTERFACE)
find_package(Qt5 5.14 CONFIG COMPONENTS Widgets Qml Concurrent)
find_package(Qt5 5.14 CONFIG COMPONENTS Widgets Concurrent)
if(WIN32)
find_package(Qt5 5.14 COMPONENTS WinExtras REQUIRED)
target_link_libraries(3rdparty_qt5 INTERFACE Qt5::Widgets Qt5::WinExtras Qt5::Qml Qt5::Concurrent)
target_link_libraries(3rdparty_qt5 INTERFACE Qt5::Widgets Qt5::WinExtras Qt5::Concurrent)
else()
find_package(Qt5 5.14 COMPONENTS DBus Gui)
if(Qt5DBus_FOUND)
target_link_libraries(3rdparty_qt5 INTERFACE Qt5::Widgets Qt5::DBus Qt5::Qml Qt5::Concurrent)
target_link_libraries(3rdparty_qt5 INTERFACE Qt5::Widgets Qt5::DBus Qt5::Concurrent)
target_compile_definitions(3rdparty_qt5 INTERFACE -DHAVE_QTDBUS)
else()
target_link_libraries(3rdparty_qt5 INTERFACE Qt5::Widgets Qt5::Qml Qt5::Concurrent)
target_link_libraries(3rdparty_qt5 INTERFACE Qt5::Widgets Qt5::Concurrent)
endif()
target_include_directories(3rdparty_qt5 INTERFACE ${Qt5Gui_PRIVATE_INCLUDE_DIRS})
endif()

File diff suppressed because it is too large Load Diff

View File

@ -22,7 +22,6 @@
#include <QFontDatabase>
#include <QCompleter>
#include <QMenu>
#include <QJSEngine>
#include <QVBoxLayout>
#include <QTimer>
#include <atomic>
@ -536,41 +535,9 @@ u64 debugger_frame::EvaluateExpression(const QString& expression)
if (!thread) return 0;
// Parse expression
QJSEngine scriptEngine;
scriptEngine.globalObject().setProperty("pc", GetPc());
if (thread->id_type() == 1)
{
auto ppu = static_cast<ppu_thread*>(thread.get());
for (int i = 0; i < 32; ++i)
{
scriptEngine.globalObject().setProperty(QString("r%1hi").arg(i), QJSValue(static_cast<u32>(ppu->gpr[i] >> 32)));
scriptEngine.globalObject().setProperty(QString("r%1").arg(i), QJSValue(static_cast<u32>(ppu->gpr[i])));
}
scriptEngine.globalObject().setProperty("lrhi", QJSValue(static_cast<u32>(ppu->lr >> 32)));
scriptEngine.globalObject().setProperty("lr", QJSValue(static_cast<u32>(ppu->lr)));
scriptEngine.globalObject().setProperty("ctrhi", QJSValue(static_cast<u32>(ppu->ctr >> 32)));
scriptEngine.globalObject().setProperty("ctr", QJSValue(static_cast<u32>(ppu->ctr)));
scriptEngine.globalObject().setProperty("cia", QJSValue(ppu->cia));
}
else
{
auto spu = static_cast<spu_thread*>(thread.get());
for (int i = 0; i < 128; ++i)
{
scriptEngine.globalObject().setProperty(QString("r%1hi").arg(i), QJSValue(spu->gpr[i]._u32[0]));
scriptEngine.globalObject().setProperty(QString("r%1lo").arg(i), QJSValue(spu->gpr[i]._u32[1]));
scriptEngine.globalObject().setProperty(QString("r%1hilo").arg(i), QJSValue(spu->gpr[i]._u32[2]));
scriptEngine.globalObject().setProperty(QString("r%1hihi").arg(i), QJSValue(spu->gpr[i]._u32[3]));
}
}
// Parse expression(or at least used to, was nuked to remove the need for QtJsEngine)
const QString fixed_expression = QRegExp("^[A-Fa-f0-9]+$").exactMatch(expression) ? "0x" + expression : expression;
return static_cast<ulong>(scriptEngine.evaluate(fixed_expression).toNumber());
return static_cast<ulong>(fixed_expression.toULong(nullptr, 0));
}
void debugger_frame::ClearBreakpoints()