summaryrefslogtreecommitdiff
path: root/Source/Core/DolphinWX/Debugger/RegisterWindow.cpp
blob: f9ec364204223f1af6e9f7cb8b57d9d5d75194a8 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
// Copyright 2008 Dolphin Emulator Project
// Licensed under GPLv2+
// Refer to the license.txt file included.

#include <cstddef>
#include <wx/panel.h>
#include <wx/sizer.h>

#include "Core/PowerPC/PowerPC.h"
#include "DolphinWX/Debugger/RegisterView.h"
#include "DolphinWX/Debugger/RegisterWindow.h"

CRegisterWindow::CRegisterWindow(wxWindow* parent, wxWindowID id,
		const wxPoint& position, const wxSize& size,
		long style, const wxString& name)
	: wxPanel(parent, id, position, size, style, name)
	, m_GPRGridView(nullptr)
{
	CreateGUIControls();
}

void CRegisterWindow::CreateGUIControls()
{
	wxBoxSizer *sGrid = new wxBoxSizer(wxVERTICAL);
	m_GPRGridView = new CRegisterView(this);
	sGrid->Add(m_GPRGridView, 1, wxGROW);
	SetSizer(sGrid);

	NotifyUpdate();
}

void CRegisterWindow::NotifyUpdate()
{
	if (m_GPRGridView != nullptr)
		m_GPRGridView->Update();
}