citra_qt: do not pass memory to widget (#6849)
This commit is contained in:
parent
ebac2e4978
commit
aaeba6759e
@ -16,6 +16,7 @@
|
||||
#include "citra_qt/debugger/graphics/graphics_cmdlists.h"
|
||||
#include "citra_qt/util/util.h"
|
||||
#include "common/vector_math.h"
|
||||
#include "core/core.h"
|
||||
#include "core/memory.h"
|
||||
#include "video_core/debug_utils/debug_utils.h"
|
||||
#include "video_core/pica_state.h"
|
||||
@ -166,7 +167,7 @@ void GPUCommandListWidget::SetCommandInfo(const QModelIndex& index) {
|
||||
const auto format = texture.format;
|
||||
|
||||
const auto info = Pica::Texture::TextureInfo::FromPicaRegister(config, format);
|
||||
const u8* src = memory.GetPhysicalPointer(config.GetPhysicalAddress());
|
||||
const u8* src = system.Memory().GetPhysicalPointer(config.GetPhysicalAddress());
|
||||
new_info_widget = new TextureInfoWidget(src, info);
|
||||
}
|
||||
if (command_info_widget) {
|
||||
@ -180,8 +181,8 @@ void GPUCommandListWidget::SetCommandInfo(const QModelIndex& index) {
|
||||
}
|
||||
#undef COMMAND_IN_RANGE
|
||||
|
||||
GPUCommandListWidget::GPUCommandListWidget(Memory::MemorySystem& memory_, QWidget* parent)
|
||||
: QDockWidget(tr("Pica Command List"), parent), memory{memory_} {
|
||||
GPUCommandListWidget::GPUCommandListWidget(Core::System& system_, QWidget* parent)
|
||||
: QDockWidget(tr("Pica Command List"), parent), system{system_} {
|
||||
setObjectName(QStringLiteral("Pica Command List"));
|
||||
GPUCommandListModel* model = new GPUCommandListModel(this);
|
||||
|
||||
|
@ -11,8 +11,8 @@
|
||||
class QPushButton;
|
||||
class QTreeView;
|
||||
|
||||
namespace Memory {
|
||||
class MemorySystem;
|
||||
namespace Core {
|
||||
class System;
|
||||
}
|
||||
|
||||
class GPUCommandListModel : public QAbstractListModel {
|
||||
@ -42,7 +42,7 @@ class GPUCommandListWidget : public QDockWidget {
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
explicit GPUCommandListWidget(Memory::MemorySystem& memory, QWidget* parent = nullptr);
|
||||
explicit GPUCommandListWidget(Core::System& system, QWidget* parent = nullptr);
|
||||
|
||||
public slots:
|
||||
void OnToggleTracing();
|
||||
@ -57,7 +57,7 @@ signals:
|
||||
|
||||
private:
|
||||
std::unique_ptr<Pica::DebugUtils::PicaTrace> pica_trace;
|
||||
Memory::MemorySystem& memory;
|
||||
Core::System& system;
|
||||
QTreeView* list_widget;
|
||||
QWidget* command_info_widget;
|
||||
QPushButton* toggle_tracing;
|
||||
|
@ -448,7 +448,7 @@ void GMainWindow::InitializeDebugWidgets() {
|
||||
graphicsWidget->hide();
|
||||
debug_menu->addAction(graphicsWidget->toggleViewAction());
|
||||
|
||||
graphicsCommandsWidget = new GPUCommandListWidget(system.Memory(), this);
|
||||
graphicsCommandsWidget = new GPUCommandListWidget(system, this);
|
||||
addDockWidget(Qt::RightDockWidgetArea, graphicsCommandsWidget);
|
||||
graphicsCommandsWidget->hide();
|
||||
debug_menu->addAction(graphicsCommandsWidget->toggleViewAction());
|
||||
|
Loading…
Reference in New Issue
Block a user