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
c6d05388
Commit
c6d05388
authored
Oct 04, 2010
by
Claes Sjofors
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
PlcPgm and Node, adopt and create methods added
parent
b320bcef
Changes
8
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
49 additions
and
1 deletion
+49
-1
src/msg/wb/src/wb_pwrb_msg.msg
src/msg/wb/src/wb_pwrb_msg.msg
+1
-0
src/msg/wb/src/wb_pwrs_msg.msg
src/msg/wb/src/wb_pwrs_msg.msg
+1
-0
src/wbl/pwrb/src/pwrb_c_plcpgm.wb_load
src/wbl/pwrb/src/pwrb_c_plcpgm.wb_load
+5
-0
src/wbl/pwrs/src/pwrs_c_attribute.wb_load
src/wbl/pwrs/src/pwrs_c_attribute.wb_load
+1
-1
src/wbl/pwrs/src/pwrs_c_classdef.wb_load
src/wbl/pwrs/src/pwrs_c_classdef.wb_load
+1
-0
src/wbl/pwrs/src/pwrs_c_node.wb_load
src/wbl/pwrs/src/pwrs_c_node.wb_load
+10
-0
wb/lib/wb/src/wb_c_node.cpp
wb/lib/wb/src/wb_c_node.cpp
+17
-0
wb/lib/wb/src/wb_c_plcpgm.cpp
wb/lib/wb/src/wb_c_plcpgm.cpp
+13
-0
No files found.
src/msg/wb/src/wb_pwrb_msg.msg
View file @
c6d05388
...
@@ -29,5 +29,6 @@ alochan <could not allocate a new channel> /error
...
@@ -29,5 +29,6 @@ alochan <could not allocate a new channel> /error
graphaction <no action defined in graph object> /error
graphaction <no action defined in graph object> /error
inlibhier <Object is in library hierarchy> /info
inlibhier <Object is in library hierarchy> /info
nobuilt <Nothing is built> /info
nobuilt <Nothing is built> /info
plcpgmchild <Object can not be a child to a PlcPgm> /error
src/msg/wb/src/wb_pwrs_msg.msg
View file @
c6d05388
...
@@ -47,6 +47,7 @@ moveattribute <an attribute object can only be moved within the same childhood>
...
@@ -47,6 +47,7 @@ moveattribute <an attribute object can only be moved within the same childhood>
movebody <a body object can only be moved within the same childhood> /error
movebody <a body object can only be moved within the same childhood> /error
possecurity <a Security object should be a child to a $Node object> /error
possecurity <a Security object should be a child to a $Node object> /error
securityalrex <a security object already exist> /error
securityalrex <a security object already exist> /error
nodealrex <a node object already exist> /error
...
...
src/wbl/pwrb/src/pwrb_c_plcpgm.wb_load
View file @
c6d05388
...
@@ -145,6 +145,11 @@ SObject pwrb:Class
...
@@ -145,6 +145,11 @@ SObject pwrb:Class
Attr MethodName = "PlcPgm-PostCreate"
Attr MethodName = "PlcPgm-PostCreate"
EndBody
EndBody
EndObject
EndObject
Object AnteAdopt $DbCallBack
Body SysBody
Attr MethodName = "PlcPgm-AnteAdopt"
EndBody
EndObject
Object NavigatorPosnn $Menu
Object NavigatorPosnn $Menu
Object Pointed $Menu
Object Pointed $Menu
Object OpenProgram $MenuButton
Object OpenProgram $MenuButton
...
...
src/wbl/pwrs/src/pwrs_c_attribute.wb_load
View file @
c6d05388
...
@@ -200,7 +200,7 @@ SObject pwrs:Class
...
@@ -200,7 +200,7 @@ SObject pwrs:Class
Attr Type = pwr_eType_TypeId
Attr Type = pwr_eType_TypeId
Attr Offset = 60
Attr Offset = 60
Attr Size = 4
Attr Size = 4
Attr Flags
= PWR_MASK_ALWAYS
WBL
Attr Flags
|= PWR_MASK_NO
WBL
Attr Flags |= PWR_MASK_INVISIBLE
Attr Flags |= PWR_MASK_INVISIBLE
Attr Flags |= PWR_MASK_RTHIDE
Attr Flags |= PWR_MASK_RTHIDE
Attr Elements = 1
Attr Elements = 1
...
...
src/wbl/pwrs/src/pwrs_c_classdef.wb_load
View file @
c6d05388
...
@@ -140,6 +140,7 @@ SObject pwrs:Class
...
@@ -140,6 +140,7 @@ SObject pwrs:Class
Attr Size = 4
Attr Size = 4
Attr Flags = PWR_MASK_INVISIBLE
Attr Flags = PWR_MASK_INVISIBLE
Attr Flags |= PWR_MASK_RTHIDE
Attr Flags |= PWR_MASK_RTHIDE
Attr Flags |= PWR_MASK_NOWBL
Attr Elements = 1
Attr Elements = 1
Attr ParamIndex = 6
Attr ParamIndex = 6
Attr TypeRef = pwr_eType_Int32
Attr TypeRef = pwr_eType_Int32
...
...
src/wbl/pwrs/src/pwrs_c_node.wb_load
View file @
c6d05388
...
@@ -283,6 +283,16 @@ SObject pwrs:Class
...
@@ -283,6 +283,16 @@ SObject pwrs:Class
Attr MethodName = "$Node-PostCreate"
Attr MethodName = "$Node-PostCreate"
EndBody
EndBody
EndObject
EndObject
Object AnteCreate $DbCallBack
Body SysBody
Attr MethodName = "$Node-AnteCreate"
EndBody
EndObject
Object PostCreate $DbCallBack
Body SysBody
Attr MethodName = "$Node-PostCreate"
EndBody
EndObject
Object NavigatorPosnn $Menu
Object NavigatorPosnn $Menu
Object Pointed $Menu
Object Pointed $Menu
Object Build $MenuButton
Object Build $MenuButton
...
...
wb/lib/wb/src/wb_c_node.cpp
View file @
c6d05388
...
@@ -127,8 +127,25 @@ static pwr_tStatus SyntaxCheck (
...
@@ -127,8 +127,25 @@ static pwr_tStatus SyntaxCheck (
return
PWRB__SUCCESS
;
return
PWRB__SUCCESS
;
}
}
static
pwr_tStatus
AnteCreate
(
ldh_tSesContext
Session
,
pwr_tObjid
Father
,
pwr_tClassId
Class
)
{
pwr_tStatus
sts
;
pwr_tOid
oid
;
// There should only be one node object
sts
=
ldh_GetClassList
(
Session
,
pwr_eClass_Node
,
&
oid
);
if
(
ODD
(
sts
))
return
PWRS__NODEALREX
;
return
PWRS__SUCCESS
;
}
pwr_dExport
pwr_BindMethods
(
$
Node
)
=
{
pwr_dExport
pwr_BindMethods
(
$
Node
)
=
{
pwr_BindMethod
(
PostCreate
),
pwr_BindMethod
(
PostCreate
),
pwr_BindMethod
(
AnteCreate
),
pwr_BindMethod
(
SyntaxCheck
),
pwr_BindMethod
(
SyntaxCheck
),
pwr_NullMethod
pwr_NullMethod
};
};
...
...
wb/lib/wb/src/wb_c_plcpgm.cpp
View file @
c6d05388
...
@@ -174,6 +174,18 @@ static pwr_tStatus PostCreate (
...
@@ -174,6 +174,18 @@ static pwr_tStatus PostCreate (
}
}
return
PWRB__SUCCESS
;
return
PWRB__SUCCESS
;
}
}
static
pwr_tStatus
AnteAdopt
(
ldh_tSesContext
Session
,
pwr_tOid
Father
,
pwr_tCid
Class
)
{
// Only allow plc window objects
if
(
Class
!=
pwr_cClass_windowplc
)
return
PWRB__PLCPGMCHILD
;
return
PWRB__SUCCESS
;
}
/*----------------------------------------------------------------------------*\
/*----------------------------------------------------------------------------*\
Every method to be exported to the workbench should be registred here.
Every method to be exported to the workbench should be registred here.
...
@@ -184,5 +196,6 @@ pwr_dExport pwr_BindMethods(PlcPgm) = {
...
@@ -184,5 +196,6 @@ pwr_dExport pwr_BindMethods(PlcPgm) = {
pwr_BindMethod
(
Build
),
pwr_BindMethod
(
Build
),
pwr_BindMethod
(
SyntaxCheck
),
pwr_BindMethod
(
SyntaxCheck
),
pwr_BindMethod
(
PostCreate
),
pwr_BindMethod
(
PostCreate
),
pwr_BindMethod
(
AnteAdopt
),
pwr_NullMethod
pwr_NullMethod
};
};
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