PlotAxisConfig& PlotAxisConfig::operator=(const PlotAxisConfig& src) {
  setTitleType(src.titleType_);
  setCustomTitle(src.customTitle_);
  setTitleVisible(src.titleVisible_);
  
  return *this;
}
Example #2
0
// 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;
}
void PlotAxisConfig::read(QDataStream& stream) {
  int titleType;
  QString customTitle;
  bool titleVisible;
  
  stream >> titleType;
  setTitleType(static_cast<TitleType>(titleType));
  stream >> customTitle;
  setCustomTitle(customTitle);
  stream >> titleVisible;
  setTitleVisible(titleVisible);
}
Example #4
0
// virtual
BOOL LLFloaterCamera::postBuild()
{
	setIsChrome(TRUE);
	setTitleVisible(TRUE); // restore title visibility after chrome applying

	mRotate = getChild<LLJoystickCameraRotate>(ORBIT);
	mZoom = getChild<LLPanelCameraZoom>(ZOOM);
	mTrack = getChild<LLJoystickCameraTrack>(PAN);

	assignButton2Mode(CAMERA_CTRL_MODE_MODES,			"avatarview_btn");
	assignButton2Mode(CAMERA_CTRL_MODE_PAN,				"pan_btn");
	assignButton2Mode(CAMERA_CTRL_MODE_PRESETS,		"presets_btn");

	update();

	return LLDockableFloater::postBuild();
}
Example #5
0
// Default constructor
LLFloaterHUD::LLFloaterHUD()
:	LLFloater(std::string("floater_hud")),
	mWebBrowser(0)
{
	// Create floater from its XML definition
	LLUICtrlFactory::getInstance()->buildFloater(this, "floater_hud.xml");
	
	// Don't grab the focus as it will impede performing in-world actions
	// while using the HUD
	setIsChrome(TRUE);

	// Chrome doesn't show the window title by default, but here we
	// want to show it.
	setTitleVisible(true);
	
	// Opaque background since we never get the focus
	setBackgroundOpaque(TRUE);

	// Position floater based on saved location
	LLRect saved_position_rect = gSavedSettings.getRect("FloaterHUDRect2");
	reshape(saved_position_rect.getWidth(), saved_position_rect.getHeight(), FALSE);
	setRect(saved_position_rect);
	
	mWebBrowser = getChild<LLWebBrowserCtrl>("floater_hud_browser" );
	if (mWebBrowser)
	{
		// Open links in internal browser
		mWebBrowser->setOpenInExternalBrowser(false);

		// This is a "chrome" floater, so we don't want anything to
		// take focus (as the user needs to be able to walk with 
		// arrow keys during tutorial).
		mWebBrowser->setTakeFocusOnClick(false);

		std::string language = LLUI::getLanguage();
		std::string base_url = gSavedSettings.getString("TutorialURL");

		std::string url = base_url + language + "/";
		mWebBrowser->navigateTo(url);
	}

	// Remember the one instance
	sInstance = this;
}
// Default constructor
LLFloaterHUD::LLFloaterHUD(const LLSD& key)
:	LLFloater(key),
	mWebBrowser(0)
{
	// do not build the floater if there the url is empty
	if (gSavedSettings.getString("TutorialURL") == "")
	{
		LLNotificationsUtil::add("TutorialNotFound");
		return;
	}
	
	//LLUICtrlFactory::getInstance()->buildFloater(this, "floater_hud.xml");
	
	// Don't grab the focus as it will impede performing in-world actions
	// while using the HUD
	setIsChrome(TRUE);

	// Chrome doesn't show the window title by default, but here we
	// want to show it.
	setTitleVisible(true);
	
	// Opaque background since we never get the focus
	setBackgroundOpaque(TRUE);
}
void PlotAxisConfig::reset() {
  setTitleType(AutoTitle);
  setCustomTitle("Untitled Axis");
  setTitleVisible(true);
}
void PlotAxisConfig::load(QSettings& settings) {
  setTitleType(static_cast<TitleType>(settings.value("title_type",
    AutoTitle).toInt()));
  setCustomTitle(settings.value("custom_title", "Untitled Axis").toString());
  setTitleVisible(settings.value("title_visible", true).toBool());
}