Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Accelerators
Generic
AttributeCombiner
Commits
8046bf9a
Commit
8046bf9a
authored
Apr 24, 2019
by
Jean-Luc Pons
Browse files
Fix for stopped devices that may prevent to start
parent
35044f0f
Changes
1
Show whitespace changes
Inline
Side-by-side
AttributeCombiner.cpp
View file @
8046bf9a
...
...
@@ -457,13 +457,22 @@ void AttributeCombiner::add_dynamic_attributes()
// Retrieve the enum list from the first attribute
// All grouped attributes must have the same list
// get_device starts at one !!!!!
Tango
::
AttributeInfoEx
ae
=
deviceGroup
->
get_device
(
1
)
->
get_attribute_config
(
attNames
[
0
]);
// Use the first enabled device
int
i
=
0
;
bool
found
=
false
;
while
(
!
found
&&
i
<
(
int
)
deviceList
.
size
())
{
found
=
!
isDisabled
(
i
);
if
(
!
found
)
i
++
;
}
if
(
found
)
{
Tango
::
AttributeInfoEx
ae
=
deviceGroup
->
get_device
(
deviceList
[
i
])
->
get_attribute_config
(
attNames
[
0
]);
Tango
::
Attribute
&
eAtt
=
get_device_attr
()
->
get_attr_by_name
(
name
.
c_str
());
Tango
::
MultiAttrProp
<
Tango
::
DevEnum
>
presetProps
;
eAtt
.
get_properties
(
presetProps
);
presetProps
.
enum_labels
=
ae
.
enum_labels
;
eAtt
.
set_properties
(
presetProps
);
}
}
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment