当前位置: 首页>>代码示例>>C++>>正文


C++ Changed函数代码示例

本文整理汇总了C++中Changed函数的典型用法代码示例。如果您正苦于以下问题:C++ Changed函数的具体用法?C++ Changed怎么用?C++ Changed使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。


在下文中一共展示了Changed函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。

示例1: QDialog

CLayoutWizard::CLayoutWizard(QWidget *parent) :
        QDialog(parent,Qt::Sheet),
    ui(new Ui::CLayoutWizard)
{
    ui->setupUi(this);
    setWindowModality(Qt::WindowModal);
    setVisible(false);
    TitleElement.SetFont(QFont("Times New Roman",24));
    SubtitleElement.SetFont(QFont("Times New Roman",18));
    ComposerElement.SetFont(QFont("Times New Roman",12));
    NamesElement.SetFont(QFont("Times New Roman",8));
    connect(ui->topMargin,SIGNAL(Changed()),this,SLOT(UpdateMargins()));
    connect(ui->leftMargin,SIGNAL(Changed()),this,SLOT(UpdateMargins()));
    connect(ui->rightMargin,SIGNAL(Changed()),this,SLOT(UpdateMargins()));
    connect(ui->bottomMargin,SIGNAL(Changed()),this,SLOT(UpdateMargins()));
    connect(ui->tabWidget,SIGNAL(currentChanged(int)),this,SLOT(UpdateMargins()));
    connect(ui->NoteSpace,SIGNAL(valueChanged(int)),this,SLOT(SpacingTooltip(int)));
    ui->graphicsView->setScene(&S);
    Printer=new QPrinter();
    pageSetupButton=new QToolButton(ui->graphicsView);
    pageSetupButton->setProperty("transparent",true);
    pageSetupButton->setIcon(QIcon(":/preferences.png"));
    pageSetupButton->setIconSize(QSize(32,32));
    pageSetupButton->setFixedSize(QSize(36,36));
    connect(pageSetupButton,SIGNAL(clicked()),this,SLOT(ShowPageSetup()));
    UpdateMargins();
}
开发者ID:vemod-,项目名称:ObjectComposerXML,代码行数:27,代码来源:clayoutwizard.cpp

示例2: MouseMove

    void MouseMove(IInputProvider* pprovider, const Point& point, bool bCaptured, bool bInside)
    {
        if (bCaptured)
        {
            ZAssert(m_bDragging && m_bCanDrag);

            float fScale = (m_xMax - m_xMin)/m_rectMap.XSize();

            float fDeltaX = fScale * (m_pointLastDrag.X() - point.X());
            float fDeltaY = fScale * (m_pointLastDrag.Y() - point.Y());

            // make sure we don't drag the map off of the screen
            m_xDrag = max(min((m_xClusterMax - m_xClusterMin) - (m_xMax - m_xMin), m_xDrag + fDeltaX), 0);
            m_yDrag = max(min((m_yClusterMax - m_yClusterMin) - (m_yMax - m_yMin), m_yDrag + fDeltaY), 0);

            m_pointLastDrag = point;
            GetWindow()->SetCursor(AWF_CURSOR_DRAG);
            Changed();
        }
        else
        {
 
            if (m_bCanDrag)
            {
                GetWindow()->SetCursor(AWF_CURSOR_DRAG);
            }
            else
            {
                GetWindow()->SetCursor(AWF_CURSOR_DEFAULT);
            }
        }

        Changed();
    }
开发者ID:borgified,项目名称:Allegiance,代码行数:34,代码来源:mappreview.cpp

示例3: disconnect

void ResourceWizard::on_StartStringBuilder_clicked()
{
    disconnect(StringBuilder,SIGNAL(Changed(QString)),this,SLOT(SetRandomStringEdit(QString)));
    connect(StringBuilder,SIGNAL(Changed(QString)),this,SLOT(SetRandomStringEdit(QString)));

    StringBuilder->Show(ui->RandomStringValue->text());
    disconnect(StringBuilder,SIGNAL(Changed(QString)),this,SLOT(SetRandomStringEdit(QString)));
}
开发者ID:bablosoft,项目名称:BAS,代码行数:8,代码来源:resourcewizard.cpp

示例4: QMainWindow

MainWindow::MainWindow(Scene *scene, QWidget *parent) :
  QMainWindow(parent),
  ui_(new Ui::MainWindow),
  scene_(scene)
{
  ui_->setupUi(this);

  gl_widget_ = new GLWidget(scene_);
  ui_->opengl_box->layout()->addWidget(gl_widget_);
  //  connect(gl_widget_,SIGNAL(Changed()),this,SLOT(SceneChanged()));

  outer_view_widget_ = new OuterViewWidget(scene_);
  ui_->outerview_box->layout()->addWidget(outer_view_widget_);
  connect(outer_view_widget_,SIGNAL(Changed()),this,SLOT(SceneChanged()));

  ray_tracing_widget_ = new RayTracingWidget(scene_);
  ui_->raytracing_box->layout()->addWidget(ray_tracing_widget_);
  connect(ray_tracing_widget_,SIGNAL(Changed()),this,SLOT(SceneChanged()));
  connect(ui_->recursion_spinBox,SIGNAL(valueChanged(int)),ray_tracing_widget_,SLOT(RayTracingLevel(int)));

  const int default_fov_slider = ((100*(kDefaultFov-kMinFov))/(kMaxFov-kMinFov));
  ui_->fov_slider->setValue(default_fov_slider);
  const int default_near_slider = ((100*(kDefaultNear-kMinNear))/(kMaxNear-kMinNear));
  ui_->near_slider->setValue(default_near_slider);
  const int default_far_slider = ((100*(kDefaultFar-kMinFar))/(kMaxFar-kMinFar));
  ui_->far_slider->setValue(default_far_slider);

  connect(ui_->fov_slider,SIGNAL(valueChanged(int)),this,SLOT(SetFov(int)));
  connect(ui_->near_slider,SIGNAL(valueChanged(int)),this,SLOT(SetNear(int)));
  connect(ui_->far_slider,SIGNAL(valueChanged(int)),this,SLOT(SetFar(int)));
  connect(ui_->light_check,SIGNAL(toggled(bool)),this,SLOT(SetLight(bool)));
  connect(ui_->track_ray_check,SIGNAL(toggled(bool)),this,SLOT(SetTrackRay(bool)));
  SetTrackRay(ui_->track_ray_check->isChecked());
  connect(ui_->fast_render_check,SIGNAL(toggled(bool)),ray_tracing_widget_,SLOT(ToggleFastRenderOnly(bool)));
  ray_tracing_widget_->ToggleFastRenderOnly(ui_->fast_render_check->isChecked());
  //  connect(ui_->image_size_comboBox,SIGNAL(currentIndexChanged(int)),ray_tracing_widget_,SLOT(SelectImageSize(int)));
  //  ray_tracing_widget_->SelectImageSize(ui_->image_size_comboBox->currentIndex());

  connect(ui_->scene_comboBox,SIGNAL(currentIndexChanged(int)),this,SLOT(LoadScene(int)));
      //  connect(ui_->load1_pushButton,SIGNAL(clicked()),this,SLOT(LoadScene1()));
      //  connect(ui_->load2_pushButton_2,SIGNAL(clicked()),this,SLOT(LoadScene2()));

      //  connect(gl_widget_,SIGNAL(Moving(bool)),ray_tracing_widget_,SLOT(SetMoving(bool)));

      connect(gl_widget_,SIGNAL(MouseMoved(QMouseEvent*)),ray_tracing_widget_,SLOT(MouseMoved(QMouseEvent*)));
  connect(gl_widget_,SIGNAL(MousePressed(QMouseEvent*)),ray_tracing_widget_,SLOT(MousePressed(QMouseEvent*)));
  connect(gl_widget_,SIGNAL(MouseReleased(QMouseEvent*)),ray_tracing_widget_,SLOT(MouseReleased(QMouseEvent*)));
  connect(gl_widget_,SIGNAL(Wheel(QWheelEvent*)),ray_tracing_widget_,SLOT(Wheel(QWheelEvent*)));

  connect(ui_->render_button,SIGNAL(clicked()),this,SLOT(FinalRender()));

  SceneChanged();
}
开发者ID:QtOpenGL,项目名称:bustamanprojects,代码行数:53,代码来源:mainwindow.cpp

示例5: Guard

void TConfiguration::Default()
{
  TGuard Guard(FCriticalSection);

  FDisablePasswordStoring = false;
  FForceBanners = false;
  FDisableAcceptingHostKeys = false;

  std::unique_ptr<TRegistryStorage> AdminStorage(new TRegistryStorage(GetRegistryStorageKey(), HKEY_LOCAL_MACHINE));
  try__finally
  {
    if (AdminStorage->OpenRootKey(false))
    {
      LoadAdmin(AdminStorage.get());
      AdminStorage->CloseSubKey();
    }
  }
  __finally
  {
//    delete AdminStorage;
  };

  SetRandomSeedFile(FDefaultRandomSeedFile);
  SetPuttyRegistryStorageKey(OriginalPuttyRegistryStorageKey);
  FConfirmOverwriting = true;
  FConfirmResume = true;
  FAutoReadDirectoryAfterOp = true;
  FSessionReopenAuto = 5000;
  FSessionReopenBackground = 2000;
  FSessionReopenTimeout = 0;
  FSessionReopenAutoStall = 60000;
  FTunnelLocalPortNumberLow = 50000;
  FTunnelLocalPortNumberHigh = 50099;
  FCacheDirectoryChangesMaxSize = 100;
  FShowFtpWelcomeMessage = false;
  FExternalIpAddress.Clear();
  FTryFtpWhenSshFails = true;
  SetCollectUsage(FDefaultCollectUsage);
  FSessionReopenAutoMaximumNumberOfRetries = CONST_DEFAULT_NUMBER_OF_RETRIES;
  FDefaultCollectUsage = false;

  FLogging = false;
  FPermanentLogging = false;
  FLogFileName = GetDefaultLogFileName();
  FPermanentLogFileName = FLogFileName;
  FLogFileAppend = true;
  FLogSensitive = false;
  FPermanentLogSensitive = FLogSensitive;
  FLogWindowLines = 100;
  FLogProtocol = 0;
  FPermanentLogProtocol = FLogProtocol;
  UpdateActualLogProtocol();
  FLogActions = false;
  FPermanentLogActions = false;
  FActionsLogFileName = "%TEMP%" WGOOD_SLASH "&S.xml";
  FPermanentActionsLogFileName = FActionsLogFileName;
  FProgramIniPathWrittable = -1;

  Changed();
}
开发者ID:elfmz,项目名称:far2l,代码行数:60,代码来源:Configuration.cpp

示例6: CudaSafeCall

void TransferFunction::onColorTFChanged()
{
    //std::cout<<"Color changed"<<std::endl;
    if(compositeTex)
    {
        CudaSafeCall(cudaDestroyTextureObject(compositeTex));
        compositeTex = 0;
    }

    colorTF->GetTable(0.0, 1.0, TABLE_SIZE, colorTable);
    size_t j = 0, k = 0;
    for(size_t i = 0; i < TABLE_SIZE; ++i)
    {
        compositeTable[j++] = colorTable[k++];
        compositeTable[j++] = colorTable[k++];
        compositeTable[j++] = colorTable[k++];
        j++;
    }
    //CompositeTable();

    CudaSafeCall(cudaMemcpyToArray(array, 0, 0, compositeTable, sizeof(float) * TABLE_SIZE * 4, cudaMemcpyHostToDevice));
    CudaSafeCall(cudaCreateTextureObject(&compositeTex, &resourceDesc, &texDesc, NULL));

    Changed();
}
开发者ID:sunwj,项目名称:SunVRVR,代码行数:25,代码来源:transferfunction.cpp

示例7: blockSignals

QTransferFunction& QTransferFunction::operator = (const QTransferFunction& Other)			
{
	QPresetXML::operator=(Other);

	blockSignals(true);
	
	m_Nodes			= Other.m_Nodes;
	m_pSelectedNode	= Other.m_pSelectedNode;

	// Notify us when the nodes change
	for (int i = 0; i < m_Nodes.size(); i++)
		connect(&m_Nodes[i], SIGNAL(NodeChanged(QNode*)), this, SLOT(OnNodeChanged(QNode*)));

	m_DensityScale		= Other.m_DensityScale;
	m_ShadingType		= Other.m_ShadingType;
	m_GradientFactor	= Other.m_GradientFactor;

	// Update node's range
	UpdateNodeRanges();

	blockSignals(false);

	// Notify others that the function has changed selection has changed
	emit Changed();

	SetSelectedNode(NULL);

	return *this;
}
开发者ID:ChuckDanglars,项目名称:exposure-render.release110,代码行数:29,代码来源:TransferFunction.cpp

示例8: disconnect

void QTransferFunction::RemoveNode(QNode* pNode)
{
	if (!pNode)
		return;

	// Remove the connection
	disconnect(pNode, SIGNAL(NodeChanged(QNode*)), this, SLOT(OnNodeChanged(QNode*)));

	// Node index of the to be removed node
	int NodeIndex = m_Nodes.indexOf(*pNode);

	// Remove from list and memory
	m_Nodes.remove(*pNode);

	// Update ID's
	for (int i = 0; i < m_Nodes.size(); i++)
		m_Nodes[i].m_ID = i;

	// Update node's range
	UpdateNodeRanges();

	// Select the previous node
	NodeIndex = qMax(0, NodeIndex - 1);

	SetSelectedNode(NodeIndex);

	// Inform others that the transfer function has changed
	emit Changed();

	Log("Removed node", "layer-select-point");
}
开发者ID:ChuckDanglars,项目名称:exposure-render.release110,代码行数:31,代码来源:TransferFunction.cpp

示例9: if

bool nuiTreeBase::SetChild(uint32 Index, nuiTreePtr pChild)
{
  pChild->Acquire();
  if (mpChildren.size() < Index+1)
    mpChildren.resize(Index+1);
  if (mpChildren[Index])
    mpChildren[Index]->Release();
  else if (mpChildren[Index])
  {
    mTreeNodeEventSink.DisconnectSource(mpChildren[Index]->Changed);
    mpChildren[Index]->SetParent(NULL);
  }
  mpChildren[Index] = pChild;  
  mTreeNodeEventSink.Connect(pChild->Changed, &nuiTreeBase::OnChildChanged, pChild);
  mTreeNodeEventSink.Connect(pChild->ChildAdded, &nuiTreeBase::OnChildAdded, pChild);
  mTreeNodeEventSink.Connect(pChild->ChildDeleted, &nuiTreeBase::OnChildRemoved, pChild);
  mTreeNodeEventSink.Connect(pChild->Deleted, &nuiTreeBase::OnChildDeleted, pChild);
  
  pChild->SetParent(this);

  AutoSort();
  Changed();
  ChildAdded(this, pChild);
  return true;
}
开发者ID:YetToCome,项目名称:nui3,代码行数:25,代码来源:nuiTree.cpp

示例10: AddChild

bool nuiTreeBase::InsertChild(uint32 Index, nuiTreePtr pChild)
{
  if (mpAutoSort)
    return AddChild(pChild);

  if (mpChildren.size() < Index+1)
    mpChildren.resize(Index+1);
  std::vector<nuiTreePtr>::iterator it = mpChildren.begin();
  it+=Index;
  if (it == mpChildren.end())
  {
    mpChildren.resize(mpChildren.size() - 1);
    return false;    
  }
  mpChildren.insert(it, pChild);
  pChild->Acquire();
  mTreeNodeEventSink.Connect(pChild->Changed, &nuiTreeBase::OnChildChanged, pChild);
  mTreeNodeEventSink.Connect(pChild->ChildAdded, &nuiTreeBase::OnChildAdded, pChild);
  mTreeNodeEventSink.Connect(pChild->ChildDeleted, &nuiTreeBase::OnChildRemoved, pChild);
  mTreeNodeEventSink.Connect(pChild->Deleted, &nuiTreeBase::OnChildDeleted, pChild);

  pChild->SetParent(this);

  AutoSort();
  Changed();
  ChildAdded(this, pChild);
  return true;
}
开发者ID:YetToCome,项目名称:nui3,代码行数:28,代码来源:nuiTree.cpp

示例11: PrivateSortFunction

bool nuiTreeBase::AddChild(nuiTreePtr pChild)
{
  pChild->Acquire();
  if (!mpAutoSort)
  {
    mpChildren.push_back(pChild);
  }
  else
  {
    // Sorted insert:
    std::vector<nuiTreePtr>::iterator it = std::upper_bound(mpChildren.begin(), mpChildren.end(), pChild, PrivateSortFunction(mpAutoSort));
    mpChildren.insert(it, pChild);
  }

  mTreeNodeEventSink.Connect(pChild->Changed, &nuiTreeBase::OnChildChanged, pChild);
  mTreeNodeEventSink.Connect(pChild->ChildAdded, &nuiTreeBase::OnChildAdded, pChild);
  mTreeNodeEventSink.Connect(pChild->ChildDeleted, &nuiTreeBase::OnChildRemoved, pChild);
  mTreeNodeEventSink.Connect(pChild->Deleted, &nuiTreeBase::OnChildDeleted, pChild);

  pChild->SetParent(this);

  Changed();
  ChildAdded(this, pChild);
  return false;
}
开发者ID:YetToCome,项目名称:nui3,代码行数:25,代码来源:nuiTree.cpp

示例12: ChildDeleted

bool nuiTreeBase::Clear(bool erase)
{
  for (uint32 i = 0; i < mpChildren.size(); i++)
  {
    nuiTreeBase* pChild = mpChildren[i];
    ChildDeleted(this, pChild);
  }
  if (erase)
  {
    std::vector<nuiTreePtr>::iterator it = mpChildren.begin();
    for (; it != mpChildren.end();)
    {
      nuiTreeBase* pChild = (*it);
      it = mpChildren.erase(it);
      pChild->Release();
    }
  }
  else
  {
    for (uint32 i = 0; i < mpChildren.size(); i++)
    {
      mpChildren[i]->SetParent(NULL);
      mTreeNodeEventSink.DisconnectSource(mpChildren[i]->Changed);
      mTreeNodeEventSink.DisconnectSource(mpChildren[i]->ChildAdded);
      mTreeNodeEventSink.DisconnectSource(mpChildren[i]->ChildDeleted);
      mTreeNodeEventSink.DisconnectSource(mpChildren[i]->Deleted);
    }
  }
  mpChildren.clear();
  Changed();
  return true;
}
开发者ID:YetToCome,项目名称:nui3,代码行数:32,代码来源:nuiTree.cpp

示例13: Changed

void nuiBorderDecoration::SetStrokeBottomColor(const nuiColor& color)
{
  mStrokeBottomColor = color;
  mUseStrokeBottomColor = true;
  mUseStrokeGlobalColor = false;
  Changed();
}
开发者ID:JamesLinus,项目名称:nui3,代码行数:7,代码来源:nuiBorderDecoration.cpp

示例14: assert

void EntityRef::onEntitySeen(Entity* e)
{
    assert(e);
    m_inner = e;
    m_inner->BeingDeleted.connect(sigc::mem_fun(this, &EntityRef::onEntityDeleted));	
	Changed();
}
开发者ID:worldforge,项目名称:eris,代码行数:7,代码来源:EntityRef.cpp

示例15: Changed

///////////////////////////////////////////////////////////
/// Tone change
///////////////////////////////////////////////////////////
void Bitmap::ToneChange(Tone tone) {
	if (tone.red == 0 && tone.green == 0 && tone.blue == 0 && tone.gray == 0) return;

	Uint8* dst_pixels = (Uint8*)&pixels[0];

	if (tone.gray == 0) {
		for (int i = 0; i < GetHeight(); i++) {
			for (int j = 0; j < GetWidth(); j++) {
				Uint8* pixel = dst_pixels;
				pixel[0] = (Uint8)max(min(pixel[0] + tone.red, 255), 0);
				pixel[1] = (Uint8)max(min(pixel[1] + tone.green, 255), 0);
				pixel[2] = (Uint8)max(min(pixel[2] + tone.blue, 255), 0);
				dst_pixels += 4;
			}
		}
	} else {
		double factor = (255 - tone.gray) / 255.0;
		double gray;
		for (int i = 0; i < GetHeight(); i++) {
			for (int j = 0; j < GetWidth(); j++) {
				Uint8* pixel = dst_pixels;

				gray = pixel[0] * 0.299 + pixel[1] * 0.587 + pixel[2] * 0.114;
				pixel[0] = (Uint8)max(min((pixel[0] - gray) * factor + gray + tone.red + 0.5, 255), 0);
				pixel[1] = (Uint8)max(min((pixel[1] - gray) * factor + gray + tone.green + 0.5, 255), 0);
				pixel[2] = (Uint8)max(min((pixel[2] - gray) * factor + gray + tone.blue + 0.5, 255), 0);
				dst_pixels += 4;
			}
		}
	}

	Changed();
}
开发者ID:cstrahan,项目名称:argss,代码行数:36,代码来源:bitmap.cpp


注:本文中的Changed函数示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。