V 10 1 LANG:1 8 (NoName) PANEL,-1 -1 283 262 N {204,204,204} 1 "$ObjectName" "main() { // Read $ Param & detect Domain/Object int type =0; object = $ObjectName ; domain = object; while(type == 0) domain = fwCU_getParent(type, domain); if (domain == \"\" ) domain = object; // select the type of rappresentation string label = \"\"; if (!fwFsm_isCU(domain,object) ) { fwUi_getLabel(domain, object, label); setValue(\"bdObjectStatus\",\"toolTipText\",label); connectedDomain = domain; connectedObject = object; fwFsmUi_connectModeBits(\"dev_show\", domain, object); } else { domain = object; fwUi_getLabel(domain, object, label); setValue(\"bdObjectStatus\",\"toolTipText\",(label == \"\") ? object : label ); connectedDomain = domain; connectedObject = object; fwFsmUi_connectModeBits(\"cu_show\",domain, object); } connectedNode = domain+\"::\"+object; fwCU_connectState(\"show_state\", connectedNode); //fwUi_connectExecutingAction(\"show_busy\", domain, object); } // ------ dev_show() { string color; dyn_string actions; int i, index; bit32 statusBits; statusBits = fwFsmUi_getOwnModeBits(); if(getBit(statusBits,FwOwnerBit)) { if(getBit(statusBits,FwExclusiveBit)) duSymbol(1, statusBits); else duSymbol(2, statusBits); } else { if(!getBit(statusBits,FwFreeBit)) { if(getBit(statusBits,FwExclusiveBit)) duSymbol(4, statusBits); else duSymbol(3, statusBits); } else duSymbol(5, statusBits); } } cu_show() { string color; dyn_string actions; int i, index; bit32 statusBits; statusBits = fwFsmUi_getOwnModeBits(); if(statusBits == 0) { cuSymbol(5, statusBits); return; } if(getBit(statusBits,FwOwnerBit)) { if(getBit(statusBits,FwExclusiveBit)) cuSymbol(1, statusBits); else cuSymbol(2, statusBits); } else { if(!getBit(statusBits,FwFreeBit)) { if(getBit(statusBits,FwExclusiveBit)) cuSymbol(4, statusBits); else cuSymbol(3, statusBits); } else { if(!getBit(statusBits,FwSendCommandsBit)) cuSymbol(5, statusBits); else cuSymbol(6, statusBits); } } } // ----------------------------- show_state(string dp, string state) { int operate_domain, operate_object; string color; fwCU_getStateColor(dp, state, color); setMultiValue(\"bdObjectStatus\",\"toolTipText\",connectedNode+\" = \"+state,\"bdObjectStatus\",\"backCol\",color); } /* show_busy(string dp, string action) { if(action == \"\") setValue(\"txtObjectStatus\",\"enabled\",true); else setValue(\"txtObjectStatus\",\"enabled\",false); } */" 0 E E E E 1 0 0 0 10 30 ""0 1 E "string domain; string object; string connectedNode = \"\"; string connectedDomain = \"\"; string connectedObject = \"\"; void cuSymbol(int num, bit32 statusBits) { disableAll(); if(num) { setValue(\"lock\"+num,\"visible\",1); if(num < 5) { if(getBit(statusBits,FwIncompleteBit)) setValue(\"lock\"+num,\"backCol\",\"FwStateAttention2\"); else if(getBit(statusBits,FwIncompleteDevBit)) setValue(\"lock\"+num,\"backCol\",\"FwStateAttention1\"); else setValue(\"lock\"+num,\"backCol\",\"_3DFace\"); } else setValue(\"lock\"+num,\"backCol\",\"_3DFace\"); } } void duSymbol(int num, bit32 statusBits) { disableAll(); if((num == 1) || (num == 2) || (num == 3)) { if(getBit(statusBits,FwSendCommandsBit)) setValue(\"enabled\",\"visible\",1); else setValue(\"disabled\",\"visible\",1); } else { if(getBit(statusBits,FwSendCommandsBit)) setValue(\"enabled_grey\",\"visible\",1); else setValue(\"disabled_grey\",\"visible\",1); } if(getBit(statusBits,FwIncompleteDevBit)) setValue(\"enabled\",\"backCol\",\"FwStateAttention1\"); else setValue(\"enabled\",\"backCol\",\"_3DFace\"); } void disableAll() { setMultiValue(\"lock1\",\"visible\",false,\"lock2\",\"visible\",false,\"lock3\",\"visible\",false, \"lock4\",\"visible\",false,\"lock5\",\"visible\",false,\"lock6\",\"visible\",false); setMultiValue(\"disabled\",\"visible\",false,\"enabled\",\"visible\",false, \"disabled_grey\",\"visible\",false,\"enabled_grey\",\"visible\",false); }" 0 2 "CBRef" "1" "EClose" E "" DISPLAY_LAYER, 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 LAYER, 0 1 LANG:1 6 Layer1 6 20 "bdObjectStatus" "" 1 10 30 E E E 1 E 1 E N "_WindowText" E N {255,255,255} E E E E 20 0 0 0 0 0 E E E 2 1 LANG:1 0 1 "dashclr"N "_Transparent" E E 0 1 1 0 1 E U 1 E 10 10 30 30 4 21 "Line1" "" 1 33 10 E E E 1 E 1 E N "_WindowText" E N {255,255,255} E E E E 21 0 0 0 0 0 E E E 0 1 LANG:1 0 1 "dashclr"N "_Transparent" E E 0 1 1 0 1 E 33 10 33 30 4 22 "Line2" "" 1 53 10 E E E 1 E 1 E N {255,255,255} E N {255,255,255} E E E E 22 0 0 0 0 0 E E E 0 1 LANG:1 0 1 "dashclr"N "_Transparent" E E 0 1 1 0 1 E 53 10 53 30 4 24 "Line4" "" 1 33 10 E E E 1 E 1 E N {0,0,0} E N {255,255,255} E E E E 24 0 0 0 0 0 E E E 0 1 LANG:1 0 1 "dashclr"N "_Transparent" E E 0 1 1 0 1 E 33 10 53 10 4 23 "Line3" "" 1 33 29 E E E 1 E 1 E N {255,255,255} E N {255,255,255} E E E E 23 0 0 0 0 0 E E E 0 1 LANG:1 0 1 "dashclr"N "_Transparent" E E 0 1 1 0 1 E 33 29 53 29 13 5 "lock6" "" 1 27 5 E E E 1 E 0 E N "_ButtonText" E N "_Button" E E E E 6 0 0 0 0 0 E E E 1 1 LANG:1 0 0 1 LANG:1 96 -*-Courier New-*-r-normal-*-12-*-100-100-*-*-iso8859-1|-12,0,0,0,404,0,0,0,0,0,0,0,0,Courier New 0 "" 32 9 54 31 P 13434828 "pictures/hmpIcons/lockWhite.bmp" 1 LANG:1 0 E E E E 13 6 "lock5" "" 1 27 5 E E E 1 E 1 E N "_ButtonText" E N "_Button" E E E E 7 0 0 0 0 0 E E E 1 1 LANG:1 0 0 1 LANG:1 96 -*-Courier New-*-r-normal-*-12-*-100-100-*-*-iso8859-1|-12,0,0,0,404,0,0,0,0,0,0,0,0,Courier New 0 "" 32 9 54 31 P 13434828 "pictures/hmpIcons/unlockWhite.bmp" 1 LANG:1 0 E E E E 13 8 "lock2" "" 1 27 5 E E E 1 E 0 E N "_ButtonText" E N "_Button" E E E E 9 0 0 0 0 0 E E E 1 1 LANG:1 0 0 1 LANG:1 96 -*-Courier New-*-r-normal-*-12-*-100-100-*-*-iso8859-1|-12,0,0,0,404,0,0,0,0,0,0,0,0,Courier New 0 "" 32 9 54 31 P 13434828 "pictures/hmpIcons/lockBlue.bmp" 1 LANG:1 0 E E E E 13 9 "lock4" "" 1 27 5 E E E 1 E 0 E N "_ButtonText" E N "_Button" E E E E 10 0 0 0 0 0 E E E 1 1 LANG:1 0 0 1 LANG:1 96 -*-Courier New-*-r-normal-*-12-*-100-100-*-*-iso8859-1|-12,0,0,0,404,0,0,0,0,0,0,0,0,Courier New 0 "" 32 9 54 31 P 13434828 "pictures/hmpIcons/lockRed.bmp" 1 LANG:1 0 E E E E 13 10 "lock3" "" 1 27 5 E E E 1 E 0 E N "_ButtonText" E N "_Button" E E E E 11 0 0 0 0 0 E E E 1 1 LANG:1 0 0 1 LANG:1 96 -*-Courier New-*-r-normal-*-12-*-100-100-*-*-iso8859-1|-12,0,0,0,404,0,0,0,0,0,0,0,0,Courier New 0 "" 32 9 54 31 P 13434828 "pictures/hmpIcons/lockYellow.bmp" 1 LANG:1 0 E E E E 13 16 "enabled" "" 1 27 5 E E E 1 E 0 E N "_ButtonText" E N "_Button" E E E E 17 0 0 0 0 0 E E E 1 1 LANG:1 0 0 1 LANG:1 96 -*-Courier New-*-r-normal-*-12-*-100-100-*-*-iso8859-1|-12,0,0,0,404,0,0,0,0,0,0,0,0,Courier New 0 "" 32 9 54 31 P 13434828 "pictures/hmpIcons/devEn.bmp" 1 LANG:1 0 E E E E 13 17 "disabled" "" 1 27 5 E E E 1 E 0 E N "_ButtonText" E N "_Button" E E E E 18 0 0 0 0 0 E E E 1 1 LANG:1 0 0 1 LANG:1 96 -*-Courier New-*-r-normal-*-12-*-100-100-*-*-iso8859-1|-12,0,0,0,404,0,0,0,0,0,0,0,0,Courier New 0 "" 32 9 54 31 P 13434828 "pictures/hmpIcons/devDis.bmp" 1 LANG:1 0 E E E E 13 18 "enabled_grey" "" 1 27 5 E E E 1 E 0 E N "_ButtonText" E N "_Button" E E E E 19 0 0 0 0 0 E E E 1 1 LANG:1 0 0 1 LANG:1 96 -*-Courier New-*-r-normal-*-12-*-100-100-*-*-iso8859-1|-12,0,0,0,404,0,0,0,0,0,0,0,0,Courier New 0 "" 32 9 54 31 P 13434828 "pictures/hmpIcons/devEn_grey.bmp" 1 LANG:1 0 E E E E 13 19 "disabled_grey" "" 1 27 5 E E E 1 E 0 E N "_ButtonText" E N "_Button" E E E E 20 0 0 0 0 0 E E E 1 1 LANG:1 0 0 1 LANG:1 96 -*-Courier New-*-r-normal-*-12-*-100-100-*-*-iso8859-1|-12,0,0,0,404,0,0,0,0,0,0,0,0,Courier New 0 "" 32 9 54 31 P 13434828 "pictures/hmpIcons/devDis_grey.bmp" 1 LANG:1 0 E E E "main() { }" 0 13 7 "lock1" "" 1 27 5 E E E 1 E 0 E N "_3DText" E N {255,255,0} E E E E 8 0 0 0 0 0 E E E 1 1 LANG:1 0 0 1 LANG:1 96 -*-Courier New-*-r-normal-*-12-*-100-100-*-*-iso8859-1|-12,0,0,0,404,0,0,0,0,0,0,0,0,Courier New 0 "" 32 9 54 31 P 13434828 "pictures/hmpIcons/lockGreen.bmp" 1 LANG:1 0 E E E E 0 LAYER, 1 1 LANG:1 6 Layer2 0 LAYER, 2 1 LANG:1 6 Layer3 0 LAYER, 3 1 LANG:1 6 Layer4 0 LAYER, 4 1 LANG:1 6 Layer5 0 LAYER, 5 1 LANG:1 6 Layer6 0 LAYER, 6 1 LANG:1 6 Layer7 0 LAYER, 7 1 LANG:1 6 Layer8 0 0