summaryrefslogtreecommitdiff
path: root/src/options
diff options
context:
space:
mode:
authorSimon Robertshaw <simon@hardwired.org.uk>2013-03-22 14:14:17 (GMT)
committer Simon Robertshaw <simon@hardwired.org.uk>2013-03-22 14:14:17 (GMT)
commit9abe51526cac2634af0541c3de69834dd30e9f78 (patch)
tree6ae4deadfe00a83094b9d288d8c11d8ce823577a /src/options
parent2c311b9a36a88fadd96f3d39acb1ab2590835d81 (diff)
downloadpowder-9abe51526cac2634af0541c3de69834dd30e9f78.zip
powder-9abe51526cac2634af0541c3de69834dd30e9f78.tar.gz
Move all GUI source files into gui/
Diffstat (limited to 'src/options')
-rw-r--r--src/options/OptionsController.cpp111
-rw-r--r--src/options/OptionsController.h36
-rw-r--r--src/options/OptionsModel.cpp148
-rw-r--r--src/options/OptionsModel.h43
-rw-r--r--src/options/OptionsView.cpp248
-rw-r--r--src/options/OptionsView.h34
6 files changed, 0 insertions, 620 deletions
diff --git a/src/options/OptionsController.cpp b/src/options/OptionsController.cpp
deleted file mode 100644
index 17c42f4..0000000
--- a/src/options/OptionsController.cpp
+++ /dev/null
@@ -1,111 +0,0 @@
-#include "OptionsController.h"
-#include "dialogues/ErrorMessage.h"
-
-OptionsController::OptionsController(GameModel * gModel_, ControllerCallback * callback_):
- callback(callback_),
- gModel(gModel_),
- HasExited(false)
-{
- view = new OptionsView();
- model = new OptionsModel(gModel);
- model->AddObserver(view);
-
- view->AttachController(this);
-
-}
-
-void OptionsController::SetHeatSimulation(bool state)
-{
- model->SetHeatSimulation(state);
-}
-
-void OptionsController::SetAmbientHeatSimulation(bool state)
-{
- model->SetAmbientHeatSimulation(state);
-}
-
-void OptionsController::SetNewtonianGravity(bool state)
-{
- model->SetNewtonianGravity(state);
-}
-
-void OptionsController::SetWaterEqualisation(bool state)
-{
- model->SetWaterEqualisation(state);
-}
-
-void OptionsController::SetGravityMode(int gravityMode)
-{
- model->SetGravityMode(gravityMode);
-}
-
-void OptionsController::SetAirMode(int airMode)
-{
- model->SetAirMode(airMode);
-}
-
-void OptionsController::SetEdgeMode(int airMode)
-{
- model->SetEdgeMode(airMode);
-}
-
-void OptionsController::SetFullscreen(bool fullscreen)
-{
- model->SetFullscreen(fullscreen);
-}
-
-void OptionsController::SetShowAvatars(bool showAvatars)
-{
- model->SetShowAvatars(showAvatars);
-}
-
-void OptionsController::SetScale(bool scale)
-{
- if(scale)
- {
- if(ui::Engine::Ref().GetMaxWidth() >= ui::Engine::Ref().GetWidth() * 2 && ui::Engine::Ref().GetMaxHeight() >= ui::Engine::Ref().GetHeight() * 2)
- model->SetScale(scale);
- else
- {
- new ErrorMessage("Screen resolution error", "Your screen size is too small to use this scale mode.");
- model->SetScale(false);
- }
- }
- else
- model->SetScale(scale);
-
-}
-
-void OptionsController::SetFastQuit(bool fastquit)
-{
- model->SetFastQuit(fastquit);
-}
-
-OptionsView * OptionsController::GetView()
-{
- return view;
-}
-
-void OptionsController::Exit()
-{
- if(ui::Engine::Ref().GetWindow() == view)
- {
- ui::Engine::Ref().CloseWindow();
- }
- if(callback)
- callback->ControllerExit();
- HasExited = true;
-}
-
-
-OptionsController::~OptionsController() {
- if(ui::Engine::Ref().GetWindow() == view)
- {
- ui::Engine::Ref().CloseWindow();
- }
- delete model;
- delete view;
- if(callback)
- delete callback;
-}
-
diff --git a/src/options/OptionsController.h b/src/options/OptionsController.h
deleted file mode 100644
index 481f9d2..0000000
--- a/src/options/OptionsController.h
+++ /dev/null
@@ -1,36 +0,0 @@
-#ifndef OPTIONSCONTROLLER_H_
-#define OPTIONSCONTROLLER_H_
-
-#include "Controller.h"
-#include "simulation/Simulation.h"
-#include "OptionsView.h"
-#include "OptionsModel.h"
-
-class GameModel;
-class OptionsModel;
-class OptionsView;
-class OptionsController {
- GameModel * gModel;
- OptionsView * view;
- OptionsModel * model;
- ControllerCallback * callback;
-public:
- bool HasExited;
- OptionsController(GameModel * gModel_, ControllerCallback * callback_);
- void SetHeatSimulation(bool state);
- void SetAmbientHeatSimulation(bool state);
- void SetNewtonianGravity(bool state);
- void SetWaterEqualisation(bool state);
- void SetGravityMode(int gravityMode);
- void SetAirMode(int airMode);
- void SetEdgeMode(int airMode);
- void SetFullscreen(bool fullscreen);
- void SetScale(bool scale);
- void SetFastQuit(bool fastquit);
- void SetShowAvatars(bool showAvatars);
- void Exit();
- OptionsView * GetView();
- virtual ~OptionsController();
-};
-
-#endif /* OPTIONSCONTROLLER_H_ */
diff --git a/src/options/OptionsModel.cpp b/src/options/OptionsModel.cpp
deleted file mode 100644
index 8ca2a30..0000000
--- a/src/options/OptionsModel.cpp
+++ /dev/null
@@ -1,148 +0,0 @@
-#include "simulation/Air.h"
-#include "game/GameModel.h"
-#include "OptionsModel.h"
-
-OptionsModel::OptionsModel(GameModel * gModel_) {
- gModel = gModel_;
- sim = gModel->GetSimulation();
-}
-
-void OptionsModel::AddObserver(OptionsView* view)
-{
- observers.push_back(view);
- view->NotifySettingsChanged(this);
-}
-
-bool OptionsModel::GetHeatSimulation()
-{
- return sim->legacy_enable?false:true;
-}
-
-void OptionsModel::SetHeatSimulation(bool state)
-{
- sim->legacy_enable = state?0:1;
- notifySettingsChanged();
-}
-
-bool OptionsModel::GetAmbientHeatSimulation()
-{
- return sim->aheat_enable?true:false;
-}
-
-void OptionsModel::SetAmbientHeatSimulation(bool state)
-{
- sim->aheat_enable = state?1:0;
- notifySettingsChanged();
-}
-
-bool OptionsModel::GetNewtonianGravity()
-{
- return sim->grav->ngrav_enable?true:false;
-}
-
-void OptionsModel::SetNewtonianGravity(bool state)
-{
- if(state)
- sim->grav->start_grav_async();
- else
- sim->grav->stop_grav_async();
- notifySettingsChanged();
-}
-
-bool OptionsModel::GetWaterEqualisation()
-{
- return sim->water_equal_test?true:false;
-}
-
-void OptionsModel::SetWaterEqualisation(bool state)
-{
- sim->water_equal_test = state?1:0;
- notifySettingsChanged();
-}
-
-int OptionsModel::GetAirMode()
-{
- return sim->air->airMode;
-}
-void OptionsModel::SetAirMode(int airMode)
-{
- sim->air->airMode = airMode;
- notifySettingsChanged();
-}
-
-int OptionsModel::GetEdgeMode()
-{
- return gModel->GetEdgeMode();
-}
-void OptionsModel::SetEdgeMode(int edgeMode)
-{
- gModel->SetEdgeMode(edgeMode);
- notifySettingsChanged();
-}
-
-int OptionsModel::GetGravityMode()
-{
- return sim->gravityMode;
-}
-void OptionsModel::SetGravityMode(int gravityMode)
-{
- sim->gravityMode = gravityMode;
- notifySettingsChanged();
-}
-
-bool OptionsModel::GetScale()
-{
- return ui::Engine::Ref().GetScale()==2;
-}
-void OptionsModel::SetScale(bool doubleScale)
-{
- ui::Engine::Ref().SetScale(doubleScale?2:1);
- Client::Ref().SetPref("Scale", int(doubleScale?2:1));
- notifySettingsChanged();
-}
-
-
-bool OptionsModel::GetFullscreen()
-{
- return ui::Engine::Ref().GetFullscreen();
-}
-void OptionsModel::SetFullscreen(bool fullscreen)
-{
- ui::Engine::Ref().SetFullscreen(fullscreen);
- Client::Ref().SetPref("Fullscreen", bool(fullscreen));
- notifySettingsChanged();
-}
-
-bool OptionsModel::GetFastQuit()
-{
- return ui::Engine::Ref().GetFastQuit();
-}
-void OptionsModel::SetFastQuit(bool fastquit)
-{
- ui::Engine::Ref().SetFastQuit(fastquit);
- Client::Ref().SetPref("FastQuit", bool(fastquit));
- notifySettingsChanged();
-}
-
-bool OptionsModel::GetShowAvatars()
-{
- return Client::Ref().GetPrefBool("ShowAvatars", true);
-}
-
-void OptionsModel::SetShowAvatars(bool state)
-{
- Client::Ref().SetPref("ShowAvatars", state);
- notifySettingsChanged();
-}
-
-void OptionsModel::notifySettingsChanged()
-{
- for(int i = 0; i < observers.size(); i++)
- {
- observers[i]->NotifySettingsChanged(this);
- }
-}
-
-OptionsModel::~OptionsModel() {
-}
-
diff --git a/src/options/OptionsModel.h b/src/options/OptionsModel.h
deleted file mode 100644
index 1fdf372..0000000
--- a/src/options/OptionsModel.h
+++ /dev/null
@@ -1,43 +0,0 @@
-#ifndef OPTIONSMODEL_H_
-#define OPTIONSMODEL_H_
-#include <vector>
-#include "OptionsView.h"
-#include "simulation/Simulation.h"
-
-class GameModel;
-class Simulation;
-class OptionsView;
-class OptionsModel {
- GameModel * gModel;
- Simulation * sim;
- std::vector<OptionsView*> observers;
- void notifySettingsChanged();
-public:
- OptionsModel(GameModel * gModel);
- void AddObserver(OptionsView* view);
- bool GetHeatSimulation();
- void SetHeatSimulation(bool state);
- bool GetAmbientHeatSimulation();
- void SetAmbientHeatSimulation(bool state);
- bool GetNewtonianGravity();
- void SetNewtonianGravity(bool state);
- bool GetWaterEqualisation();
- void SetWaterEqualisation(bool state);
- bool GetShowAvatars();
- void SetShowAvatars(bool state);
- int GetAirMode();
- void SetAirMode(int airMode);
- int GetEdgeMode();
- void SetEdgeMode(int edgeMode);
- int GetGravityMode();
- void SetGravityMode(int gravityMode);
- bool GetFullscreen();
- void SetFullscreen(bool fullscreen);
- bool GetFastQuit();
- void SetFastQuit(bool fastquit);
- bool GetScale();
- void SetScale(bool scale);
- virtual ~OptionsModel();
-};
-
-#endif /* OPTIONSMODEL_H_ */
diff --git a/src/options/OptionsView.cpp b/src/options/OptionsView.cpp
deleted file mode 100644
index 70aeba5..0000000
--- a/src/options/OptionsView.cpp
+++ /dev/null
@@ -1,248 +0,0 @@
-#include "OptionsView.h"
-#include "Style.h"
-#include "interface/Button.h"
-#include "interface/Label.h"
-#include "interface/DropDown.h"
-
-OptionsView::OptionsView():
- ui::Window(ui::Point(-1, -1), ui::Point(300, 310)){
-
- ui::Label * tempLabel = new ui::Label(ui::Point(4, 5), ui::Point(Size.X-8, 14), "Simulation Options");
- tempLabel->SetTextColour(style::Colour::InformationTitle);
- tempLabel->Appearance.HorizontalAlign = ui::Appearance::AlignLeft; tempLabel->Appearance.VerticalAlign = ui::Appearance::AlignMiddle;
- AddComponent(tempLabel);
-
- class HeatSimulationAction: public ui::CheckboxAction
- {
- OptionsView * v;
- public:
- HeatSimulationAction(OptionsView * v_){ v = v_; }
- virtual void ActionCallback(ui::Checkbox * sender){ v->c->SetHeatSimulation(sender->GetChecked()); }
- };
-
- heatSimulation = new ui::Checkbox(ui::Point(8, 23), ui::Point(Size.X-6, 16), "Heat simulation \bgIntroduced in version 34", "");
- heatSimulation->SetActionCallback(new HeatSimulationAction(this));
- AddComponent(heatSimulation);
- tempLabel = new ui::Label(ui::Point(24, heatSimulation->Position.Y+14), ui::Point(Size.X-28, 16), "\bgCan cause odd behaviour with very old saves");
- tempLabel->Appearance.HorizontalAlign = ui::Appearance::AlignLeft; tempLabel->Appearance.VerticalAlign = ui::Appearance::AlignMiddle;
- AddComponent(tempLabel);
-
- class AmbientHeatSimulationAction: public ui::CheckboxAction
- {
- OptionsView * v;
- public:
- AmbientHeatSimulationAction(OptionsView * v_){ v = v_; }
- virtual void ActionCallback(ui::Checkbox * sender){ v->c->SetAmbientHeatSimulation(sender->GetChecked()); }
- };
-
- ambientHeatSimulation = new ui::Checkbox(ui::Point(8, 53), ui::Point(Size.X-6, 16), "Ambient heat simulation \bgIntroduced in version 50", "");
- ambientHeatSimulation->SetActionCallback(new AmbientHeatSimulationAction(this));
- AddComponent(ambientHeatSimulation);
- tempLabel = new ui::Label(ui::Point(24, ambientHeatSimulation->Position.Y+14), ui::Point(Size.X-28, 16), "\bgCan cause odd behaviour with old saves");
- tempLabel->Appearance.HorizontalAlign = ui::Appearance::AlignLeft; tempLabel->Appearance.VerticalAlign = ui::Appearance::AlignMiddle;
- AddComponent(tempLabel);
-
- class NewtonianGravityAction: public ui::CheckboxAction
- {
- OptionsView * v;
- public:
- NewtonianGravityAction(OptionsView * v_){ v = v_; }
- virtual void ActionCallback(ui::Checkbox * sender){ v->c->SetNewtonianGravity(sender->GetChecked()); }
- };
-
- newtonianGravity = new ui::Checkbox(ui::Point(8, 83), ui::Point(Size.X-6, 16), "Newtonian gravity \bgIntroduced in version 48", "");
- newtonianGravity->SetActionCallback(new NewtonianGravityAction(this));
- AddComponent(newtonianGravity);
- tempLabel = new ui::Label(ui::Point(24, newtonianGravity->Position.Y+14), ui::Point(Size.X-28, 16), "\bgMay cause poor performance on older computers");
- tempLabel->Appearance.HorizontalAlign = ui::Appearance::AlignLeft; tempLabel->Appearance.VerticalAlign = ui::Appearance::AlignMiddle;
- AddComponent(tempLabel);
-
- class WaterEqualisationAction: public ui::CheckboxAction
- {
- OptionsView * v;
- public:
- WaterEqualisationAction(OptionsView * v_){ v = v_; }
- virtual void ActionCallback(ui::Checkbox * sender){ v->c->SetWaterEqualisation(sender->GetChecked()); }
- };
-
- waterEqualisation = new ui::Checkbox(ui::Point(8, 113), ui::Point(Size.X-6, 16), "Water equalisation \bgIntroduced in version 61", "");
- waterEqualisation->SetActionCallback(new WaterEqualisationAction(this));
- AddComponent(waterEqualisation);
- tempLabel = new ui::Label(ui::Point(24, waterEqualisation->Position.Y+14), ui::Point(Size.X-28, 16), "\bgMay cause poor performance with a lot of water");
- tempLabel->Appearance.HorizontalAlign = ui::Appearance::AlignLeft; tempLabel->Appearance.VerticalAlign = ui::Appearance::AlignMiddle;
- AddComponent(tempLabel);
-
- class AirModeChanged: public ui::DropDownAction
- {
- OptionsView * v;
- public:
- AirModeChanged(OptionsView * v): v(v) { }
- virtual void OptionChanged(ui::DropDown * sender, std::pair<std::string, int> option) { v->c->SetAirMode(option.second); }
- };
- airMode = new ui::DropDown(ui::Point(Size.X-88, 146), ui::Point(80, 16));
- AddComponent(airMode);
- airMode->AddOption(std::pair<std::string, int>("On", 0));
- airMode->AddOption(std::pair<std::string, int>("Pressure off", 1));
- airMode->AddOption(std::pair<std::string, int>("Velocity off", 2));
- airMode->AddOption(std::pair<std::string, int>("Off", 3));
- airMode->AddOption(std::pair<std::string, int>("No Update", 4));
- airMode->SetActionCallback(new AirModeChanged(this));
-
- tempLabel = new ui::Label(ui::Point(8, 146), ui::Point(Size.X-96, 16), "Air Simulation Mode");
- tempLabel->Appearance.HorizontalAlign = ui::Appearance::AlignLeft; tempLabel->Appearance.VerticalAlign = ui::Appearance::AlignMiddle;
- AddComponent(tempLabel);
-
- class GravityModeChanged: public ui::DropDownAction
- {
- OptionsView * v;
- public:
- GravityModeChanged(OptionsView * v): v(v) { }
- virtual void OptionChanged(ui::DropDown * sender, std::pair<std::string, int> option) { v->c->SetGravityMode(option.second); }
- };
-
- gravityMode = new ui::DropDown(ui::Point(Size.X-88, 166), ui::Point(80, 16));
- AddComponent(gravityMode);
- gravityMode->AddOption(std::pair<std::string, int>("Vertical", 0));
- gravityMode->AddOption(std::pair<std::string, int>("Off", 1));
- gravityMode->AddOption(std::pair<std::string, int>("Radial", 2));
- gravityMode->SetActionCallback(new GravityModeChanged(this));
-
- tempLabel = new ui::Label(ui::Point(8, 166), ui::Point(Size.X-96, 16), "Gravity Simulation Mode");
- tempLabel->Appearance.HorizontalAlign = ui::Appearance::AlignLeft; tempLabel->Appearance.VerticalAlign = ui::Appearance::AlignMiddle;
- AddComponent(tempLabel);
-
- class EdgeModeChanged: public ui::DropDownAction
- {
- OptionsView * v;
- public:
- EdgeModeChanged(OptionsView * v): v(v) { }
- virtual void OptionChanged(ui::DropDown * sender, std::pair<std::string, int> option) { v->c->SetEdgeMode(option.second); }
- };
-
- edgeMode = new ui::DropDown(ui::Point(Size.X-88, 186), ui::Point(80, 16));
- AddComponent(edgeMode);
- edgeMode->AddOption(std::pair<std::string, int>("Void", 0));
- edgeMode->AddOption(std::pair<std::string, int>("Solid", 1));
- edgeMode->SetActionCallback(new EdgeModeChanged(this));
-
- tempLabel = new ui::Label(ui::Point(8, 186), ui::Point(Size.X-96, 16), "Edge Mode");
- tempLabel->Appearance.HorizontalAlign = ui::Appearance::AlignLeft; tempLabel->Appearance.VerticalAlign = ui::Appearance::AlignMiddle;
- AddComponent(tempLabel);
-
- class ScaleAction: public ui::CheckboxAction
- {
- OptionsView * v;
- public:
- ScaleAction(OptionsView * v_){ v = v_; }
- virtual void ActionCallback(ui::Checkbox * sender){ v->c->SetScale(sender->GetChecked()); }
- };
-
- scale = new ui::Checkbox(ui::Point(8, 210), ui::Point(Size.X-6, 16), "Large screen", "");
- scale->SetActionCallback(new ScaleAction(this));
- tempLabel = new ui::Label(ui::Point(scale->Position.X+Graphics::textwidth(scale->GetText().c_str())+20, scale->Position.Y), ui::Point(Size.X-28, 16), "\bg- Double window size for smaller screen");
- tempLabel->Appearance.HorizontalAlign = ui::Appearance::AlignLeft; tempLabel->Appearance.VerticalAlign = ui::Appearance::AlignMiddle;
- AddComponent(tempLabel);
- AddComponent(scale);
-
-
- class FullscreenAction: public ui::CheckboxAction
- {
- OptionsView * v;
- public:
- FullscreenAction(OptionsView * v_){ v = v_; }
- virtual void ActionCallback(ui::Checkbox * sender){ v->c->SetFullscreen(sender->GetChecked()); }
- };
-
- fullscreen = new ui::Checkbox(ui::Point(8, 230), ui::Point(Size.X-6, 16), "Fullscreen", "");
- fullscreen->SetActionCallback(new FullscreenAction(this));
- tempLabel = new ui::Label(ui::Point(fullscreen->Position.X+Graphics::textwidth(fullscreen->GetText().c_str())+20, fullscreen->Position.Y), ui::Point(Size.X-28, 16), "\bg- Use the entire screen");
- tempLabel->Appearance.HorizontalAlign = ui::Appearance::AlignLeft; tempLabel->Appearance.VerticalAlign = ui::Appearance::AlignMiddle;
- AddComponent(tempLabel);
- AddComponent(fullscreen);
-
-
- class FastQuitAction: public ui::CheckboxAction
- {
- OptionsView * v;
- public:
- FastQuitAction(OptionsView * v_){ v = v_; }
- virtual void ActionCallback(ui::Checkbox * sender){ v->c->SetFastQuit(sender->GetChecked()); }
- };
-
- fastquit = new ui::Checkbox(ui::Point(8, 250), ui::Point(Size.X-6, 16), "Fast Quit", "");
- fastquit->SetActionCallback(new FastQuitAction(this));
- tempLabel = new ui::Label(ui::Point(fastquit->Position.X+Graphics::textwidth(fastquit->GetText().c_str())+20, fastquit->Position.Y), ui::Point(Size.X-28, 16), "\bg- Always exit completely when hitting close");
- tempLabel->Appearance.HorizontalAlign = ui::Appearance::AlignLeft; tempLabel->Appearance.VerticalAlign = ui::Appearance::AlignMiddle;
- AddComponent(tempLabel);
- AddComponent(fastquit);
-
- class ShowAvatarsAction: public ui::CheckboxAction
- {
- OptionsView * v;
- public:
- ShowAvatarsAction(OptionsView * v_){ v = v_; }
- virtual void ActionCallback(ui::Checkbox * sender){ v->c->SetShowAvatars(sender->GetChecked()); }
- };
-
- showAvatars = new ui::Checkbox(ui::Point(8, 270), ui::Point(Size.X-6, 16), "Show Avatars", "");
- showAvatars->SetActionCallback(new ShowAvatarsAction(this));
- tempLabel = new ui::Label(ui::Point(showAvatars->Position.X+Graphics::textwidth(showAvatars->GetText().c_str())+20, showAvatars->Position.Y), ui::Point(Size.X-28, 16), "\bg- Disable if you have a slow connection");
- tempLabel->Appearance.HorizontalAlign = ui::Appearance::AlignLeft; tempLabel->Appearance.VerticalAlign = ui::Appearance::AlignMiddle;
- AddComponent(tempLabel);
- AddComponent(showAvatars);
-
- class CloseAction: public ui::ButtonAction
- {
- public:
- OptionsView * v;
- CloseAction(OptionsView * v_) { v = v_; }
- void ActionCallback(ui::Button * sender)
- {
- v->c->Exit();
- }
- };
-
- ui::Button * tempButton = new ui::Button(ui::Point(0, Size.Y-16), ui::Point(Size.X, 16), "OK");
- tempButton->SetActionCallback(new CloseAction(this));
- AddComponent(tempButton);
- SetCancelButton(tempButton);
- SetOkayButton(tempButton);
-}
-
-void OptionsView::NotifySettingsChanged(OptionsModel * sender)
-{
- heatSimulation->SetChecked(sender->GetHeatSimulation());
- ambientHeatSimulation->SetChecked(sender->GetAmbientHeatSimulation());
- newtonianGravity->SetChecked(sender->GetNewtonianGravity());
- waterEqualisation->SetChecked(sender->GetWaterEqualisation());
- airMode->SetOption(sender->GetAirMode());
- gravityMode->SetOption(sender->GetGravityMode());
- edgeMode->SetOption(sender->GetEdgeMode());
- scale->SetChecked(sender->GetScale());
- fullscreen->SetChecked(sender->GetFullscreen());
- fastquit->SetChecked(sender->GetFastQuit());
- showAvatars->SetChecked(sender->GetShowAvatars());
-}
-
-void OptionsView::AttachController(OptionsController * c_)
-{
- c = c_;
-}
-
-void OptionsView::OnDraw()
-{
- Graphics * g = ui::Engine::Ref().g;
- g->clearrect(Position.X-2, Position.Y-2, Size.X+3, Size.Y+3);
- g->drawrect(Position.X, Position.Y, Size.X, Size.Y, 255, 255, 255, 255);
- g->draw_line(Position.X+1, Position.Y+scale->Position.Y-4, Position.X+Size.X-1, Position.Y+scale->Position.Y-4, 255, 255, 255, 180);
-}
-
-void OptionsView::OnTryExit(ExitMethod method)
-{
- c->Exit();
-}
-
-
-OptionsView::~OptionsView() {
-}
-
diff --git a/src/options/OptionsView.h b/src/options/OptionsView.h
deleted file mode 100644
index 4ee254f..0000000
--- a/src/options/OptionsView.h
+++ /dev/null
@@ -1,34 +0,0 @@
-#ifndef OPTIONSVIEW_H_
-#define OPTIONSVIEW_H_
-
-#include "interface/Window.h"
-#include "OptionsController.h"
-#include "interface/Checkbox.h"
-#include "interface/DropDown.h"
-#include "OptionsModel.h"
-
-class OptionsModel;
-class OptionsController;
-class OptionsView: public ui::Window {
- OptionsController * c;
- ui::Checkbox * heatSimulation;
- ui::Checkbox * ambientHeatSimulation;
- ui::Checkbox * newtonianGravity;
- ui::Checkbox * waterEqualisation;
- ui::DropDown * airMode;
- ui::DropDown * gravityMode;
- ui::DropDown * edgeMode;
- ui::Checkbox * scale;
- ui::Checkbox * fullscreen;
- ui::Checkbox * fastquit;
- ui::Checkbox * showAvatars;
-public:
- OptionsView();
- void NotifySettingsChanged(OptionsModel * sender);
- void AttachController(OptionsController * c_);
- void OnDraw();
- void OnTryExit(ExitMethod method);
- virtual ~OptionsView();
-};
-
-#endif /* OPTIONSVIEW_H_ */