3.63 DM_SetMultiValue
Using this function you are able to set several attributes of different DM objects in one function call. This function should therefore be implemented especially together with the Distributed Dialog Manager (DDM), since the network capacity is considerably reduced.
For information on the permitted attributes for the corresponding object type please refer to the “Object Reference”.
DM_Boolean DML_default DM_EXPORT DM_SetMultiValue
(
DM_MultiValue *values,
DM_UInt count,
DM_ID dialogID,
DM_String pathname,
DM_Options options
)
Parameters
<-> DM_MultiValue *values
List of attributes and objects to be reset. If the element in the structure for the object is set to 0, the object described in the parameter pathname is chosen. The list has to have at least the length specified in the parameter count.
-> DM_UInt count
Specifies the length of the object-attribute vector indicated in the parameter values.
-> DM_ID dialogID
This parameter describes the dialog to which the given objects belong. It has to be specified only if the object identifier whose attributes are to be set is not known and thus the name of the object is specified in the parameter pathname.
-> DM_String pathname
Describes the object the attributes of which are to be set. It will only be allocated if the object's internal identifier is not yet known.
-> DM_Options options
Currently not used. Please specify with 0.
Return Value
TRUE |
The attributes have been set successfully. |
FALSE |
At least one attribute could not be set. |
Example
Setting coordinates for several objects:
void DML_default DM_ENTRY Set __3((DM_ID, o1),
(DM_ID, o2),
(DM_ID, o3))
{
DM_MultiValue val[3];
/* Setting the relevant object */
val[0].object = o1;
val[1].object = o2;
val[2].object = o3;
/* Setting the relevant index type */
val[0].index.type = DT_void;
val[1].index.type = DT_void;
val[2].index.type = DT_void;
/* Setting the relevant attribute */
val[0].attribute = AT_xleft;
val[1].attribute = AT_width;
val[2].attribute = AT_xright;
/* Setting the attribute datatype */
val[0].data.type = DT_integer;
val[1].data.type = DT_integer;
val[2].data.type = DT_integer;
val[0].data.value.integer = 10;
val[1].data.value.integer = 50;
val[2].data.value.integer = 10;
DM_SetMultiValue(val, 3, dialogID, (char *)0, 0);
}