From: ouv Date: Tue, 16 Feb 2010 09:15:23 +0000 (+0000) Subject: Issue 0020704: EDF 1292 VISU: SURFACEFRAME on a scalar map using a python script X-Git-Tag: V5_1_main_20100217 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=d027c07cd7f5fb07977090a28bdc89a6b296e4fb;p=modules%2Fvisu.git Issue 0020704: EDF 1292 VISU: SURFACEFRAME on a scalar map using a python script --- diff --git a/src/VISU_I/VISU_View_i.cc b/src/VISU_I/VISU_View_i.cc index b9f660ce..89ebe9d2 100644 --- a/src/VISU_I/VISU_View_i.cc +++ b/src/VISU_I/VISU_View_i.cc @@ -2379,10 +2379,10 @@ namespace VISU { myResult("Unknown error occured") {} virtual void Execute() { + VISU::VISUType aType = myPrs->GetType(); switch (myPrsType) { case VISU::INSIDEFRAME: { - VISU::VISUType aType = myPrs->GetType(); if (aType != VISU::TSCALARMAP && aType != VISU::TDEFORMEDSHAPE && aType != VISU::TSCALARMAPONDEFORMEDSHAPE && @@ -2393,8 +2393,19 @@ namespace VISU { } break; case VISU::SURFACEFRAME: - myResult = "Surfaceframe representation is available only for mesh presentation."; - return; + { + if (aType != VISU::TSCALARMAP && + aType != VISU::TDEFORMEDSHAPE && + aType != VISU::TSCALARMAPONDEFORMEDSHAPE && + aType != VISU::TDEFORMEDSHAPEANDSCALARMAP && + aType != VISU::TCUTPLANES && + aType != VISU::TISOSURFACES && + aType != VISU::TPLOT3D) { + myResult = "Surfaceframe representation is not available for this type of presentations."; + return; + } + } + break; case VISU::SHRINK: myResult = "Use SetShrinked() method to shrink/unshrink presentation."; return;