// virtual BOOL LLFloaterMove::postBuild() { updateTransparency(TT_ACTIVE); // force using active floater transparency (STORM-730) // Code that implements floater buttons toggling when user moves via keyboard is located in LLAgent::propagate() mForwardButton = getChild<LLJoystickAgentTurn>("forward btn"); mForwardButton->setHeldDownDelay(MOVE_BUTTON_DELAY); mBackwardButton = getChild<LLJoystickAgentTurn>("backward btn"); mBackwardButton->setHeldDownDelay(MOVE_BUTTON_DELAY); mSlideLeftButton = getChild<LLJoystickAgentSlide>("move left btn"); mSlideLeftButton->setHeldDownDelay(MOVE_BUTTON_DELAY); mSlideRightButton = getChild<LLJoystickAgentSlide>("move right btn"); mSlideRightButton->setHeldDownDelay(MOVE_BUTTON_DELAY); mTurnLeftButton = getChild<LLButton>("turn left btn"); mTurnLeftButton->setHeldDownDelay(MOVE_BUTTON_DELAY); mTurnLeftButton->setHeldDownCallback(boost::bind(&LLFloaterMove::turnLeft, this)); mTurnRightButton = getChild<LLButton>("turn right btn"); mTurnRightButton->setHeldDownDelay(MOVE_BUTTON_DELAY); mTurnRightButton->setHeldDownCallback(boost::bind(&LLFloaterMove::turnRight, this)); mMoveUpButton = getChild<LLButton>("move up btn"); mMoveUpButton->setHeldDownDelay(MOVE_BUTTON_DELAY); mMoveUpButton->setHeldDownCallback(boost::bind(&LLFloaterMove::moveUp, this)); mMoveDownButton = getChild<LLButton>("move down btn"); mMoveDownButton->setHeldDownDelay(MOVE_BUTTON_DELAY); mMoveDownButton->setHeldDownCallback(boost::bind(&LLFloaterMove::moveDown, this)); mModeActionsPanel = getChild<LLPanel>("panel_modes"); LLButton* btn; btn = getChild<LLButton>("mode_walk_btn"); btn->setCommitCallback(boost::bind(&LLFloaterMove::onWalkButtonClick, this)); btn = getChild<LLButton>("mode_run_btn"); btn->setCommitCallback(boost::bind(&LLFloaterMove::onRunButtonClick, this)); btn = getChild<LLButton>("mode_fly_btn"); btn->setCommitCallback(boost::bind(&LLFloaterMove::onFlyButtonClick, this)); initModeTooltips(); initModeButtonMap(); initMovementMode(); // LLViewerParcelMgr::getInstance()->addAgentParcelChangedCallback(LLFloaterMove::sUpdateFlyingStatus); // [RLVa:KB] - Checked: 2011-05-27 (RLVa-1.4.0a) | Added: RLVa-1.4.0a LLViewerParcelMgr::getInstance()->addAgentParcelChangedCallback(LLFloaterMove::sUpdateMovementStatus); // [/RLVa:KB] return TRUE; }
// virtual BOOL LLFloaterMove::postBuild() { setIsChrome(TRUE); setTitleVisible(TRUE); // restore title visibility after chrome applying LLDockableFloater::postBuild(); // Code that implements floater buttons toggling when user moves via keyboard is located in LLAgent::propagate() mForwardButton = getChild<LLJoystickAgentTurn>("forward btn"); mForwardButton->setHeldDownDelay(MOVE_BUTTON_DELAY); mBackwardButton = getChild<LLJoystickAgentTurn>("backward btn"); mBackwardButton->setHeldDownDelay(MOVE_BUTTON_DELAY); mSlideLeftButton = getChild<LLJoystickAgentSlide>("move left btn"); mSlideLeftButton->setHeldDownDelay(MOVE_BUTTON_DELAY); mSlideRightButton = getChild<LLJoystickAgentSlide>("move right btn"); mSlideRightButton->setHeldDownDelay(MOVE_BUTTON_DELAY); mTurnLeftButton = getChild<LLButton>("turn left btn"); mTurnLeftButton->setHeldDownDelay(MOVE_BUTTON_DELAY); mTurnLeftButton->setHeldDownCallback(boost::bind(&LLFloaterMove::turnLeft, this)); mTurnRightButton = getChild<LLButton>("turn right btn"); mTurnRightButton->setHeldDownDelay(MOVE_BUTTON_DELAY); mTurnRightButton->setHeldDownCallback(boost::bind(&LLFloaterMove::turnRight, this)); mMoveUpButton = getChild<LLButton>("move up btn"); mMoveUpButton->setHeldDownDelay(MOVE_BUTTON_DELAY); mMoveUpButton->setHeldDownCallback(boost::bind(&LLFloaterMove::moveUp, this)); mMoveDownButton = getChild<LLButton>("move down btn"); mMoveDownButton->setHeldDownDelay(MOVE_BUTTON_DELAY); mMoveDownButton->setHeldDownCallback(boost::bind(&LLFloaterMove::moveDown, this)); mModeActionsPanel = getChild<LLPanel>("panel_modes"); LLButton* btn; btn = getChild<LLButton>("mode_walk_btn"); btn->setCommitCallback(boost::bind(&LLFloaterMove::onWalkButtonClick, this)); btn = getChild<LLButton>("mode_run_btn"); btn->setCommitCallback(boost::bind(&LLFloaterMove::onRunButtonClick, this)); btn = getChild<LLButton>("mode_fly_btn"); btn->setCommitCallback(boost::bind(&LLFloaterMove::onFlyButtonClick, this)); initModeTooltips(); initModeButtonMap(); initMovementMode(); LLViewerParcelMgr::getInstance()->addAgentParcelChangedCallback(LLFloaterMove::sUpdateFlyingStatus); return TRUE; }