|
Post by Rob on Oct 3, 2015 13:38:48 GMT 1
How to save the state of the Choice / Itemlist pins?
Place this in your source:
.xml file:
<Parameters> <Parameter id="0" datatype="enum" /> </Parameters>
<GUI> <Pin id="0" name="Value In" direction="in" datatype="int" parameterId="0" /> <Pin id="1" name="List Values" direction="in" datatype="string" parameterId="0" parameterField="EnumList"/>
<Pin id="2" name="Choice" direction="out" datatype="int"/> <Pin id="3" name="Item List" direction="out" datatype="string"/> <Pin id=".." ( the rest of your pins ) </GUI>
.h file:
Private:
IntGuiPin pinChoice; StringGuiPin pinListItems;
.cpp file:
Yourmodulename::yourmodulename( IMpUnknown* host ) : MpGuiBase(host) {
pinChoice.initialize( this, 0, static_cast<MpGuiBaseMemberPtr>(&Yourmodulename::onSetChoice) ); pinListItems.initialize( this, 1);
pinYourpins.initialize( this, 2, static_cast<MpGuiBaseMemberPtr>(&yourmodulename::onSetYourpins) ); ..all your other pins
}
|
|