Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Bill Lorensen
VTK
Commits
cd4b584a
Commit
cd4b584a
authored
May 05, 2012
by
Dave DeMarle
Browse files
Merge branch 'fix-setget-tests' into release
Change-Id: I45d5e1e49aa9154edd826f02687ffc6bd3eff464
parents
49c3e919
8e17ee09
Changes
2
Hide whitespace changes
Inline
Side-by-side
Charts/vtkContext2D.cxx
View file @
cd4b584a
...
...
@@ -639,7 +639,11 @@ void vtkContext2D::ApplyPen(vtkPen *pen)
//-----------------------------------------------------------------------------
vtkPen
*
vtkContext2D
::
GetPen
()
{
return
this
->
Device
->
GetPen
();
if
(
this
->
Device
)
{
return
this
->
Device
->
GetPen
();
}
return
NULL
;
}
//-----------------------------------------------------------------------------
...
...
@@ -651,7 +655,11 @@ void vtkContext2D::ApplyBrush(vtkBrush *brush)
//-----------------------------------------------------------------------------
vtkBrush
*
vtkContext2D
::
GetBrush
()
{
return
this
->
Device
->
GetBrush
();
if
(
this
->
Device
)
{
return
this
->
Device
->
GetBrush
();
}
return
NULL
;
}
//-----------------------------------------------------------------------------
...
...
@@ -663,7 +671,11 @@ void vtkContext2D::ApplyTextProp(vtkTextProperty *prop)
//-----------------------------------------------------------------------------
vtkTextProperty
*
vtkContext2D
::
GetTextProp
()
{
return
this
->
Device
->
GetTextProp
();
if
(
this
->
Device
)
{
return
this
->
Device
->
GetTextProp
();
}
return
NULL
;
}
//-----------------------------------------------------------------------------
...
...
@@ -678,8 +690,12 @@ void vtkContext2D::SetTransform(vtkTransform2D *transform)
//-----------------------------------------------------------------------------
vtkTransform2D
*
vtkContext2D
::
GetTransform
()
{
this
->
Device
->
GetMatrix
(
this
->
Transform
->
GetMatrix
());
return
this
->
Transform
;
if
(
this
->
Device
&&
this
->
Transform
)
{
this
->
Device
->
GetMatrix
(
this
->
Transform
->
GetMatrix
());
return
this
->
Transform
;
}
return
NULL
;
}
//-----------------------------------------------------------------------------
...
...
Chemistry/vtkProgrammableElectronicData.cxx
View file @
cd4b584a
...
...
@@ -98,6 +98,11 @@ void vtkProgrammableElectronicData::SetNumberOfMOs(vtkIdType size)
//----------------------------------------------------------------------------
vtkImageData
*
vtkProgrammableElectronicData
::
GetMO
(
vtkIdType
orbitalNumber
)
{
if
(
orbitalNumber
<=
0
)
{
vtkWarningMacro
(
<<
"Request for invalid orbital number "
<<
orbitalNumber
);
return
NULL
;
}
if
(
orbitalNumber
>
static_cast
<
vtkIdType
>
(
this
->
MOs
->
size
()))
{
vtkWarningMacro
(
<<
"Request for orbital number "
<<
orbitalNumber
...
...
@@ -117,6 +122,11 @@ vtkImageData * vtkProgrammableElectronicData::GetMO(vtkIdType orbitalNumber)
void
vtkProgrammableElectronicData
::
SetMO
(
vtkIdType
orbitalNumber
,
vtkImageData
*
data
)
{
if
(
orbitalNumber
<=
0
)
{
vtkErrorMacro
(
"Cannot set invalid orbital number "
<<
orbitalNumber
);
return
;
}
if
(
orbitalNumber
>
static_cast
<
vtkIdType
>
(
this
->
MOs
->
size
()))
{
this
->
SetNumberOfMOs
(
orbitalNumber
);
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment