MCPcopy Create free account
hub / github.com/carbonengine/trinity / OnListModified

Method OnListModified

trinity/Shader/Tr2Effect.cpp:901–932  ·  view source on GitHub ↗

---------------------------------------------------------------

Source from the content-addressed store, hash-verified

899
900// ---------------------------------------------------------------
901void Tr2Effect::OnListModified( long event, ssize_t key, ssize_t key2, IRoot* currvalue, const IList* theList )
902{
903 CCP_STATS_ZONE( __FUNCTION__ );
904
905 if( ( event & BELIST_LOADING ) == 0 )
906 {
907 switch( event & BELIST_EVENTMASK )
908 {
909 case BELIST_REMOVED:
910 if( ITriReroutablePtr rp = BlueCastPtr( currvalue ) )
911 {
912 rp->SetDestination( NULL, 0 );
913 }
914 if( ITriEffectResourceParameterPtr res = BlueCastPtr( currvalue ) )
915 {
916 res->OnRemovedFromMaterial( this );
917 }
918 RebuildCachedDataInternal();
919 break;
920
921 case BELIST_INSERTED:
922 if( ITriEffectResourceParameterPtr res = BlueCastPtr( currvalue ) )
923 {
924 res->OnAddedToMaterial( this );
925 }
926 case BELIST_SWAPPED:
927 case BELIST_MOVED:
928 RebuildCachedDataInternal();
929 break;
930 }
931 }
932}
933
934// ---------------------------------------------------------------
935// PopulateParameters

Callers

nothing calls this directly

Calls 3

SetDestinationMethod · 0.45
OnRemovedFromMaterialMethod · 0.45
OnAddedToMaterialMethod · 0.45

Tested by

no test coverage detected