summaryrefslogtreecommitdiff
path: root/src/gui/render/RenderView.h
blob: 4cf8cf0da00197db5707549870e2052c460128e5 (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
37
38
39
40
41
42
43
44
#ifndef RENDERVIEW_H_
#define RENDERVIEW_H_


#include <vector>
#include "gui/interface/Window.h"
#include "RenderController.h"
#include "RenderModel.h"
#include "graphics/Renderer.h"
#include "gui/interface/Checkbox.h"
#include "gui/interface/Button.h"

class RenderController;
class RenderModel;
class RenderView: public ui::Window {
	RenderController * c;
	Renderer * ren;
	std::vector<ui::Checkbox*> renderModes;
	std::vector<ui::Checkbox*> displayModes;
	std::vector<ui::Checkbox*> colourModes;
	std::string toolTip;
	int toolTipPresence;
	bool isToolTipFadingIn;
	int line1, line2, line3, line4;
public:
	class RenderModeAction;
	class DisplayModeAction;
	class ColourModeAction;
	class RenderPresetAction;
	RenderView();
	void NotifyRendererChanged(RenderModel * sender);
	void NotifyRenderChanged(RenderModel * sender);
	void NotifyDisplayChanged(RenderModel * sender);
	void NotifyColourChanged(RenderModel * sender);
	void AttachController(RenderController * c_) { c = c_; }
	void OnMouseDown(int x, int y, unsigned button);
	virtual void OnDraw();
	virtual void OnTick(float dt);
	virtual void OnKeyPress(int key, Uint16 character, bool shift, bool ctrl, bool alt);
	virtual void ToolTip(ui::Component * sender, ui::Point mousePosition, std::string toolTip);
	virtual ~RenderView();
};

#endif /* RENDERVIEW_H_ */