Mercurial > fife-parpg
diff engine/core/gui/console/console.cpp @ 378:64738befdf3b
bringing in the changes from the build_system_rework branch in preparation for the 0.3.0 release. This commit will require the Jan2010 devkit. Clients will also need to be modified to the new way to import fife.
author | vtchill@33b003aa-7bff-0310-803a-e67f0ece8222 |
---|---|
date | Mon, 11 Jan 2010 23:34:52 +0000 |
parents | 756b895e1dab |
children | 16c2b3ee59ce |
line wrap: on
line diff
--- a/engine/core/gui/console/console.cpp Wed Dec 09 17:01:52 2009 +0000 +++ b/engine/core/gui/console/console.cpp Mon Jan 11 23:34:52 2010 +0000 @@ -165,22 +165,21 @@ caption += boost::lexical_cast<std::string>(fps); m_status->setCaption( caption ); } - + void Console::updateAnimation() { - if( m_hiding ) { - setPosition( getX(), getY() - m_animationDelta); - } else { - setPosition( getX(), getY() + m_animationDelta); + if (m_hiding){ + setPosition(getX(), getY() - m_animationDelta); + if (getY() <= m_hiddenPos){ + doHide(); + m_animationTimer.stop(); } - - if( !m_hiding && getY() >= 0 ) { - setPosition( getX(), 0 ); - m_animationTimer.stop(); + }else{ + setPosition(getX(), getY() + m_animationDelta); + if (getY() >= 0){ + setPosition(getX(), 0); + m_animationTimer.stop(); } - if( m_hiding && getY() <= m_hiddenPos ) { - doHide(); - m_animationTimer.stop(); - } + } } void Console::clear() { @@ -246,7 +245,7 @@ FL_WARN(_log, LMsg("ConsoleExecuter not bind, but command received: ") << cmd.c_str()); } } - catch (FIFE::Exception & e) { + catch (const FIFE::Exception & e) { FL_WARN(_log, LMsg("Console caught exception: ") << e.getMessage()); println(e.getMessage()); }