summaryrefslogtreecommitdiffstatshomepage
path: root/src/emu/ui/datmenu.h
blob: 9df45d5719002d3f952880c7fee581b764f83f8c (plain) (blame)
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
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
// license:BSD-3-Clause
// copyright-holders:Dankan1890
/***************************************************************************

    mewui/datmenu.h

    Internal MEWUI user interface.


***************************************************************************/

#pragma once

#ifndef __MEWUI_DATMENU_H__
#define __MEWUI_DATMENU_H__

struct ui_software_info;

//-------------------------------------------------
//  class dats menu
//-------------------------------------------------

class ui_menu_dats : public ui_menu
{
public:
	ui_menu_dats(running_machine &machine, render_container *container, int _flags, const game_driver *driver = nullptr);
	virtual ~ui_menu_dats();
	virtual void populate() override;
	virtual void handle() override;
	virtual void custom_render(void *selectedref, float top, float bottom, float x, float y, float x2, float y2) override;

private:
	const game_driver  *m_driver;
	int                m_flags;

	bool get_data(const game_driver *driver, int flags);
};

//-------------------------------------------------
//  class command data menu
//-------------------------------------------------

class ui_menu_command : public ui_menu
{
public:
	ui_menu_command(running_machine &machine, render_container *container, const game_driver *driver = nullptr);
	virtual ~ui_menu_command();
	virtual void populate() override;
	virtual void handle() override;
	virtual void custom_render(void *selectedref, float top, float bottom, float x, float y, float x2, float y2) override;

private:
	const game_driver *m_driver;
};

//-------------------------------------------------
//  class command content data menu
//-------------------------------------------------

class ui_menu_command_content : public ui_menu
{
public:
	ui_menu_command_content(running_machine &machine, render_container *container, std::string title, const game_driver *driver = nullptr);
	virtual ~ui_menu_command_content();
	virtual void populate() override;
	virtual void handle() override;
	virtual void custom_render(void *selectedref, float top, float bottom, float x, float y, float x2, float y2) override;

private:
	const game_driver   *m_driver;
	std::string          m_title;
};

//-------------------------------------------------
//  class software history menu
//-------------------------------------------------

class ui_menu_history_sw : public ui_menu
{
public:
	ui_menu_history_sw(running_machine &machine, render_container *container, ui_software_info *swinfo, const game_driver *driver = nullptr);
	ui_menu_history_sw(running_machine &machine, render_container *container, const game_driver *driver = nullptr);
	virtual ~ui_menu_history_sw();
	virtual void populate() override;
	virtual void handle() override;
	virtual void custom_render(void *selectedref, float top, float bottom, float x, float y, float x2, float y2) override;

private:
	std::string m_list, m_short, m_long, m_parent;
	const game_driver *m_driver;
};

#endif  /* __MEWUI_DATMENU_H__ */