File tree Expand file tree Collapse file tree 2 files changed +12
-5
lines changed
Sources/Rendering/Core/AbstractMapper Expand file tree Collapse file tree 2 files changed +12
-5
lines changed Original file line number Diff line number Diff line change @@ -35,13 +35,15 @@ export interface vtkAbstractMapper extends vtkAbstractMapperBase {
35
35
36
36
/**
37
37
* Remove all clipping planes.
38
+ * @return true if there were planes, false otherwise.
38
39
*/
39
- removeAllClippingPlanes ( ) : void ;
40
+ removeAllClippingPlanes ( ) : boolean ;
40
41
41
- /**
42
- * Remove clipping plane.
43
- * @param {vtkPlane } plane
44
- */
42
+ /**
43
+ * Remove clipping plane.
44
+ * @param {vtkPlane } plane
45
+ * @return true if plane existed and therefore is removed, false otherwise.
46
+ */
45
47
removeClippingPlane ( plane : vtkPlane ) : boolean ;
46
48
47
49
/**
Original file line number Diff line number Diff line change @@ -25,7 +25,12 @@ function vtkAbstractMapper(publicAPI, model) {
25
25
publicAPI . getNumberOfClippingPlanes = ( ) => model . clippingPlanes . length ;
26
26
27
27
publicAPI . removeAllClippingPlanes = ( ) => {
28
+ if ( model . clippingPlanes . length === 0 ) {
29
+ return false ;
30
+ }
28
31
model . clippingPlanes . length = 0 ;
32
+ publicAPI . modified ( ) ;
33
+ return true ;
29
34
} ;
30
35
31
36
publicAPI . removeClippingPlane = ( clippingPlane ) => {
You can’t perform that action at this time.
0 commit comments