diff options
author | krzys-h <krzys_h@interia.pl> | 2014-07-10 16:52:29 +0200 |
---|---|---|
committer | krzys-h <krzys_h@interia.pl> | 2014-07-10 16:52:29 +0200 |
commit | c22e55b99a38d405fb79184106261229bd2d1855 (patch) | |
tree | e2207e5a3a2e9d9f3c247892acd7e9136a060628 /src/object/robotmain.cpp | |
parent | 4c7ff90dcc451a4d231d227ae69efdb0c7e33a1c (diff) | |
download | colobot-c22e55b99a38d405fb79184106261229bd2d1855.tar.gz colobot-c22e55b99a38d405fb79184106261229bd2d1855.tar.bz2 colobot-c22e55b99a38d405fb79184106261229bd2d1855.zip |
Removed some unused code related to Quit button
The button itself has been removed a long time ago
Diffstat (limited to 'src/object/robotmain.cpp')
-rw-r--r-- | src/object/robotmain.cpp | 40 |
1 files changed, 0 insertions, 40 deletions
diff --git a/src/object/robotmain.cpp b/src/object/robotmain.cpp index 76c234d..83b9fc9 100644 --- a/src/object/robotmain.cpp +++ b/src/object/robotmain.cpp @@ -859,8 +859,6 @@ CRobotMain::CRobotMain(CApplication* app, bool loadProfile) CBotProgram::DefineNum("ResearchSubber", RESEARCH_SUBM); CBotProgram::DefineNum("ResearchSniffer", RESEARCH_SNIFFER); -//? CBotProgram:: - CBotProgram::DefineNum("PolskiPortalColobota", 1337); CBotClass* bc; @@ -1215,14 +1213,6 @@ void CRobotMain::ChangePhase(Phase phase) m_app->ResetTimeAfterLoading(); - /*Math::Point ddim; - - pos.x = 620.0f/640.0f; - pos.y = 460.0f/480.0f; - ddim.x = 20.0f/640.0f; - ddim.y = 20.0f/480.0f; - m_interface->CreateButton(pos, ddim, 11, EVENT_BUTTON_QUIT);*/ - if (m_immediatSatCom && !loading && m_infoFilename[SATCOM_HUSTON][0] != 0) StartDisplayInfo(SATCOM_HUSTON, false); // shows the instructions @@ -1638,18 +1628,6 @@ bool CRobotMain::ProcessEvent(Event &event) m_cameraZoom = 0.0f; break; - case EVENT_BUTTON_QUIT: - if (m_movie->IsExist()) - StartDisplayInfo(SATCOM_HUSTON, false); - else if (m_winDelay > 0.0f) - ChangePhase(PHASE_WIN); - else if (m_lostDelay > 0.0f) - - ChangePhase(PHASE_LOST); - else - m_dialog->StartAbort(); // do you want to leave? - break; - case EVENT_OBJECT_LIMIT: StartShowLimit(); break; @@ -2189,12 +2167,6 @@ void CRobotMain::StartDisplayInfo(const char *filename, int index) m_sound->MuteAll(true); } - Ui::CButton* pb = static_cast<Ui::CButton*>(m_interface->SearchControl(EVENT_BUTTON_QUIT)); - if (pb != nullptr) - { - pb->ClearState(Ui::STATE_VISIBLE); - } - bool soluce = m_dialog->GetSceneSoluce(); m_displayInfo = new Ui::CDisplayInfo(); @@ -2223,10 +2195,6 @@ void CRobotMain::StopDisplayInfo() if (!m_editLock) { - Ui::CButton* pb = static_cast<Ui::CButton*>(m_interface->SearchControl(EVENT_BUTTON_QUIT)); - if (pb != nullptr) - pb->SetState(Ui::STATE_VISIBLE); - SelectObject(m_infoObject, false); // gives the command buttons m_displayText->HideText(false); @@ -2264,20 +2232,12 @@ void CRobotMain::StartSuspend() m_infoObject = DeselectAll(); // removes the control buttons m_displayText->HideText(true); - Ui::CButton* pb = static_cast<Ui::CButton*>(m_interface->SearchControl(EVENT_BUTTON_QUIT)); - if (pb != nullptr) - pb->ClearState(Ui::STATE_VISIBLE); - m_suspend = true; } //! End of dialogue during the game void CRobotMain::StopSuspend() { - Ui::CButton* pb = static_cast<Ui::CButton*>(m_interface->SearchControl(EVENT_BUTTON_QUIT)); - if (pb != nullptr) - pb->SetState(Ui::STATE_VISIBLE); - SelectObject(m_infoObject, false); // gives the command buttons m_map->ShowMap(m_mapShow); m_displayText->HideText(false); |