UI/ToolCommunicationReceiver.py
Main Page
Groups
Classes
Examples
UI/ToolCommunicationReceiver.py
1
# Copyright 2009 Autodesk, Inc. All rights reserved.
2
# Use of this software is subject to the terms of the Autodesk license agreement
3
# provided at the time of installation or download, or which otherwise accompanies
4
# this software in either electronic or hard copy form.
5
#
6
# Script description:
7
# This tool is used with ToolCommunicationSender. The Sender will "ping" the receiver.
8
# This tool provide a vertical list used to display the "ping"
9
#
10
# Topic: FBList, FBListStyle, FBTool
11
#
12
13
from
pyfbsdk
import
*
14
from
pyfbsdk_additions
import
*
15
16
17
# Tool creation will serve as the hub for all other controls
18
t =
FBCreateUniqueTool
(
"Receiver"
)
19
t.StartSizeX = 400
20
t.StartSizeY = 400
21
x =
FBAddRegionParam
(0,FBAttachType.kFBAttachLeft,
""
)
22
y =
FBAddRegionParam
(0,FBAttachType.kFBAttachTop,
""
)
23
w =
FBAddRegionParam
(0,FBAttachType.kFBAttachRight,
""
)
24
h =
FBAddRegionParam
(0,FBAttachType.kFBAttachBottom,
""
)
25
t.AddRegion(
"main"
,
"main"
, x, y, w, h)
26
27
t.receivedList =
FBList
()
28
t.receivedList.Style = FBListStyle.kFBVerticalList
29
t.SetControl(
"main"
,t.receivedList)
30
31
ShowTool
(t)