1
0
mirror of https://git.dev.opencascade.org/repos/occt.git synced 2025-08-29 14:00:49 +03:00

0028726: Quantity_NameOfColor should be replaced by Quantity_Color in function input argument

AIS_InteractiveObject, virtual methods ::SetColor(), ::Color()
returning/accepting Quantity_NameOfColor have been removed.
Virtual method ::SetMaterial() accepting Graphic3d_NameOfMaterial has been also removed.

V3d_View, V3d_Viewer, V3d_AmbientLight, V3d_DirectionalLight,
V3d_Light, V3d_PositionalLight, V3d_SpotLight, Aspect_Window,
methods accepting Quantity_NameOfColor have been removed (duplicates)
or color argument(s) replaced with Quantity_Color.
This commit is contained in:
kgv
2017-05-11 18:10:53 +03:00
committed by bugmaster
parent 5ecc46c08e
commit 87432b8278
71 changed files with 426 additions and 1585 deletions

View File

@@ -179,12 +179,12 @@ void DocumentCommon::onShading()
void DocumentCommon::onColor()
{
QColor aColor ;
Quantity_Color aShapeColor;
myContext->InitSelected();
Handle(AIS_InteractiveObject) Current = myContext->SelectedInteractive() ;
if ( Current->HasColor () )
{
aShapeColor = myContext->Color( Current );
Quantity_Color aShapeColor;
myContext->Color( Current, aShapeColor );
aColor.setRgb( aShapeColor.Red() * 255, aShapeColor.Green() * 255, aShapeColor.Blue() * 255 );
}
else
@@ -196,7 +196,7 @@ void DocumentCommon::onColor()
Quantity_Color color( aRetColor.red() / 255., aRetColor.green() / 255.,
aRetColor.blue() / 255., Quantity_TOC_RGB );
for (; myContext->MoreSelected(); myContext->NextSelected() )
myContext->SetColor( myContext->SelectedInteractive(), color.Name(), Standard_False);
myContext->SetColor( myContext->SelectedInteractive(), color, Standard_False);
myContext->UpdateCurrentViewer();
}
}