OnChanged on self-installing property 2004-07-20 - By Hardt, Michael
Back Professors of Properties,
I can't get the OnChanged event to work for my self-installing property. Can anybody see the problem with this?
Michael Hardt
'''''''''''''''''''''Save as PropA.vbs''''''''''''''''''''''''''''''''''''''''''''
'Drop into a ...\Softimage\XSI_4.0\Application\Plugins folder to install. 'Go under Get, Property, PropAMenuItem to apply / inspect. 'Creates and inspects a PropA custom property under the scene root.
function XSILoadPlugin( in_reg ) in_reg.Name = "PropA SDK Example" in_reg.RegisterProperty "PropA" in_reg.RegisterMenu siMenuTbGetPropertyPSetID, "PropA_Menu", false, false XSILoadPlugin = true end function
function PropA_Define( io_Context ) io_Context.Source.AddParameter3 "MyAParam", siInt4, 1, 0, 20 end function
function PropA_DefineLayout( io_Context ) io_Context.Source.Clear io_Context.Source.AddItem "MyAParam", "My A Parameter" end function
function PropA_OnInit( io_Context ) LogMessage "In PropA_OnInit, io_Context.Source: " & io_Context.Source.FullName 'I never see this message, but that might be okay end function
function PropA_MyAParam_OnChanged( io_Context ) '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''' '''''''''PROBLEM HERE''''''''''''''''''''''''''''''''''''''' '''''''''I never see this message, but I want to see it.'''' LogMessage "In PropA_MyAParam_OnChanged" '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''' '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''' end function
function PropA_Menu_Init( io_Context ) io_Context.Source.AddCallbackItem "PropAMenuItem", "OnPropAMenuClicked" end function
function OnPropAMenuClicked( io_Context ) Set oNewProp = Application.ActiveSceneRoot.AddProperty("PropA") InspectObj oNewProp, , "PropA", siRecycle end function
'''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''' ''''''''''
--- Unsubscribe? Mail Majordomo@(protected) with the following text in body: unsubscribe xsi
|
|