You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Aug 31, 2021. It is now read-only.
@@ -5109,6 +5111,27 @@ private on __setPropertyOfObject pObject, pProperty, pValue
5109
5111
5110
5112
end__setPropertyOfObject
5111
5113
5114
+
functionideCheckStackName pName
5115
+
ifchar1to3ofpNameis"rev"then
5116
+
answer warning revIDELocalise("Using rev in the first three characters of a stack name is reserved for use by the LiveCode development environment and advanced users creating Plug-ins. If you use these characters, your stack may not behave as expected.") with revIDELocalise("OK") and revIDELocalise("Cancel")
5117
+
ifitis revIDELocalise("Cancel") then
5118
+
return false
5119
+
end if
5120
+
end if
5121
+
ifpNameis anumberthen
5122
+
beep
5123
+
answer error revIDELocalise("You cannot set the name of a stack to a number.")
5124
+
return false
5125
+
end if
5126
+
ifpNamecontainsquotethen
5127
+
beep
5128
+
answer error revIDELocalise("The name of the stack cannot contain quotes")
@@ -5130,27 +5153,14 @@ on revIDEPropertySet pObjectList, pProperty, pValue, pLockUpdates
5130
5153
5131
5154
# If stack name is changed, use new name when setting edited
5132
5155
iftStackistObjectandpPropertyis"name"then
5133
-
localtOldName
5134
-
puttheshort name oftStackintotOldName
5135
-
ifchar1to3ofpValueis"rev"then
5136
-
answer warning revIDELocalise("Using rev in the first three characters of a stack name is reserved for use by the LiveCode development environment and advanced users creating Plug-ins. If you use these characters, your stack may not behave as expected.") with revIDELocalise("OK") and revIDELocalise("Cancel")
5137
-
ifitis revIDELocalise("Cancel") then
5138
-
setthe name oftStacktotOldName
5139
-
exit revIDEPropertySet
5140
-
end if
5141
-
end if
5142
-
ifpValueis anumberthen
5143
-
beep
5144
-
answer error revIDELocalise("You cannot set the name of a stack to a number.")
5145
-
setthe name oftStacktotOldName
5146
-
exit revIDEPropertySet
5147
-
end if
5148
-
ifpValuecontainsquotethen
5149
-
beep
5150
-
answer error revIDELocalise("The name of the stack cannot contain quotes")
0 commit comments