您当前的位置:首页 > IT编程 > C++
| C语言 | Java | VB | VC | python | Android | TensorFlow | C++ | oracle | 学术与代码 | cnn卷积神经网络 | gnn | 图像修复 | Keras | 数据集 | Neo4j | 自然语言处理 | 深度学习 | 医学CAD | 医学影像 | 超参数 | pointnet | pytorch | 异常检测 | Transformers | 情感分类 | 知识图谱 |

自学教程:C++ Change函数代码示例

51自学网 2021-06-01 20:09:52
  C++
这篇教程C++ Change函数代码示例写得很实用,希望能帮到您。

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

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

示例1: Change

void QgsGeometryCheck::deleteFeatureGeometryPart( QgsFeature &feature, int partIdx, Changes &changes ) const{  QgsAbstractGeometryV2* geom = feature.geometry()->geometry();  if ( dynamic_cast<QgsGeometryCollectionV2*>( geom ) )  {    static_cast<QgsGeometryCollectionV2*>( geom )->removeGeometry( partIdx );    if ( static_cast<QgsGeometryCollectionV2*>( geom )->numGeometries() == 0 )    {      mFeaturePool->deleteFeature( feature );      changes[feature.id()].append( Change( ChangeFeature, ChangeRemoved ) );    }    else    {      mFeaturePool->updateFeature( feature );      changes[feature.id()].append( Change( ChangePart, ChangeRemoved, QgsVertexId( partIdx ) ) );    }  }  else  {    mFeaturePool->deleteFeature( feature );    changes[feature.id()].append( Change( ChangeFeature, ChangeRemoved ) );  }}
开发者ID:spatialthoughts,项目名称:QGIS,代码行数:23,


示例2: ASSERT

void Selection::remove(Tile* tile, Item* item){	ASSERT(subsession);	ASSERT(tile);	ASSERT(item);	bool tmp = item->isSelected();	item->deselect();	Tile* new_tile = tile->deepCopy(editor.map);	if(tmp) item->select();	if(item->isBorder() && g_settings.getInteger(Config::BORDER_IS_GROUND)) new_tile->deselectGround();	subsession->addChange(newd Change(new_tile));}
开发者ID:HeavenIsLost,项目名称:rme,代码行数:14,


示例3: main

int main(){	int Option=1,			Value,			i;	       		while(Option){		printf("1) PUSH Stack/n2) POP Stack/n3) Print Stack/n4) Peep/n5) Change Stack/n0) Exit program/n"); 		scanf("%d", &Option);  		switch(Option){		 case 1:		   do{				printf("Enter a +ve value: "); 		    scanf("%d", &Value);			 }while(Value<0);       			 Push(Value);	/* allow possitive values */		   			 printf("Stack PUSHed/n/n");		   break;		 case 2:		   Pop();		   printf("Stack POPed/n/n");		   break;		 case 3:		   StackPrint();		   break;		 case 4:			 printf("Enter a valid index: ");		   scanf("%d", &Value);		   Value = Peep(Value);			 if(Value)			 	printf("Value at asked index: %d/n/n", Value);		   else				printf("wrong index/n/n");			 break;		 case 5:			 printf("Enter a valid index & value: ");		   scanf("%d %d", &i, &Value);			 Change(i,Value);			 printf("Value changed/n/n");		   break;		 case 0:		   DeleteStack();		   break;		 default:			 printf("Enter a valid choice/n/n");			 break;		}	}  return 1;}
开发者ID:Adesh,项目名称:cPrograms,代码行数:49,


示例4: Copy

int Copy(int copy, int index){  if (test[copy] > move_pos[index][copy])    if (copy > 0)       return Change(copy - 1);    else    {       No();       return 0;    }  test[copy] = move_pos[index][copy];  ++copy;  while (copy < p) test[copy++] = 1;  return 0;}
开发者ID:antoshkaplus,项目名称:CompetitiveProgramming,代码行数:15,


示例5: ChangeById

int ChangeById(mlink * h, id_tm who, mem_t sz, maddr_t * addr){	mlink *p = h;	if (NULL == h || sz < 0)		return -1;	if (NULL == (p = FindById(p, who)))		return -1;	if (-1 == Change(p, sz, addr))		return -1;	return 0;}
开发者ID:Qiuyongjie,项目名称:memlink,代码行数:15,


示例6: main

int main(){	int i,j;	for (i=0; i<3; i++)	 for (j=0; j<3; j++)	   scanf("%d",&a[i][j]);	Change(a);	for (i=0; i<3; i++)	{		for (j=0; j<3; j++)		 printf("%d ",a[i][j]);		 printf("/n");	}	return 0;}
开发者ID:2015CLanguage,项目名称:Homework8,代码行数:15,


示例7: ASSERT

void Selection::add(Tile* tile, Spawn* spawn){	ASSERT(subsession);	ASSERT(tile);	ASSERT(spawn);	if(spawn->isSelected()) return;	// Make a copy of the tile with the item selected	spawn->select();	Tile* new_tile = tile->deepCopy(editor.map);	spawn->deselect();	subsession->addChange(newd Change(new_tile));}
开发者ID:mattyx14,项目名称:rme,代码行数:15,


示例8: ChangeByoff

int ChangeByoff(mlink * h, offset_t off, mem_t sz, maddr_t * addr){	mlink *p = h;	if (NULL == h || off > Count(h) || off < 0 || sz < 0)		return -1;	if (NULL == (p = FindByoff(p, off)))		return -1;	if (-1 == Change(p, sz, addr))		return -1;	return 0;}
开发者ID:Qiuyongjie,项目名称:memlink,代码行数:15,


示例9: Replace_min

bool ScrollListShape::setSelectDown(ulen pos) // pos -> down , -> up , unchanged {  ulen count=info->getLineCount();  Replace_min(pos,count);  for(ulen i=pos; i<count ;i++)    {     if( info->getLine(i).type==ComboInfoText )       {        return Change(select,i);       }    }  for(ulen i=pos; i-- ;)    {     if( info->getLine(i).type==ComboInfoText )       {        return Change(select,i);       }    }  return false; }
开发者ID:SergeyStrukov,项目名称:CCore-2-99,代码行数:24,


示例10: Change

void Selection::clear(){	if(session) {		for(TileVector::iterator it = tiles.begin(); it != tiles.end(); it++) {			Tile* new_tile = (*it)->deepCopy(editor.map);			new_tile->deselect();			subsession->addChange(newd Change(new_tile));		}	} else {		for(TileVector::iterator it = tiles.begin(); it != tiles.end(); it++) {			(*it)->deselect();		}		tiles.clear();	}}
开发者ID:Codex-NG,项目名称:rme,代码行数:15,


示例11: breakToken

void WhitespaceManager::breakToken(const FormatToken &Tok, unsigned Offset,                                   unsigned ReplaceChars,                                   StringRef PreviousPostfix,                                   StringRef CurrentPrefix, bool InPPDirective,                                   unsigned Spaces) {  Changes.push_back(Change(      true, SourceRange(Tok.getStartOfNonWhitespace().getLocWithOffset(Offset),                        Tok.getStartOfNonWhitespace().getLocWithOffset(                            Offset + ReplaceChars)),      Spaces, Spaces, 1, PreviousPostfix, CurrentPrefix,      // FIXME: Unify token adjustment, so we don't split it between      // BreakableToken and the WhitespaceManager. That would also allow us to      // correctly store a tok::TokenKind instead of rolling our own enum.      tok::unknown, InPPDirective && !Tok.IsFirst));}
开发者ID:mikea,项目名称:clang,代码行数:15,


示例12: main

int main(){	freopen("name.in","r",stdin);	freopen("name.out","w",stdout);	scanf("%d",&n);	for(int i=1;i<=n;i++) scanf("%d",&a[i][0]);	for(int i=1;i<=n;i++) scanf("%d",&a[i][1]);	Build(1,n);	scanf("%d",&m);	for(int i=1,x,y,z;i<=m;i++)	{		scanf("%d%d%d",&x,&y,&z);		Change(1,x,y,z);	}	printf("%lld/n",t[1].sum[0]);}
开发者ID:cjsoft,项目名称:inasdfz,代码行数:16,


示例13: SeriesEdit

//перенос релиза серии на 7 днейvoid AnimeList::ModifySeries(){	Date release;	if(seriesDate.IsCursor())	{		release = ~dateSeries;		operator+=(release, 7);		seriesDate.Set(1, release);		series.number = seriesDate.Get(Series);		series.release = release;		SeriesEdit();		ModifyAnimeSeries();	}	Change();	ChangeSeries();}
开发者ID:MagistrTot,项目名称:AnimeListOld,代码行数:17,


示例14: Change

void QQuickChangeSet::change(QVector<Change> *changes){    QVector<Insert>::iterator insert = m_inserts.begin();    QVector<Change>::iterator change = m_changes.begin();    for (QVector<Change>::iterator cit = changes->begin(); cit != changes->end(); ++cit) {        for (; insert != m_inserts.end() && insert->end() < cit->index; ++insert) {}        for (; insert != m_inserts.end() && insert->index < cit->end(); ++insert) {            const int offset = insert->index - cit->index;            const int count = cit->count + cit->index - insert->index - insert->count;            if (offset == 0) {                cit->index = insert->index + insert->count;                cit->count = count;            } else {                cit = changes->insert(++cit, Change(insert->index + insert->count, count));                --cit;                cit->count = offset;            }        }        for (; change != m_changes.end() && change->index + change->count < cit->index; ++change) {}        if (change == m_changes.end() || change->index > cit->index + cit->count) {            if (cit->count > 0) {                change = m_changes.insert(change, *cit);                ++change;            }        } else {            if (cit->index < change->index) {                change->count += change->index - cit->index;                change->index = cit->index;            }            if (cit->index + cit->count > change->index + change->count) {                change->count = cit->index + cit->count - change->index;                QVector<Change>::iterator cbegin = change;                QVector<Change>::iterator cend = ++cbegin;                for (; cend != m_changes.end() && cend->index <= change->index + change->count; ++cend) {                    if (cend->index + cend->count > change->index + change->count)                        change->count = cend->index + cend->count - change->index;                }                if (cbegin != cend) {                    change = m_changes.erase(cbegin, cend);                    --change;                }            }        }    }}
开发者ID:crobertd,项目名称:qtdeclarative,代码行数:47,


示例15: Change

void QDeclarativeChangeSet::applyChanges(QVector<Change> &changes){    QVector<Insert>::iterator insert = m_inserts.begin();    QVector<Change>::iterator change = m_changes.begin();    for (QVector<Change>::iterator cit = changes.begin(); cit != changes.end(); ++cit) {        for (; insert != m_inserts.end() && insert->end() < cit->index; ++insert) {}        for (; insert != m_inserts.end() && insert->index < cit->end(); ++insert) {            const int offset = insert->index - cit->index;            const int count = cit->count + cit->index - insert->index - insert->count;            if (offset == 0) {                cit->index = insert->index + insert->count;                cit->count = count;            } else {                cit = changes.insert(++cit, Change(insert->index + insert->count, count));                --cit;                cit->count = offset;            }        }        for (; change != m_changes.end() && change->index + change->count < cit->index; ++change) {}        if (change == m_changes.end() || change->index > cit->index + cit->count) {            if (cit->count > 0) {                change = m_changes.insert(change, *cit);                ++change;            }        } else {            if (cit->index < change->index) {                change->count += change->index - cit->index;                change->index = cit->index;            }            if (cit->index + cit->count > change->index + change->count) {                change->count = cit->index + cit->count - change->index;                QVector<Change>::iterator rbegin = change;                QVector<Change>::iterator rend = ++rbegin;                for (; rend != m_changes.end() && rend->index <= change->index + change->count; ++rend) {                    if (rend->index + rend->count > change->index + change->count)                        change->count = rend->index + rend->count - change->index;                }                if (rbegin != rend) {                    change = m_changes.erase(rbegin, rend);                    --change;                }            }        }    }}
开发者ID:yinyunqiao,项目名称:qtdeclarative,代码行数:47,


示例16: replaceWhitespaceInToken

void WhitespaceManager::replaceWhitespaceInToken(    const FormatToken &Tok, unsigned Offset, unsigned ReplaceChars,    StringRef PreviousPostfix, StringRef CurrentPrefix, bool InPPDirective,    unsigned Newlines, unsigned Spaces) {  Changes.push_back(Change(      true, SourceRange(Tok.getStartOfNonWhitespace().getLocWithOffset(Offset),                        Tok.getStartOfNonWhitespace().getLocWithOffset(                            Offset + ReplaceChars)),      Spaces, Spaces, Newlines, PreviousPostfix, CurrentPrefix,      // If we don't add a newline this change doesn't start a comment. Thus,      // when we align line comments, we don't need to treat this change as one.      // FIXME: We still need to take this change in account to properly      // calculate the new length of the comment and to calculate the changes      // for which to do the alignment when aligning comments.      Tok.Type == TT_LineComment && Newlines > 0 ? tok::comment : tok::unknown,      InPPDirective && !Tok.IsFirst));}
开发者ID:IllusionRom-deprecated,项目名称:android_platform_external_clang,代码行数:17,


示例17: CtrlLayout

void MeasuresTab::Init(ScatterCtrl& scatter) {	CtrlLayout(*this);	SizePos();		pscatter = &scatter;		xMin <<= scatter.GetXMin();	xMax <<= scatter.GetXRange() + scatter.GetXMin();	yMin <<= scatter.GetYMin();	yMax <<= scatter.GetYRange() + scatter.GetYMin();	yMin2 <<= scatter.GetYMin2();	yMax2 <<= scatter.GetY2Range() + scatter.GetYMin2();		butUpdate.WhenAction = THISBACK(Change);		Change();}
开发者ID:kolyden,项目名称:mirror,代码行数:17,


示例18: layerFeatureA

void QgsGeometryContainedCheck::fixError( QgsGeometryCheckError *error, int method, const QMap<QString, int> & /*mergeAttributeIndices*/, Changes &changes ) const{  QgsGeometryContainedCheckError *containerError = static_cast<QgsGeometryContainedCheckError *>( error );  QgsFeaturePool *featurePoolA = mContext->featurePools[ error->layerId() ];  QgsFeaturePool *featurePoolB = mContext->featurePools[ containerError->containingFeature().first ];  QgsFeature featureA;  QgsFeature featureB;  if ( !featurePoolA->get( error->featureId(), featureA ) ||       !featurePoolB->get( containerError->containingFeature().second, featureB ) )  {    error->setObsolete();    return;  }  // Check if error still applies  QgsGeometryCheckerUtils::LayerFeature layerFeatureA( featurePoolA, featureA, true );  QgsGeometryCheckerUtils::LayerFeature layerFeatureB( featurePoolB, featureB, true );  std::unique_ptr< QgsGeometryEngine > geomEngineA = QgsGeometryCheckerUtils::createGeomEngine( layerFeatureA.geometry(), mContext->tolerance );  std::unique_ptr< QgsGeometryEngine > geomEngineB = QgsGeometryCheckerUtils::createGeomEngine( layerFeatureB.geometry(), mContext->tolerance );  if ( !( geomEngineB->contains( layerFeatureA.geometry() ) && !geomEngineA->contains( layerFeatureB.geometry() ) ) )  {    error->setObsolete();    return;  }  // Fix error  if ( method == NoChange )  {    error->setFixed( method );  }  else if ( method == Delete )  {    changes[error->layerId()][featureA.id()].append( Change( ChangeFeature, ChangeRemoved ) );    featurePoolA->deleteFeature( featureA.id() );    error->setFixed( method );  }  else  {    error->setFixFailed( tr( "Unknown method" ) );  }}
开发者ID:CS-SI,项目名称:QGIS,代码行数:44,


示例19: Change

size_t KeyBar::Change(const KeyBarTitles *Kbt){	size_t Result=0;	if (!Kbt)		return Result;	static DWORD Groups[]=	{		0,KBL_MAIN,		KEY_SHIFT,KBL_SHIFT,		KEY_CTRL,KBL_CTRL,		KEY_ALT,KBL_ALT,		KEY_CTRL|KEY_SHIFT,KBL_CTRLSHIFT,		KEY_ALT|KEY_SHIFT,KBL_ALTSHIFT,		KEY_CTRL|KEY_ALT,KBL_CTRLALT,		KEY_CTRL|KEY_ALT|KEY_SHIFT,KBL_CTRLALTSHIFT,	};	for (size_t I = 0; I < Kbt->CountLabels; ++I)	{		WORD Pos=Kbt->Labels[I].Key.VirtualKeyCode;		DWORD Shift=0,Flags=Kbt->Labels[I].Key.ControlKeyState;		if(Flags&(LEFT_CTRL_PRESSED|RIGHT_CTRL_PRESSED)) Shift|=KEY_CTRL;		if(Flags&(LEFT_ALT_PRESSED|RIGHT_ALT_PRESSED)) Shift|=KEY_ALT;		if(Flags&SHIFT_PRESSED) Shift|=KEY_SHIFT;		if (Pos >= VK_F1 && Pos <= VK_F24)		{			for (unsigned J=0; J < ARRAYSIZE(Groups); J+=2)			{				if (Groups[J] == Shift)				{					Change(Groups[J+1],Kbt->Labels[I].Text,Pos-VK_F1);					Result++;					break;				}			}		}	}	return Result;}
开发者ID:alexlav,项目名称:conemu,代码行数:44,


示例20: both

/*---------------------------------------------------------------------------   This function will update either the video texture, or depth texture, or   both (if applicable). It may also recofigure the filter if the selected   input has a different resolution. Returns true if either of the textures   were updated.  ---------------------------------------------------------------------------*/bool Filter::Update(Buffers &Buffer)   {   if (!Ready()) {return false;}   //Test for resolution change, if applicable   Change(Buffer);      bool Updated = false;   if (Buffer.VideoUpdated(VideoUpdateID) && EnableVideo)      {      Texture &VideoFront = Buffer.GetVideo();      MutexControl Mutex(VideoFront.GetMutexHandle());      if (Mutex.LockRequest())         {         Video.Bind(0);         Video.Update(VideoFront);         Video.Unbind(0);         Mutex.Unlock();         Updated |= true;         }      }   if (Buffer.DepthUpdated(DepthUpdateID) && EnableDepth)      {      Texture &DepthFront = Buffer.GetDepth();      MutexControl Mutex(DepthFront.GetMutexHandle());      if (Mutex.LockRequest())         {         Depth.Bind(0);         Depth.Update(DepthFront);         Depth.Unbind(0);         Mutex.Unlock();         Updated |= true;         }      }   #if defined (DEBUG)      GLenum Error = glGetError();      if (Error != GL_NO_ERROR) {throw dexception("OpenGL generated an error: %s", Debug::ErrorGL(Error));}   #endif   return Updated;   }
开发者ID:DominikDeak,项目名称:KFX,代码行数:50,


示例21: Change

void Properties::on_devicePathButton_clicked(int device, QLineEdit *line){	QString p=line->text();	if (p.length()==0) {		p=QDir::homePath();	}	ppl6::CString q=tr("Select directory with your files for device type: %s");	ppl6::CString Tmp;	Tmp.Setf((const char*)q,(const char*)wm->GetDeviceName(device));	QString dir = QFileDialog::getExistingDirectory(this, Tmp,		p,		QFileDialog::ShowDirsOnly | QFileDialog::DontResolveSymlinks);	if(dir.length()) {		line->setText(dir);		Change();	}}
开发者ID:pfedick,项目名称:winmusik,代码行数:19,


示例22: TheGame

void TheGame(int liveArray[BOARDH][BOARDW], int tempArray[BOARDH][BOARDW]){   int i = 1; /* Counter */   char generation = 'y'; /* Keep playing the game y/n variable */   do {      Copier(liveArray, tempArray);      Change(tempArray, liveArray);      printf("Generation %d:/n", i);      Printer(liveArray);      printf("Print next generation? (y/n): ");      scanf(" %c", &generation);      i++;   } while(generation == 'y');}
开发者ID:Tywholland,项目名称:CalPolySchoolWork,代码行数:19,


示例23: tr

void Properties::on_addDirectory_clicked(){	QString p;	if (LastHDSearchDir.isEmpty()) LastHDSearchDir=QDir::currentPath();	p=LastHDSearchDir;	QString dir = QFileDialog::getExistingDirectory(this, tr("Select the directory you want to add to the harddisk search"),		p,		QFileDialog::ShowDirsOnly | QFileDialog::DontResolveSymlinks);	if(dir.length()) {		LastHDSearchDir=dir;		// Sofern das Verzeichnis noch nicht in der Liste ist. fügen wir es hinzu		QList<QListWidgetItem *> list;		list=ui.directoryList->findItems (dir, Qt::MatchExactly);		if (list.count()==0) {			ui.directoryList->addItem(dir);			Change();		}	}}
开发者ID:pfedick,项目名称:winmusik,代码行数:19,


示例24: main

int main(){    int i,j,n,m,k,v,sum;    scanf("%d",&n);    getchar();    while(n--)    {       scanf("%s",a);       m=strlen(a);k=0;j=0;       memset(b,0,sizeof(b));       for(i=0;i<m;i++)       {          if(i%6!=0||i==0)          b[k][j++]=(int)a[i];          else          {             k++;j=0;             b[k][j++]=(int)a[i];          }       }       /*for(i=0;i<=k;i++)       {           for(j=0;j<6;j++)           printf("%d ",b[i][j]);           puts("");       }*/       v=0;sum=0;       for(i=0;i<6;i++)       {          sum=0;          for(j=0;j<=k;j++)          sum+=b[j][i];          c[v++]=Change(sum);          //printf("sum=%d/n",sum);       }       for(i=0;i<v;i++)       printf("%d",c[i]);       puts("");    }    system("pause");    return 0;}
开发者ID:iceker,项目名称:Test,代码行数:42,


示例25: One_Change

/******************************完成一次转换********************************* 函  数:u16 One_Change(void);* 功  能:控制DS18B20完成一次温度转换* 参  数:无* 返回值:无* 更  新:无* 备  注:无若要读出当前的温度数据我们需要执行两次工作周期,第一个周期为复位、跳过ROM指令(0xCC)、执行温度转换存储器操作指令(0x44)、等待500uS温度转换时间。紧接着执行第二个周期为复位、跳过ROM指令(0xCC)、执行读RAM的存储器操作指令(0xBE)、读数据(最多为9个字节,中途可停止,只读简单温度值则读前2个字节即可)。****************************************************************************/extern u16 One_Change(void){    ErrorStatus i;    do    {        i = Init_18B20();    }while(!i);    Skip_ID();//跳过ROM指令    Change();//执行温度转换存储器操作指令    delay1ms(10);    do    {        i = Init_18B20();    }while(!i);    Skip_ID();//跳过ROM指令    Read_Ram();    return (Tmp_Get());}
开发者ID:codekenq,项目名称:stm32-and-tm4c123g,代码行数:35,


示例26: if

void QgsGeometryContainedCheck::fixError( QgsGeometryCheckError* error, int method, int /*mergeAttributeIndex*/, Changes &changes ) const{    QgsGeometryContainedCheckError* coverError = static_cast<QgsGeometryContainedCheckError*>( error );    QgsFeature feature;    QgsFeature otherFeature;    if ( !mFeaturePool->get( error->featureId(), feature ) ||            !mFeaturePool->get( coverError->otherId(), otherFeature ) )    {        error->setObsolete();        return;    }    // Check if error still applies    QgsGeometry featureGeom = feature.geometry();    QgsGeometryEngine* geomEngine = QgsGeometryCheckerUtils::createGeomEngine( featureGeom.geometry(), QgsGeometryCheckPrecision::tolerance() );    if ( !geomEngine->within( *otherFeature.geometry().geometry() ) )    {        delete geomEngine;        error->setObsolete();        return;    }    delete geomEngine;    // Fix error    if ( method == NoChange )    {        error->setFixed( method );    }    else if ( method == Delete )    {        changes[feature.id()].append( Change( ChangeFeature, ChangeRemoved ) );        mFeaturePool->deleteFeature( feature );        error->setFixed( method );    }    else    {        error->setFixFailed( tr( "Unknown method" ) );    }}
开发者ID:Gustry,项目名称:QGIS,代码行数:41,


示例27: Change

void RageCompiledGeometry::Set( const vector<msMesh> &vMeshes, bool bNeedsNormals ){	m_bNeedsNormals = bNeedsNormals;	size_t totalVerts = 0;	size_t totalTriangles = 0;	m_bAnyNeedsTextureMatrixScale = false;	m_vMeshInfo.resize( vMeshes.size() );	for( unsigned i=0; i<vMeshes.size(); i++ )	{		const msMesh& mesh = vMeshes[i];		const vector<RageModelVertex> &Vertices = mesh.Vertices;		const vector<msTriangle> &Triangles = mesh.Triangles;		MeshInfo& meshInfo = m_vMeshInfo[i];		meshInfo.m_bNeedsTextureMatrixScale = false;		meshInfo.iVertexStart = totalVerts;		meshInfo.iVertexCount = Vertices.size();		meshInfo.iTriangleStart = totalTriangles;		meshInfo.iTriangleCount = Triangles.size();		totalVerts += Vertices.size();		totalTriangles += Triangles.size();		for( unsigned j = 0; j < Vertices.size(); ++j )		{			if( Vertices[j].TextureMatrixScale.x != 1.0f || Vertices[j].TextureMatrixScale.y != 1.0f )			{				meshInfo.m_bNeedsTextureMatrixScale = true;				m_bAnyNeedsTextureMatrixScale = true;			}		}	}	this->Allocate( vMeshes );	Change( vMeshes );}
开发者ID:Highlogic,项目名称:stepmania-event,代码行数:41,


示例28: switch

// Handle spinners in the dialog boxvoid AudioP3Dlg::SpinnerChange(int id,BOOL drag){	switch (id) {		case IDC_AUDAMP_BASEXSPIN:			cont->basePoint.x = dim->UnConvert(iBaseX->GetFVal());			Change();			break;		case IDC_AUDAMP_BASEYSPIN:			cont->basePoint.y = dim->UnConvert(iBaseY->GetFVal());			Change();			break;		case IDC_AUDAMP_BASEZSPIN:			cont->basePoint.z = dim->UnConvert(iBaseZ->GetFVal());			Change();			break;		case IDC_AUDAMP_TARGETXSPIN:			cont->targetPoint.x = dim->UnConvert(iTargetX->GetFVal());			Change();			break;		case IDC_AUDAMP_TARGETYSPIN:			cont->targetPoint.y = dim->UnConvert(iTargetY->GetFVal());			Change();			break;		case IDC_AUDAMP_TARGETZSPIN:			cont->targetPoint.z = dim->UnConvert(iTargetZ->GetFVal());			Change();			break;		case IDC_AUDAMP_NUMSAMPLESSPIN:			cont->numsamples = iSamples->GetIVal();			Change();			break;		case IDC_AUDAMP_THRESHOLDSPIN:			cont->threshold = iThreshold->GetFVal();			Change();			break;		}	ip->RedrawViews(ip->GetTime());	}
开发者ID:2asoft,项目名称:xray,代码行数:39,


示例29: Win

	SButton::SButton( int nId, Win* parent, unicode_t* txt, int _group, bool _isSet, crect* rect )		:  Win( Win::WT_CHILD, Win::WH_TABFOCUS | WH_CLICKFOCUS, parent, rect, nId ),		   isSet( _isSet ),		   text( txt ),		   group( _group )	{		if ( !rect )		{			GC gc( this );			gc.Set( GetFont() );			cpoint p = gc.GetTextExtents( txt );			if ( p.y < 16 ) { p.y = 16; }			p.x += 17 + 4;			p.y += 2;			SetLSize( LSize( p ) );		}		Change( isSet );	}
开发者ID:KonstantinKuklin,项目名称:WalCommander,代码行数:21,



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


C++ ChangeDisplaySettings函数代码示例
C++ Ch函数代码示例
万事OK自学网:51自学网_软件自学网_CAD自学网自学excel、自学PS、自学CAD、自学C语言、自学css3实例,是一个通过网络自主学习工作技能的自学平台,网友喜欢的软件自学网站。