Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
P
proview
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Esteban Blanc
proview
Commits
c949de84
Commit
c949de84
authored
Dec 19, 2017
by
Marcus Nordenberg
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Profinet Configurator: Add more help text for ModuleTypes, fix some typos
parent
628630f9
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
14 additions
and
18 deletions
+14
-18
profibus/lib/cow/gtk/cow_pn_gsdml_attrnav_gtk.cpp
profibus/lib/cow/gtk/cow_pn_gsdml_attrnav_gtk.cpp
+7
-8
profibus/lib/cow/src/cow_pn_gsdml_attrnav.cpp
profibus/lib/cow/src/cow_pn_gsdml_attrnav.cpp
+6
-7
profibus/lib/cow/src/cow_pn_gsdml_attrnav.h
profibus/lib/cow/src/cow_pn_gsdml_attrnav.h
+1
-3
No files found.
profibus/lib/cow/gtk/cow_pn_gsdml_attrnav_gtk.cpp
View file @
c949de84
...
...
@@ -116,8 +116,8 @@ void GsdmlAttrNavGtk::display_attr_help_text()
switch
(
base_item
->
type
)
{
/*
* The following two item types could make use
if the same info_text in the base class as PnEnumValue does
* but since they already contained references t
o t
hey were used instead...
* The following two item types could make use
of the same info_text that the the base class does,
* but since they already contained references they were used instead...
*/
case
attrnav_eItemType_PnParValue
:
case
attrnav_eItemType_PnParEnum
:
{
...
...
@@ -130,18 +130,17 @@ void GsdmlAttrNavGtk::display_attr_help_text()
//If we do have help available show it
if
(
vi
&&
vi
->
Body
.
Help
.
p
)
((
GsdmlAttrGtk
*
)
parent_ctx
)
->
attr_help_text
((
char
*
)
vi
->
Body
.
Help
.
p
);
else
((
GsdmlAttrGtk
*
)
parent_ctx
)
->
attr_help_text
(
""
);
break
;
}
case
attrnav_eItemType_PnEnumValue
:
{
default:
{
// Do we have an associated info text string to show the user some more info?
if
(
base_item
->
info_text
)
((
GsdmlAttrGtk
*
)
parent_ctx
)
->
attr_help_text
(
base_item
->
info_text
);
break
;
else
((
GsdmlAttrGtk
*
)
parent_ctx
)
->
attr_help_text
(
""
)
;
}
default:
((
GsdmlAttrGtk
*
)
parent_ctx
)
->
attr_help_text
(
""
);
}
}
profibus/lib/cow/src/cow_pn_gsdml_attrnav.cpp
View file @
c949de84
...
...
@@ -2095,8 +2095,7 @@ int ItemPnEnumValue::scan( GsdmlAttrNav *attrnav, void *p)
ItemPnEnumValueMType
::
ItemPnEnumValueMType
(
GsdmlAttrNav
*
attrnav
,
const
char
*
item_name
,
const
char
*
item_number
,
int
item_num
,
int
item_type_id
,
void
*
attr_value_p
,
brow_tNode
dest
,
flow_eDest
dest_code
)
:
num
(
item_num
),
type_id
(
item_type_id
),
value_p
(
attr_value_p
),
first_scan
(
1
)
brow_tNode
dest
,
flow_eDest
dest_code
,
const
char
*
info_text
)
:
ItemPn
(
info_text
),
num
(
item_num
),
type_id
(
item_type_id
),
value_p
(
attr_value_p
),
first_scan
(
1
)
{
type
=
attrnav_eItemType_PnEnumValueMType
;
...
...
@@ -2238,9 +2237,8 @@ int ItemPnDevice::scan( GsdmlAttrNav *attrnav, void *p)
if
(
attrnav
->
device_num
==
0
)
strcpy
(
buf
,
"No"
);
else
{
strncpy
(
buf
,
(
char
*
)
attrnav
->
gsdml
->
ApplicationProcess
->
DeviceAccessPointList
->
DeviceAccessPointItem
[
attrnav
->
device_num
-
1
]
->
ModuleInfo
->
Body
.
Name
.
p
,
sizeof
(
buf
));
gsdml_DeviceAccessPointItem
*
item
=
attrnav
->
gsdml
->
ApplicationProcess
->
DeviceAccessPointList
->
DeviceAccessPointItem
[
attrnav
->
device_num
-
1
];
snprintf
(
buf
,
sizeof
(
buf
),
"%s (%s)"
,
(
char
*
)
item
->
ModuleInfo
->
Body
.
Name
.
p
,
item
->
ModuleInfo
->
Body
.
OrderNumber
);
}
}
brow_SetAnnotation
(
node
,
1
,
buf
,
strlen
(
buf
));
...
...
@@ -2540,7 +2538,8 @@ int ItemPnSlot::scan( GsdmlAttrNav *attrnav, void *p)
ModuleItemRef
[
slotdata
->
module_enum_number
-
1
]
->
Body
.
ModuleItemTarget
.
p
;
if
(
!
mi
||
!
mi
->
ModuleInfo
->
Body
.
Name
.
p
)
return
1
;
strncpy
(
buf
,
(
char
*
)
mi
->
ModuleInfo
->
Body
.
Name
.
p
,
sizeof
(
buf
));
snprintf
(
buf
,
sizeof
(
buf
),
"%s (%s)"
,
(
char
*
)
mi
->
ModuleInfo
->
Body
.
Name
.
p
,
mi
->
ModuleInfo
->
Body
.
OrderNumber
);
}
brow_SetAnnotation
(
node
,
1
,
buf
,
strlen
(
buf
));
old_value
=
*
(
int
*
)
p
;
...
...
@@ -3480,7 +3479,7 @@ int ItemPnModuleType::open_children( GsdmlAttrNav *attrnav, double x, double y)
new
ItemPnEnumValueMType
(
attrnav
,
mname
,
mi
->
ModuleInfo
->
Body
.
OrderNumber
,
idx
,
pwr_eType_UInt32
,
&
attrnav
->
dev_data
.
slot_data
[
slot_idx
]
->
module_enum_number
,
node
,
flow_eDest_IntoLast
);
node
,
flow_eDest_IntoLast
,
(
char
*
)
mi
->
ModuleInfo
->
Body
.
InfoText
.
p
);
}
else
if
(
um
->
ModuleItemRef
[
i
]
->
Body
.
FixedInSlots
.
list
&&
um
->
ModuleItemRef
[
i
]
->
Body
.
FixedInSlots
.
list
->
in_list
(
slot_number
))
{
...
...
profibus/lib/cow/src/cow_pn_gsdml_attrnav.h
View file @
c949de84
...
...
@@ -286,9 +286,7 @@ class ItemPnEnumValue : public ItemPn {
class
ItemPnEnumValueMType
:
public
ItemPn
{
public:
ItemPnEnumValueMType
(
GsdmlAttrNav
*
attrnav
,
const
char
*
item_name
,
const
char
*
item_number
,
int
item_num
,
int
item_type_id
,
void
*
attr_value_p
,
brow_tNode
dest
,
flow_eDest
dest_code
);
int
item_num
,
int
item_type_id
,
void
*
attr_value_p
,
brow_tNode
dest
,
flow_eDest
dest_code
,
const
char
*
info_text
=
0
);
int
num
;
int
type_id
;
void
*
value_p
;
...
...
Write
Preview
Markdown
is supported
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