コード例 #1
0
 void PieChartDisplay::onInitialize()
 {
   static int count = 0;
   rviz::UniformStringStream ss;
   ss << "PieChartDisplayObject" << count++;
   overlay_.reset(new OverlayObject(ss.str()));
   onEnable();
   updateSize();
   updateLeft();
   updateTop();
   updateFGColor();
   updateBGColor();
   updateFGAlpha();
   updateFGAlpha2();
   updateBGAlpha();
   updateMinValue();
   updateMaxValue();
   updateTextColor();
   updateTextAlpha();
   updateTextSize();
   updateShowCaption();
   updateAutoColorChange();
   updateMaxColor();
   overlay_->updateTextureSize(texture_size_, texture_size_ + caption_offset_);
   overlay_->hide();
 }
コード例 #2
0
 void Plotter2DDisplay::onInitialize()
 {
   static int count = 0;
   rviz::UniformStringStream ss;
   ss << "Plotter2DDisplayObject" << count++;
   overlay_.reset(new OverlayObject(ss.str()));
   updateBufferSize();
   onEnable();
   updateShowValue();
   updateWidth();
   updateHeight();
   updateLeft();
   updateTop();
   updateFGColor();
   updateBGColor();
   updateFGAlpha();
   updateBGAlpha();
   updateLineWidth();
   updateUpdateInterval();
   updateShowBorder();
   updateAutoColorChange();
   updateMaxColor();
   updateShowCaption();
   updateTextSize();
   updateAutoScale();
   updateMinValue();
   updateMaxValue();
   overlay_->updateTextureSize(width_property_->getInt(),
                               height_property_->getInt() + caption_offset_);
 }
コード例 #3
0
ファイル: oculus_display.cpp プロジェクト: rahulraw/adVentuRe
void OculusDisplay::reset()
{
  rviz::Display::reset();
  if ( oculus_ )
  {
    onDisable();
    onEnable();
  }
}
コード例 #4
0
void GameObject::enable()
{
	if (!isEnable)
	{
		onAwake();
		onEnable();
	}
	isEnable = true;
	isAwake = true;
}
void InteractiveMarkerDisplay::onInitialize()
{
  tf::Transformer* tf = context_->getFrameManager()->getTFClient();
  im_client_.reset( new interactive_markers::InteractiveMarkerClient( *tf, fixed_frame_.toStdString() ) );

  im_client_->setInitCb( boost::bind( &InteractiveMarkerDisplay::initCb, this, _1 ) );
  im_client_->setUpdateCb( boost::bind( &InteractiveMarkerDisplay::updateCb, this, _1 ) );
  im_client_->setResetCb( boost::bind( &InteractiveMarkerDisplay::resetCb, this, _1 ) );
  im_client_->setStatusCb( boost::bind( &InteractiveMarkerDisplay::statusCb, this, _1, _2, _3 ) );

  client_id_ = ros::this_node::getName() + "/" + getNameStd();

  onEnable();
}
コード例 #6
0
ファイル: Node.cpp プロジェクト: EternalWind/ducttape-engine
void Node::enable() {
    if(mParent == nullptr || mParent->isEnabled()) {
        mIsEnabled = true;
        
        for(auto iter = mChildren.begin(); iter != mChildren.end(); ++iter) {
            iter->second->enable();
        }

        for(auto iter = mComponents.begin(); iter != mComponents.end(); ++iter) {
            iter->second->enable();
        }

        onEnable();
    }
}
コード例 #7
0
ファイル: display.cpp プロジェクト: jonfink/rviz
void Display::enable( bool force )
{
  if ( enabled_ && !force )
  {
    return;
  }

  enabled_ = true;

  if (StatusPropertyPtr status = status_property_.lock())
  {
    status->enable();
  }

  onEnable();

  state_changed_(this);
}
コード例 #8
0
// only the first time
void OverlayTextDisplay::onInitialize()
{
    onEnable();
    updateTopic();
    updateOvertakePositionProperties();
    updateOvertakeColorProperties();
    updateTop();
    updateLeft();
    updateWidth();
    updateHeight();
    updateTextSize();
    updateFGColor();
    updateFGAlpha();
    updateBGColor();
    updateBGAlpha();
    updateFont();
    updateLineWidth();
    require_update_texture_ = true;
}
コード例 #9
0
void
SoXipMenuItemBase::fieldChanged( SoField* whichField )
{
    if( whichField == &focused )
    {
		onFocus();       
    }
    else if( whichField == &enabled )
    {
		onEnable();
    }
	else if( whichField == &caption )
    {
		updateCaption();
    }
	else if( whichField == &icon )
    {
		updateIcon();
    }
}
コード例 #10
0
ファイル: widget.cpp プロジェクト: euphoria64/aseprite
void Widget::setEnabled(bool state)
{
  if (state) {
    if (this->flags & JI_DISABLED) {
      this->flags &= ~JI_DISABLED;
      invalidate();

      onEnable();
    }
  }
  else {
    if (!(this->flags & JI_DISABLED)) {
      getManager()->freeWidget(this); // Free from the manager

      this->flags |= JI_DISABLED;
      invalidate();

      onDisable();
    }
  }
}
コード例 #11
0
ファイル: frame.cpp プロジェクト: yixu34/RefuseRobots
void Frame::enable()
{
	enabled = true;
	enableEvents();
	onEnable();
}