Subversion Repositories DevTools

Rev

Rev 6827 | Rev 7003 | Go to most recent revision | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
129 ghuddy 1
<!-- #INCLUDE FILE="..\common\adovbs.inc" -->
119 ghuddy 2
<%
3
'=============================================================
4
'//
127 ghuddy 5
'//                  Action Button Control
119 ghuddy 6
'//
7
'=============================================================
8
%>
9
<%
10
'--------------- Global Constants ----------------
11
Const enumABTNCTRL_ON_READONLY_HIDE = 1
12
Const enumABTNCTRL_ON_READONLY_DISABLE = 2
13
'-------------------------------------------------
14
 
15
Class ActionButtonControl
127 ghuddy 16
 
17
   Private mArrAbtnDef()
18
   Private mobjNameDefMap        ' Item can be accesed by name. Must be unique within one page
19
   Private mobjIdDefMap          ' Item can be accesed by id. Must be unique within one page. If NULL, ubound is assigned to it
20
   Private mobjSeparator         ' Has a name of item after separator is applied
21
   Private mobjACActionsMap      ' Map of buttons to actions from access control
22
 
23
   Private mnButtonSpacer
24
   Private mnImageHspace
25
 
26
   Private mNumOfProperties
27
   Private mLastPropertyInx
28
 
29
   Private mbDisableAll
30
 
31
   Private mbIsReadonly
4083 dpurdie 32
   Private mbIsClosed
127 ghuddy 33
   Private mReadonlyActionBehaviour
34
 
35
   Private InxID
36
   Private InxName
37
   Private InxTxt
38
   Private InxLink
39
   Private InxEventHandler
40
   Private InxImg
41
   Private InxImgOff
42
   Private InxHint
43
   Private InxVisible
44
   Private InxActive
45
   Private InxIsReadonlyAction
4083 dpurdie 46
   Private InxHideOnClosed
127 ghuddy 47
 
48
 
49
   Public Property Let AllActive ( cActive )
50
      If cActive = enumDB_NO Then
51
         mbDisableAll = TRUE
52
      Else
53
         mbDisableAll = FALSE
54
      End If
55
 
56
   End Property
57
 
58
   Public Property Let ButtonSpacer ( nWidth )
59
      mnButtonSpacer = nWidth
60
   End Property
61
 
62
   Public Property Let ImageHspace ( nWidth )
63
      mnImageHspace = nWidth
64
   End Property
65
 
66
   Public Property Let IsReadonlyAction ( IsReadonly )
67
      If IsReadonly = enumDB_YES Then
68
         mbIsReadonly = TRUE
69
 
70
      ElseIf IsReadonly = enumDB_NO Then
71
         mbIsReadonly = FALSE
72
      Else
73
         mbIsReadonly = IsReadonly
74
      End If
4083 dpurdie 75
   End Property
127 ghuddy 76
 
4083 dpurdie 77
   Public Property Let setClosed ( isClosed )
78
      mbIsClosed = isClosed
127 ghuddy 79
   End Property
4083 dpurdie 80
 
127 ghuddy 81
   Public Property Let ReadonlyActionBehaviour ( nEnum )
82
      mReadonlyActionBehaviour = nEnum
83
   End Property
84
 
85
   '-----------------------------------------------------------------------------------------------------------------
86
   Public Sub SetRelationship ( sButtonName, sActionName )
87
      Call mobjACActionsMap.Add ( sButtonName, sActionName )
88
   End Sub
89
   '-----------------------------------------------------------------------------------------------------------------
90
   Private Sub SetItemPropertyByIndex ( nInx, nProperty, Value )
91
      If nInx = "" Then Exit Sub   ' Exit sub if you don't find defined button
92
 
93
      If nProperty = ""  OR  Value = "" Then Err.Raise 8, "Method SetItemPropertyByIndex", "Empty parameters found. nInx="& nInx &", nProperty="& nProperty &", Value="& Value
94
 
95
      mArrAbtnDef ( nProperty, nInx ) = Value
96
 
97
      'Response.write "mArrAbtnDef ( "& nProperty &", "& nInx &" ) = "& Value &"<br>"
98
   End Sub
99
   '-----------------------------------------------------------------------------------------------------------------
143 ghuddy 100
   Private Function GetItemPropertyByIndex ( nInx, nProperty )
101
      GetItemPropertyByIndex = ""
102
      If nInx = "" Then Exit Function   ' Exit sub if you don't find defined button
103
 
104
      If nProperty = ""  Then Err.Raise 8, "Method GetItemPropertyByIndex", "Empty parameters found. nInx="& nInx &", nProperty="& nProperty
105
 
106
      GetItemPropertyByIndex = Cstr(mArrAbtnDef ( nProperty, nInx ))
107
   End Function
108
   '-----------------------------------------------------------------------------------------------------------------
127 ghuddy 109
   Private Function LastItemInx ()
110
       LastItemInx = UBound ( mArrAbtnDef, 2 )
111
   End Function
112
   '-----------------------------------------------------------------------------------------------------------------
113
   Public Sub AddActionButton ( sItemName, nItemID )
114
      Dim newArrayDim
115
 
116
      If InStr( sItemName, " " ) > 0 Then   Err.Raise 8, "Method AddActionButton", "Item Name '"& sItemName &"' cannot have spaces."
117
 
118
 
119
 
120
      If NOT mobjNameDefMap.Exists (CStr( sItemName )) Then
121
 
122
         newArrayDim = LastItemInx() + 1
123
 
124
         ReDim Preserve mArrAbtnDef( mNumOfProperties, newArrayDim )
125
 
126
         ' Store name
127
         Call SetItemPropertyByIndex ( newArrayDim, InxName, sItemName )
128
         mobjNameDefMap.Add Cstr( sItemName ), CStr( newArrayDim )
129
 
130
         If Not IsNull(nItemID) Then
131
            ' Store ID
132
            Call SetItemPropertyByIndex ( newArrayDim, InxdbID, nItemID )
133
            mobjIdDefMap.Add Cstr( nItemID ), CStr( newArrayDim )
134
         End If
135
 
136
         ' Set Defaults
137
         Call SetItemDefaults ( sItemName )
138
      Else
139
 
140
         Err.Raise 8, "Method AddActionButton", "Item Name '"& sItemName &"' has been already defined."
141
 
142
      End If
143
 
144
   End Sub
145
   '-----------------------------------------------------------------------------------------------------------------
146
   Public Sub Render ( aAbtnList, ByRef oAccessControl )
147
      Dim itemInx, itemName, nLastItemInx, btnImage, ButtonStr, ButtonStrDisabled, bIsVisibleAC, bIsActiveAC
6873 dpurdie 148
      Response.write "<table cellpadding='0' cellspacing='0' width='1' ><tr>"
127 ghuddy 149
 
150
      For Each itemName in aAbtnList
151
         itemInx = mobjNameDefMap.Item (Cstr(itemName))
152
 
153
         '-- Define Image
154
         btnImage = "<img src='images/spacer.gif' width='"& mnButtonSpacer &"' height='1' align='absmiddle' border='0'>"
155
         If (mArrAbtnDef( InxImg, itemInx ) <> "") Then
156
            btnImage = "<img src='"& mArrAbtnDef( InxImg, itemInx ) &"' hspace='"& mnImageHspace &"' border='0' align='absmiddle'>"
157
         End If
158
 
159
         '-- Define Button
5190 dpurdie 160
         '-- Two forms
161
         '--    Starts with "vixConfirm - Generate confirmation dialog with url
162
         '--    Else 'eval' and use in raw form
163
         Dim uhref,uevent
164
         uhref = Eval( mArrAbtnDef( InxLink, itemInx ) )
165
         uevent = Eval( mArrAbtnDef( InxEventHandler, itemInx ) )
166
         If InStr( uevent, "vixConfirm" ) = 1 Then
167
            uevent = Replace(uevent, "HREF", uhref )
168
            uevent = "onclick=""" & uevent & """"
169
            uhref = "javascript:;"
170
         End If
6827 dpurdie 171
         Dim hint: hint = mArrAbtnDef( InxHint, itemInx )
172
         If uhref = "javascript:;" Then
173
             ButtonStr = _
174
                "<td nowrap>"&_
175
                "<span id='"& mArrAbtnDef( InxName, itemInx ) &"' "&_
176
                " "& uevent &" class='menu_link' title='"& hint &"'>" &_
177
                btnImage & mArrAbtnDef( InxTxt, itemInx ) &"<span>"&_
178
                "</td>"
179
         Else
180
             ButtonStr = _
181
                "<td nowrap>"&_
182
                "<a id='"& mArrAbtnDef( InxName, itemInx ) &"' "&_
183
                " name='"& mArrAbtnDef( InxName, itemInx ) &"' href='"& uhref &"' "&_
184
                " "& uevent &" class='menu_link' title='"& hint &"'>"&_
185
                btnImage & mArrAbtnDef( InxTxt, itemInx ) &"</a>"&_
186
                "</td>"
187
         End If
127 ghuddy 188
 
5814 dpurdie 189
			'-- Define Disabled Button
190
            '   A Null value of '' will use InxImg with the lessOpacity Class
6176 dpurdie 191
            hint = hint & " [Disabled]" 
5814 dpurdie 192
            If IsNull(mArrAbtnDef( InxImgOff, itemInx )) Then
193
                ButtonStrDisabled = _
194
                    "<td nowrap>"&_
6176 dpurdie 195
                    "<img src='"& mArrAbtnDef( InxImg, itemInx ) &"' hspace='2' border='0' align='absmiddle' class='lessOpacity' title='"&hint&"'>"&_
5814 dpurdie 196
                    "<label class='menu_txt'>"& mArrAbtnDef( InxTxt, itemInx ) &"</label>"&_
197
                    "</td>"
198
            Else
199
                ButtonStrDisabled = _
200
                    "<td nowrap>"&_
6176 dpurdie 201
                    "<img src='"& mArrAbtnDef( InxImgOff, itemInx ) &"' hspace='2' border='0' align='absmiddle' title='"&hint&"'>"&_
5814 dpurdie 202
                    "<label class='menu_txt'>"& mArrAbtnDef( InxTxt, itemInx ) &"</label>"&_
203
                    "</td>"
204
            End If
127 ghuddy 205
 
206
 
207
         '-- Get Access Control permissions --
208
         bIsVisibleAC = TRUE
209
         bIsActiveAC = TRUE
210
         If NOT IsNull( oAccessControl ) Then
211
            ' Access control object is supplied
212
 
213
            If mobjACActionsMap.Exists ( itemName ) Then
214
               ' Relationship supplied
215
               bIsVisibleAC = oAccessControl.IsVisible ( mobjACActionsMap.Item( itemName ) )
216
               bIsActiveAC = oAccessControl.IsActive ( mobjACActionsMap.Item( itemName ) )
143 ghuddy 217
               'Response.write "<br>" & itemName &":"& bIsVisibleAC &"-"& bIsActiveAC
127 ghuddy 218
            End If
219
 
220
         End If
221
 
4670 dpurdie 222
         ' Hide Buttons on closed (Release is closed, or archived)
4083 dpurdie 223
         If mbIsClosed AND (mArrAbtnDef( InxHideOnClosed, itemInx ) = enumDB_YES) Then
224
            bIsVisibleAC = FALSE
225
         End If
127 ghuddy 226
 
4670 dpurdie 227
         ' Debug
228
         'Response.write "<br>Render["&itemInx &"](V:"&itemName &","&_
229
         '   mArrAbtnDef( InxVisible, itemInx )&":" &bIsVisibleAC & ",A:"&_
230
         '   mArrAbtnDef( InxActive, itemInx ) &":" &bIsActiveAC  & ")"
231
 
232
         ' Button 
233
         '      is visible AND to be shown
234
         ' OR   isa width specification
235
         ' OR   isa height specification
236
         '
127 ghuddy 237
         If (  ( mArrAbtnDef( InxVisible, itemInx ) = enumDB_YES)   AND   bIsVisibleAC   ) _
238
            OR  (InStr( itemName, "width=" ) > 0)  _
239
            OR  (InStr( itemName, "height=" ) > 0) Then
240
            ' --- Display if Visible ---
241
 
242
            'AND  (NOT bIsActiveAC)
243
            '( mbDisableAll OR (  mArrAbtnDef( InxActive, itemInx ) = enumDB_NO )     )   AND ( itemInx <> "" )
244
            'Response.write itemName &":"& mbDisableAll &"-"& Eval( mArrAbtnDef( InxActive, itemInx ) = enumDB_NO ) &"-"& Eval( NOT bIsActiveAC ) &"-"& itemInx &"<br>"
245
            If  ( itemInx <> "" ) AND _
246
               ( mbDisableAll  OR _
247
                  (  ( mArrAbtnDef( InxActive, itemInx ) = enumDB_NO )  OR  (NOT bIsActiveAC)  ) _
248
               ) _
249
            Then
143 ghuddy 250
               'Response.Write "<br>"&itemName&" is disabled," & itemInx & "," & mbDisableAll & "," & mArrAbtnDef( InxActive, itemInx ) & "," & mArrAbtnDef( InxVisible, itemInx )
127 ghuddy 251
 
252
               ' --- Display DISABLED Button Item ---
253
               Response.write ButtonStrDisabled
254
 
255
               If mnButtonSpacer > 0 Then
256
                  Response.write "<td><img src='images/spacer.gif' width='"& mnButtonSpacer &"' height='1' align='absmiddle'></td>"
257
               End If
258
 
259
            Else
260
 
261
               ' --- Display Action Button Item ---
262
               If   ( NOT mbIsReadonly )  OR _
263
                     ( mbIsReadonly  AND  mArrAbtnDef( InxIsReadonlyAction, itemInx ) = enumDB_YES ) Then
264
 
265
                  If InStr( itemName, "width=" ) > 0 Then
266
                     Response.write "<td><img src='images/spacer.gif' "& itemName &" height='1' align='absmiddle'></td>"
267
 
268
                  ElseIf InStr( itemName, "height=" ) > 0 Then
269
                     Response.write "<td><img src='images/bg_bage_2.gif' width='1' "& itemName &" align='absmiddle' hspace='4'></td>"
270
 
271
                  Else
272
                     '/* It is a button, i.e. Display Button */
273
 
274
                     ' Check if button is loaded from Database
275
                     If itemInx = "" Then    Err.Raise 8, "Method Render", "Definition for item name '"& itemName &"' not found."
276
 
277
                     Response.write ButtonStr
143 ghuddy 278
                     'Response.Write "<br>"&itemName&" is enabled"
127 ghuddy 279
 
280
                     If mnButtonSpacer > 0 Then
281
                        Response.write "<td><img src='images/spacer.gif' width='"& mnButtonSpacer &"' height='1' align='absmiddle'></td>"
282
                     End If
283
 
284
                  End If
285
 
286
               ElseIf ( mbIsReadonly  AND  mArrAbtnDef( InxIsReadonlyAction, itemInx ) = enumDB_NO ) Then
287
 
288
                  If mReadonlyActionBehaviour = enumABTNCTRL_ON_READONLY_DISABLE Then
289
                     Response.write ButtonStrDisabled
290
                  End If
291
 
292
               End If
293
 
294
            End If
295
 
296
         End If
297
 
298
         ' --- Separators added manually using  method AddSeparator or AddSeparatorAfter ---
299
         If mobjSeparator.Exists ( Cstr(mArrAbtnDef( InxName, itemInx )) ) Then
300
            Response.write "<td><img src='images/spacer.gif' width='"& mobjSeparator.Item ( Cstr(mArrAbtnDef( InxName, itemInx )) ) &"' height='1'></td>"
301
         End If
302
 
303
 
304
      Next
305
 
306
      Response.write "</tr></table>"
307
   End Sub
143 ghuddy 308
   '-----------------------------------------------------------------------------------------------------------------
127 ghuddy 309
   ' Return true if required_abtnName is one of the strings in the aAbtnList string array, else return false
310
   Private Function isAbtnRequired (aAbtnList, required_abtnName)
311
      Dim this_abtnName
312
 
313
      isAbtnRequired = FALSE
314
 
315
      For Each this_abtnName in aAbtnList
316
         If 0 = StrComp(this_abtnName, required_abtnName) Then
317
            isAbtnRequired = TRUE
318
            Exit Function
319
         End If
320
      Next
321
   End Function
322
   '-----------------------------------------------------------------------------------------------------------------
323
   Public Sub LoadActionButtons ( aAbtnList, ByRef objOraDatabase )
324
 
325
      ' The following code is now used in place of the earlier code to acquire action button records.
326
      '
327
      ' This code exploits the fact that in ADO 2.8 onwards, you can create ADO DB record sets
328
      ' without a connection to an actual database. So, to rid ourselves of the need for a DEF_ACTION_BUTTONS
329
      ' table in the database, we can simply take all of the table's rows and reproduce them here in row
330
      ' creation and field assignment statements. The rest of the website code will be ignorant of the fact
331
      ' that the data has not come from the actual database.
332
      '
333
      ' Complicating factors:
334
      ' 1) Some action button fields (action_link and event_handler) are to be EVAL'ed later on when used
335
      '    to render the HTML page. This can lead to some very complex looking strings that are difficult to
336
      '    understand. EVAL allows things like parRtag_id used in a string to be converted to an actual
337
      '    number (in string form) at time of HTML rendering. We have to use EVAL. There is no other option.
338
      '
339
      ' 2) The strings from the database must also be represented as VBScript strings in the assignments
340
      '    below. This means that where a string needs to have an embedded " char, two such chars must be
341
      '    used, and remember about EVAL mentioned above, meaning that sometimes """" has to be used to
342
      '    give a single " to the resulting string that pops out from EVAL.
343
      '    Remember also that whilst HTML doesn't care whether you use single or double quotes, javascript
344
      '    does (it must use single quotes) and VBScript does (it must use double quotes)
345
      '
346
      ' Possible Future Roadmap
347
      ' 1) Rid the code of ABTN_ID - I dont think we need this field now that we are free of the database
348
      '
349
      '
350
      Dim rsQry
351
      Dim varFields
352
      Dim varValues
353
 
354
      ' Create the object and configure some of its properties
355
      Set rsQry = Server.CreateObject("ADODB.Recordset")
356
      rsQry.CursorLocation = adUseClient
357
      rsQry.CursorType = adOpenKeyset
358
      rsQry.LockType = adLockOptimistic
359
 
360
      ' Based upon the original DEF_ACTION_BUTTONS table DDL, define the fields (ie. table columns) being simulated
361
      rsQry.Fields.Append "ABTN_ID",               adInteger
362
      rsQry.Fields.Append "ABTN_NAME",             adVarChar,   64
363
      rsQry.Fields.Append "TEXT",                  adVarChar,  128, adFldIsNullable
364
      rsQry.Fields.Append "ACTION_LINK",           adVarChar,  512, adFldIsNullable
365
      rsQry.Fields.Append "EVENT_HANDLER",         adVarChar,  512, adFldIsNullable
366
      rsQry.Fields.Append "IMG_ENABLED",           adVarChar,  128, adFldIsNullable
367
      rsQry.Fields.Append "IMG_DISABLED",          adVarChar,  128, adFldIsNullable
368
      rsQry.Fields.Append "HINT",                  adVarChar,  256, adFldIsNullable
369
      rsQry.Fields.Append "VISIBLE",               adChar,       1
370
      rsQry.Fields.Append "ACTIVE",                adChar,       1
371
      rsQry.Fields.Append "IS_READONLY_ACTION",    adChar,       1
4083 dpurdie 372
      rsQry.Fields.Append "HIDE_ON_CLOSED",        adChar,       1
127 ghuddy 373
 
374
      ' open the record set for updating
375
      rsQry.Open
376
 
377
      ' Specify the field order that we are going to use in our row creation statements
378
      varFields = Array("ABTN_ID", "ABTN_NAME", "TEXT",_
379
                        "ACTION_LINK",_
380
                        "EVENT_HANDLER",_
381
                        "IMG_ENABLED",_
382
                        "IMG_DISABLED",_
383
                        "HINT",_
384
                        "VISIBLE",_
385
                        "ACTIVE",_
4083 dpurdie 386
                        "IS_READONLY_ACTION",_
387
                        "HIDE_ON_CLOSED")
127 ghuddy 388
 
389
      ' Add the rows to the record set, but only for buttons specifed in the list supplied by the caller
390
 
391
      ' Remember, Field Ordering is... ID, name, text, link, event handler, en-img, dis-img, hint, visible, active, is readonly action
392
 
393
      If isAbtnRequired(aAbtnList, "btnNewVersion") Then
394
         varValues = Array( 1, "btnNewVersion", null,_
395
                           """form_new_version.asp?""& objPMod.ComposeURL()",_
396
                           null,_
397
                           "images/abtn_new_version.gif",_
4671 dpurdie 398
                           "images/abtn_new_version_off.gif",_
127 ghuddy 399
                           "Create new version of this package.",_
400
                           "Y",_
401
                           "Y",_
4083 dpurdie 402
                           "N",_
127 ghuddy 403
                           "N")
404
         rsQry.AddNew varFields, varValues
405
      End If
406
 
407
      If isAbtnRequired(aAbtnList, "btnVersionHistory") Then
408
         varValues = Array( 2, "btnVersionHistory", null,_
409
                           """javascript:;""",_
5933 dpurdie 410
                           """onClick=""""MM_openBrWindow('_wform_versions_history_release_notes.asp?OLDpv_id=""& parPv_id &""&pkg_id=""& pkgInfoHash.Item (""pkg_id"") &""&FLpkg_version=*""& pkgInfoHash.Item(""v_ext"") &""&FLuser_name=*&rfile=""& scriptName &""&""& objPMod.ComposeURL() &""','History','resizable=yes,scrollbars=yes,width=1000,height='+ ( screen.height - 100 )  );""""""",_
127 ghuddy 411
                           "images/abtn_version_history.gif",_
412
                           null,_
413
                           "Show version history of this package.",_
414
                           "Y",_
415
                           "Y",_
4083 dpurdie 416
                           "Y",_
417
                           "N")
127 ghuddy 418
         rsQry.AddNew varFields, varValues
419
      End If
420
 
421
      If isAbtnRequired(aAbtnList, "btnRemovePackage") Then
422
         varValues = Array( 3, "btnRemovePackage", null,_
423
                           """_remove_package.asp?pv_id=""& parPv_id &""&rtag_id=""& parRtag_id ",_
5190 dpurdie 424
                           """vixConfirm('Remove this package from this release.',{title:'Remove Package', button:'Remove', url: 'HREF'});""",_
127 ghuddy 425
                           "images/abtn_remove_pkg.gif",_
4670 dpurdie 426
                           "images/abtn_remove_pkg_off.gif",_
427
                           "Remove the package-version from this Release.",_
127 ghuddy 428
                           "Y",_
429
                           "Y",_
4083 dpurdie 430
                           "N",_
127 ghuddy 431
                           "N")
432
         rsQry.AddNew varFields, varValues
433
      End If
434
 
435
      If isAbtnRequired(aAbtnList, "btnMakeRelease") Then
436
         varValues = Array( 4, "btnMakeRelease", null,_
437
                           """_make_released.asp?rfile=""& ScriptName &""&pv_id=""& parPv_id &""&rtag_id=""& parRtag_id ",_
5190 dpurdie 438
                           """vixConfirm('Making this package released will prevent any further changes',{title:'Make Release', button:'Release', url: 'HREF'});""""""",_
127 ghuddy 439
                           "icons/i_make_released.gif",_
440
                           "icons/i_make_released_off.gif",_
441
                           "Make this package released, so that other packages can use it.",_
442
                           "Y",_
443
                           "Y",_
4083 dpurdie 444
                           "N",_
127 ghuddy 445
                           "N")
446
         rsQry.AddNew varFields, varValues
447
      End If
448
 
449
      If isAbtnRequired(aAbtnList, "btnMakeUnrelease") Then
450
         varValues = Array( 5, "btnMakeUnrelease", null,_
451
                           """_make_unreleased.asp?rfile=""& ScriptName &""&pv_id=""& parPv_id &""&rtag_id=""& parRtag_id ",_
5190 dpurdie 452
                           """vixConfirm('You are going to unrelease this package.',{title:'Make UnRelease', button:'UnRelease', url: 'HREF'});""""""",_
127 ghuddy 453
                           "icons/i_make_unreleased.gif",_
454
                           "icons/i_make_unreleased_off.gif",_
183 brianf 455
                           "Unrelease this package.",_
127 ghuddy 456
                           "Y",_
457
                           "Y",_
4083 dpurdie 458
                           "N",_
127 ghuddy 459
                           "N")
460
         rsQry.AddNew varFields, varValues
461
      End If
462
 
463
      If isAbtnRequired(aAbtnList, "btnMakePending") Then
464
         varValues = Array( 6, "btnMakePending", null,_
465
                           """_make_pending.asp?rfile=""& ScriptName &""&pv_id=""& parPv_id &""&rtag_id=""& parRtag_id ",_
5190 dpurdie 466
                           """vixConfirm('Making this package pending will prevent any further changes.',{title:'Make Pending', button:'Pending', url: 'HREF'});""""""",_
127 ghuddy 467
                           "icons/i_make_pending.gif",_
468
                           "icons/i_make_pending_off.gif",_
469
                           "Make this package pending for build/release.",_
470
                           "Y",_
471
                           "Y",_
4083 dpurdie 472
                           "N",_
127 ghuddy 473
                           "N")
474
         rsQry.AddNew varFields, varValues
475
      End If
476
 
477
      If isAbtnRequired(aAbtnList, "btnRejectPackage") Then
478
         varValues = Array( 7, "btnRejectPackage", null,_
479
                           """_make_rejected.asp?rfile=""& ScriptName &""&pv_id=""& parPv_id &""&rtag_id=""& parRtag_id ",_
5190 dpurdie 480
                           """vixConfirm('Rejecting a new package version will move it to Work-In-Progress.<br>Rejecting a merge package version will simply remove it from pending.',{title:'Reject Package', button:'Reject', url: 'HREF'});""""""",_
127 ghuddy 481
                           "icons/i_reject_pending.gif",_
482
                           "icons/i_reject_pending_off.gif",_
483
                           "Reject this package from Pending.",_
484
                           "Y",_
485
                           "Y",_
4083 dpurdie 486
                           "N",_
127 ghuddy 487
                           "N")
488
         rsQry.AddNew varFields, varValues
489
      End If
490
 
491
      If isAbtnRequired(aAbtnList, "btnMoveToView") Then
492
         varValues = Array( 8, "btnMoveToView", null,_
493
                           """javascript:;""",_
6579 dpurdie 494
                           """onClick=""""MM_openVixIFrame('_wform_change_group.asp?""& objPMod.ComposeURL() &""','Set Package Base View');""""""",_
127 ghuddy 495
                           "images/abtn_move_package.gif",_
4670 dpurdie 496
                           "images/abtn_move_package_off.gif",_
127 ghuddy 497
                           "Move this package to different Base View (Group).",_
498
                           "Y",_
499
                           "Y",_
4083 dpurdie 500
                           "N",_
127 ghuddy 501
                           "N")
502
         rsQry.AddNew varFields, varValues
503
      End If
504
 
505
      If isAbtnRequired(aAbtnList, "btnReversionPackage") Then
506
         varValues = Array( 9, "btnReversionPackage", null,_
507
                           """javascript:;""",_
5590 dpurdie 508
                           """onClick=""""MM_openVixIFrame('_wform_rename_version.asp?renameMode=1&rfile=""& ScriptName & objPMod.ComposeURLWithout(""rfile"") &""','Rename Version Number');""""""",_
127 ghuddy 509
                           "images/abtn_rename_version.gif",_
510
                           "images/abtn_rename_version_off.gif",_
511
                           "Reversion this package.",_
512
                           "Y",_
513
                           "Y",_
6176 dpurdie 514
                           "Y",_
4199 dpurdie 515
                           "N")
127 ghuddy 516
         rsQry.AddNew varFields, varValues
517
      End If
518
 
519
      If isAbtnRequired(aAbtnList, "btnStickyNotes") Then
520
         varValues = Array(10, "btnStickyNotes", null,_
521
                           """javascript:;""",_
522
                           """onClick=""""showHideNote();""""""",_
523
                           "notemanager/images/note.gif",_
524
                           null,_
525
                           "Sticky notes",_
526
                           "Y",_
527
                           "Y",_
4083 dpurdie 528
                           "N",_
127 ghuddy 529
                           "N")
530
         rsQry.AddNew varFields, varValues
531
      End If
532
 
533
      If isAbtnRequired(aAbtnList, "btnObsoletePatch") Then
534
         varValues = Array(11, "btnObsoletePatch", null,_
535
                           """javascript:;""",_
5590 dpurdie 536
                           """onClick=""""MM_openVixIFrame('_wform_obsolete_patch.asp?rfile=""& ScriptName &""&""& objPMod.ComposeURL() &""','Make Patch Obsolete');""""""",_
127 ghuddy 537
                           "images/abtn_obsolete_patch.gif",_
538
                           "images/abtn_obsolete_patch_off.gif",_
539
                           "Make this patch obsolete.",_
540
                           "Y",_
541
                           "Y",_
4083 dpurdie 542
                           "N",_
127 ghuddy 543
                           "N")
544
         rsQry.AddNew varFields, varValues
545
      End If
546
 
547
      If isAbtnRequired(aAbtnList, "btnUnobsoletePatch") Then
548
         varValues = Array(12, "btnUnobsoletePatch", null,_
549
                           """javascript:;""",_
5590 dpurdie 550
                           """onClick=""""MM_openVixIFrame('_wform_obsolete_patch.asp?action=true&unobsolete=true&rfile=""& ScriptName &""&""& objPMod.ComposeURL() &""','UnObsolete Patch');""""""",_
127 ghuddy 551
                           "images/abtn_unobsolete_patch.gif",_
552
                           null,_
553
                           "Undo patch obsolete.",_
554
                           "Y",_
555
                           "Y",_
4083 dpurdie 556
                           "N",_
127 ghuddy 557
                           "N")
558
         rsQry.AddNew varFields, varValues
559
      End If
560
 
561
      If isAbtnRequired(aAbtnList, "btnApprovePackage") Then
562
         varValues = Array(13, "btnApprovePackage", null,_
563
                           """_make_approved.asp?rfile=""& ScriptName &""&pv_id=""& parPv_id &""&rtag_id=""& parRtag_id ",_
5190 dpurdie 564
                           """vixConfirm('Approve this package for auto-build.',{title:'Approve Package', button:'Approve', url: 'HREF'});""""""",_
3959 dpurdie 565
                           "icons/i_submit_build.gif",_
566
                           "icons/i_submit_build_off.gif",_
127 ghuddy 567
                           "Make this package released for automated build.",_
568
                           "Y",_
569
                           "Y",_
4083 dpurdie 570
                           "N",_
127 ghuddy 571
                           "N")
572
         rsQry.AddNew varFields, varValues
573
      End If
574
 
575
      If isAbtnRequired(aAbtnList, "btnNewRelease") Then
576
         varValues = Array(14, "btnNewRelease", null,_
6508 dpurdie 577
                           """new_release.asp?" & objPMod.ComposeURL() &"""",_
127 ghuddy 578
                           null,_
579
                           "images/abtn_new_release.gif",_
580
                           "images/abtn_new_release_off.gif",_
581
                           "Create new release...",_
582
                           "Y",_
583
                           "Y",_
4083 dpurdie 584
                           "N",_
127 ghuddy 585
                           "N")
586
         rsQry.AddNew varFields, varValues
587
      End If
588
 
589
      If isAbtnRequired(aAbtnList, "btnEditRelease") Then
590
         varValues = Array(15, "btnEditRelease", null,_
591
                           """javascript:go_submit( document.FormName, """"btnEditRelease"""" );""",_
592
                           null,_
593
                           "images/abtn_edit.gif",_
594
                           "images/abtn_edit_off.gif",_
595
                           "Edit selected release details...",_
596
                           "Y",_
597
                           "Y",_
4083 dpurdie 598
                           "N",_
127 ghuddy 599
                           "N")
600
         rsQry.AddNew varFields, varValues
601
      End If
602
 
603
      If isAbtnRequired(aAbtnList, "btnMergeManager") Then
604
         varValues = Array(17, "btnMergeManager", null,_
6508 dpurdie 605
                           """diff.asp""",_
127 ghuddy 606
                           null,_
607
                           "images/abtn_merge_manager.gif",_
608
                           "images/abtn_merge_manager_off.gif",_
5177 dpurdie 609
                           "Run merge manager...",_
127 ghuddy 610
                           "Y",_
611
                           "Y",_
4083 dpurdie 612
                           "N",_
127 ghuddy 613
                           "N")
614
         rsQry.AddNew varFields, varValues
615
      End If
616
 
617
      If isAbtnRequired(aAbtnList, "btnMoveRelease") Then
618
         varValues = Array(18, "btnMoveRelease", null,_
619
                           """javascript:go_submit( document.FormName, """"btnMoveRelease"""" );""",_
620
                           null,_
621
                           "images/abtn_move_release.gif",_
622
                           "images/abtn_move_release_off.gif",_
623
                           "Move selected release vertically...",_
624
                           "Y",_
625
                           "Y",_
4083 dpurdie 626
                           "N",_
127 ghuddy 627
                           "N")
628
         rsQry.AddNew varFields, varValues
629
      End If
630
 
5590 dpurdie 631
      ' NOTE: entries 19 and 20 were not used
632
      '       Index numbers can be reused
127 ghuddy 633
 
634
      If isAbtnRequired(aAbtnList, "btnNewVersion-MASSREF") Then
635
         varValues = Array(21, "btnNewVersion-MASSREF", null,_
636
                           """form_new_version.asp?rtag_id=""& AssocMASSREFValue &""&pv_id=""& Request(""pv_id"")",_
637
                           null,_
638
                           "images/abtn_new_version_MassRef.gif",_
639
                           null,_
640
                           "Create new version of this package in associated MASS REF.",_
641
                           "Y",_
642
                           "Y",_
4083 dpurdie 643
                           "N",_
127 ghuddy 644
                           "N")
645
         rsQry.AddNew varFields, varValues
646
      End If
647
 
5930 dpurdie 648
      If isAbtnRequired(aAbtnList, "btnDestroyWip") Then
649
         varValues = Array(34, "btnDestroyWip", null,_
650
                           """javascript:;""",_
651
                           """onClick=""""MM_openVixIFrame('_destroy_package.asp?bfile=""& ScriptName &""&""& objPMod.ComposeURL() &""','Destroy WIP');""""""",_
652
                           "icons/i_destroy_package.gif",_
653
                           "icons/i_destroy_package_off.gif",_
654
                           "Destroy this WIP",_
655
                           "Y",_
656
                           "Y",_
657
                           "Y",_
658
                           "N")
659
         rsQry.AddNew varFields, varValues
660
      End If
661
 
127 ghuddy 662
      If isAbtnRequired(aAbtnList, "btnRecycleBin") Then
663
         varValues = Array(22, "btnRecycleBin", null,_
5930 dpurdie 664
                           """javascript:;""",_
665
                           """onClick=""""MM_openVixIFrame('_destroy_package.asp?&rfile=""& ScriptName &""&""& objPMod.ComposeURL() &""','Destroy Package Version');""""""",_
127 ghuddy 666
                           "icons/i_destroy_package.gif",_
5929 dpurdie 667
                           "icons/i_destroy_package_off.gif",_
668
                           "Destroy this package version",_
127 ghuddy 669
                           "Y",_
670
                           "Y",_
5929 dpurdie 671
                           "Y",_
127 ghuddy 672
                           "N")
673
         rsQry.AddNew varFields, varValues
674
      End If
675
 
676
      If isAbtnRequired(aAbtnList, "btnDeprecation") Then
677
         varValues = Array(23, "btnDeprecation", null,_
678
                           """javascript:;""",_
5590 dpurdie 679
                           """onClick='MM_openVixIFrame(""""_wform_deprecate_package.asp?rfile=""& scriptName &""&pv_id=""& parPv_id &""&rtag_id=""& parRtag_id &"""""",""""Deprecate Package"""")' class='body_txt' title='Deprecate the package.'""",_
127 ghuddy 680
                           "images/BombBorder.gif",_
5169 dpurdie 681
                           "images/BombBorder_off.gif",_
127 ghuddy 682
                           "Deprecate this package in this release.",_
683
                           "Y",_
684
                           "Y",_
4083 dpurdie 685
                           "N",_
127 ghuddy 686
                           "N")
687
         rsQry.AddNew varFields, varValues
688
      End If
689
 
690
      If isAbtnRequired(aAbtnList, "btnUnDeprecation") Then
691
         varValues = Array(24, "btnUnDeprecation", null,_
5190 dpurdie 692
                           """_wform_undeprecate_package.asp?rfile=""& scriptName &""&pkg_id=""& pkgInfoHash.Item(""pkg_id"") &""&pv_id=""& parPv_id &""&rtag_id=""& parRtag_id &""""",_
693
                           """vixConfirm('You are about to undeprecate package: ""& pkgInfoHash.Item (""pkg_name"") &"".',{title:'Undeprecate Package', url: 'HREF'});""""""",_
127 ghuddy 694
                           "images/BombBorder.gif",_
695
                           null,_
5190 dpurdie 696
                           "Un Deprecate this package in this release",_
127 ghuddy 697
                           "Y",_
698
                           "Y",_
4083 dpurdie 699
                           "N",_
127 ghuddy 700
                           "N")
701
         rsQry.AddNew varFields, varValues
702
      End If
703
 
704
      If isAbtnRequired(aAbtnList, "btnAdminView") Then
705
         varValues = Array(25, "btnAdminView", null,_
6508 dpurdie 706
                           """form_edit_project_view.asp?proj_id=""& parProjId &""""",_
127 ghuddy 707
                           null,_
708
                           "images/view_admin.gif",_
709
                           null,_
710
                           "Administer the views in the project.",_
711
                           "Y",_
712
                           "Y",_
4083 dpurdie 713
                           "N",_
127 ghuddy 714
                           "N")
715
         rsQry.AddNew varFields, varValues
716
      End If
717
 
6508 dpurdie 718
      If isAbtnRequired(aAbtnList, "btnNotificationView") Then
719
         varValues = Array(25, "btnNotificationView", null,_
720
                           """form_view_release_notifications.asp?proj_id=""& parProjId &""""",_
721
                           null,_
722
                           "images/view_notifications.gif",_
723
                           null,_
724
                           "Display the package notification information in this project .",_
725
                           "Y",_
726
                           "Y",_
727
                           "N",_
728
                           "N")
729
         rsQry.AddNew varFields, varValues
730
      End If
731
 
6770 dpurdie 732
      If isAbtnRequired(aAbtnList, "btnProjectReplication") Then
733
         varValues = Array(25, "btnProjectReplication", null,_
734
                           """form_project_replication.asp?proj_id=""& parProjId &""""",_
735
                           null,_
736
                           "images/project_replication.gif",_
737
                           null,_
738
                           "Display the project replication information.",_
739
                           "Y",_
740
                           "Y",_
741
                           "N",_
742
                           "N")
743
         rsQry.AddNew varFields, varValues
744
      End If
6508 dpurdie 745
 
127 ghuddy 746
      ' NOTE: I do not think this one is ever used
747
      If isAbtnRequired(aAbtnList, "btnAddProc") Then
748
         varValues = Array(26, "btnAddProc", "Add Process",_
749
                           """javascript:;""",_
5590 dpurdie 750
                           """onClick=""""MM_openVixIFrame('wAddProc.asp?rfile=""& SCRIPT_NAME &""&""& objPMod.ComposeURL() &""','Add Process');""""""",_
127 ghuddy 751
                           "icons/btn_add.gif",_
752
                           null,_
753
                           null,_
754
                           "Y",_
755
                           "Y",_
4083 dpurdie 756
                           "N",_
127 ghuddy 757
                           "N")
758
         rsQry.AddNew varFields, varValues
759
      End If
760
 
761
      If isAbtnRequired(aAbtnList, "btnEditGBE_Machtype") Then
762
         varValues = Array(27, "btnEditGBE_Machtype", null,_
763
                           """javascript:;""",_
5590 dpurdie 764
                           """onClick=""""MM_openVixIFrame('wAddMachtype.asp?type=edit&gbe_id=""& gbe_id &""&rfile=""& SCRIPT_NAME &""&""& objPMod.ComposeURL() &""','Edit Machine Type');""""""",_
127 ghuddy 765
                           "icons/i_edit.gif",_
5814 dpurdie 766
                           null,_
127 ghuddy 767
                           "Edit this GBE MachType value",_
768
                           "Y",_
769
                           "Y",_
4083 dpurdie 770
                           "N",_
127 ghuddy 771
                           "N")
772
         rsQry.AddNew varFields, varValues
773
      End If
774
 
775
      If isAbtnRequired(aAbtnList, "btnDeleteGBE_Machtype") Then
776
         varValues = Array(28, "btnDeleteGBE_Machtype", null,_
777
                           """_DeleteMachtype.asp?rfile=""& SCRIPT_NAME &""&gbe_id=""& gbe_id &""&""& objPMod.ComposeURL()",_
5190 dpurdie 778
                           """vixConfirm('Remove \'""& GBE_VALUE &""\' from this list?',{title:'Remove GBE_MACHTYPE', button:'Remove', url: 'HREF'});""""""",_
127 ghuddy 779
                           "icons/i_remove.gif",_
780
                           null,_
781
                           "Delete this GBE MachType value",_
782
                           "Y",_
783
                           "Y",_
4083 dpurdie 784
                           "N",_
127 ghuddy 785
                           "N")
786
         rsQry.AddNew varFields, varValues
787
      End If
788
 
789
      If isAbtnRequired(aAbtnList, "btnEditDaemon") Then
790
         varValues = Array(29, "btnEditDaemon", null,_
791
                           """javascript:;""",_
5590 dpurdie 792
                           """onClick=""""MM_openVixIFrame('wAddDaemon.asp?type=edit&rcon_id=""& rcon_id &""&rfile=""& SCRIPT_NAME &""&""& objPMod.ComposeURL() &""','Edit Build Daemon');""""""",_
127 ghuddy 793
                           "icons/i_edit.gif",_
5983 dpurdie 794
                           NULL,_
4295 dpurdie 795
                           "Edit Build Configuration",_
127 ghuddy 796
                           "Y",_
797
                           "Y",_
4083 dpurdie 798
                           "N",_
127 ghuddy 799
                           "N")
800
         rsQry.AddNew varFields, varValues
801
      End If
802
 
803
      If isAbtnRequired(aAbtnList, "btnDeleteDaemon") Then
804
         varValues = Array(30, "btnDeleteDaemon", null,_
4293 dpurdie 805
                           """_DeleteDaemon.asp?rcon_id=""& rcon_id & ""&action=Delete&"" & objPMod.ComposeURL()",_
5190 dpurdie 806
                           """vixConfirm('Delete the \'""& Daemon &""\' Daemon and associated information from this Release?',{title:'Remove Deamon', button:'Remove', url: 'HREF'});""""""",_
4295 dpurdie 807
                           "icons/i_remove.gif",_
4293 dpurdie 808
                           null,_
4295 dpurdie 809
                           "Delete Daemon",_
4293 dpurdie 810
                           "Y",_
811
                           "Y",_
812
                           "N",_
813
                           "N")
814
         rsQry.AddNew varFields, varValues
815
      End If
816
 
817
      If isAbtnRequired(aAbtnList, "btnRemoveDaemon") Then
818
         varValues = Array(47, "btnRemoveDaemon", null,_
819
                           """_DeleteDaemon.asp?rcon_id=""& rcon_id & ""&action=Remove&""& objPMod.ComposeURL()",_
5190 dpurdie 820
                           """vixConfirm('Unlink the \'""& Daemon &""\' Daemon from this Release.<p>Configuration information will be maintained.',{title:'Unlink Deamon', button:'Unlink', url: 'HREF'});""""""",_
4295 dpurdie 821
                           "icons/break_link.gif",_
127 ghuddy 822
                           null,_
4295 dpurdie 823
                           "Unlink Daemon from entry",_
127 ghuddy 824
                           "Y",_
825
                           "Y",_
4083 dpurdie 826
                           "N",_
127 ghuddy 827
                           "N")
828
         rsQry.AddNew varFields, varValues
829
      End If
830
 
161 iaugusti 831
      If isAbtnRequired(aAbtnList, "btnEditBuildMachine") Then
832
         varValues = Array(29, "btnEditBuildMachine", null,_
833
                           """javascript:;""",_
5590 dpurdie 834
                           """onClick=""""MM_openVixIFrame('wAddBuildMachine.asp?type=edit&bmcon_id=""& bmcon_id &""&rfile=""& SCRIPT_NAME &""&""& objPMod.ComposeURL() &""','Edit Build Machine');""""""",_
161 iaugusti 835
                           "icons/i_edit.gif",_
5983 dpurdie 836
                           NULL,_
161 iaugusti 837
                           "Edit Build Machine",_
838
                           "Y",_
839
                           "Y",_
4083 dpurdie 840
                           "N",_
161 iaugusti 841
                           "N")
842
         rsQry.AddNew varFields, varValues
843
      End If
844
 
845
      If isAbtnRequired(aAbtnList, "btnDeleteBuildMachine") Then
846
         varValues = Array(30, "btnDeleteBuildMachine", null,_
847
                           """_DeleteBuildMachine.asp?rfile=""& SCRIPT_NAME &""&bmcon_id=""& bmcon_id &""&""& objPMod.ComposeURL()",_
5190 dpurdie 848
                           """vixConfirm('Remove Build Machine \'""& machine_hostname &""\' from this list?',{title:'Delete Build Machine', button:'Delete', url: 'HREF'});""""""",_
161 iaugusti 849
                           "icons/i_remove.gif",_
850
                           null,_
851
                           "Delete Build Machine",_
852
                           "Y",_
853
                           "Y",_
4083 dpurdie 854
                           "N",_
161 iaugusti 855
                           "N")
856
         rsQry.AddNew varFields, varValues
857
      End If
858
 
6770 dpurdie 859
      If isAbtnRequired(aAbtnList, "btnEditBlatMachine") Then
860
         varValues = Array(29, "btnEditBlatMachine", null,_
861
                           """javascript:;""",_
862
                           """onClick=""""MM_openVixIFrame('wAddPkgReplica.asp?type=edit&server_id=""& server_id &""&rfile=""& SCRIPT_NAME &""&""& objPMod.ComposeURL() &""','Edit Package Replica');""""""",_
863
                           "icons/i_edit.gif",_
864
                           NULL,_
865
                           "Edit Package Replica",_
866
                           "Y",_
867
                           "Y",_
868
                           "N",_
869
                           "N")
870
         rsQry.AddNew varFields, varValues
871
      End If
872
 
873
      If isAbtnRequired(aAbtnList, "btnDeleteBlatMachine") Then
874
         varValues = Array(30, "btnDeleteBlatMachine", null,_
875
                           """_DeletePkgReplica.asp?rfile=""& SCRIPT_NAME &""&server_id=""& server_id &""&""& objPMod.ComposeURL()",_
876
                           """vixConfirm('Remove Package Replica \'""& display_name &""\' from this list?',{title:'Delete Package Replica', button:'Delete', url: 'HREF'});""""""",_
877
                           "icons/i_remove.gif",_
878
                           null,_
879
                           "Delete Package Replica",_
880
                           "Y",_
881
                           "Y",_
882
                           "N",_
883
                           "N")
884
         rsQry.AddNew varFields, varValues
885
      End If
886
 
127 ghuddy 887
      If isAbtnRequired(aAbtnList, "btnPendingIntegration") Then
888
         varValues = Array(32, "btnPendingIntegration", null,_
889
                           """_modify_product_state.asp?state_id=1&rfile=""& ScriptName &""&pv_id=""& parPv_id &""&rtag_id=""& parRtag_id",_
5190 dpurdie 890
                           """vixConfirm('Do you want to proceed to make this product pending for INTEGRATION?',{title:'Make Pending', button:'Pending', url: 'HREF'});""""""",_
127 ghuddy 891
                           "icons/PendingIntegration.gif",_
892
                           null,_
893
                           "Make this product pending for Integration.",_
894
                           "Y",_
895
                           "Y",_
4083 dpurdie 896
                           "N",_
127 ghuddy 897
                           "N")
898
         rsQry.AddNew varFields, varValues
899
      End If
900
 
901
      If isAbtnRequired(aAbtnList, "btnPendingTest") Then
902
         varValues = Array(33, "btnPendingTest", null,_
903
                           """_modify_product_state.asp?state_id=2&rfile=""& ScriptName &""&pv_id=""& parPv_id &""&rtag_id=""& parRtag_id",_
5190 dpurdie 904
                           """vixConfirm('Do you want to proceed to make this product pending for Test?',{title:'Make Test', button:'Test', url: 'HREF'});""""""",_
127 ghuddy 905
                           "icons/PendingTest.gif",_
906
                           null,_
907
                           "Make this product pending for Test.",_
908
                           "Y",_
909
                           "Y",_
4083 dpurdie 910
                           "N",_
127 ghuddy 911
                           "N")
912
         rsQry.AddNew varFields, varValues
913
      End If
914
 
915
      If isAbtnRequired(aAbtnList, "btnPendingDeployment") Then
916
         varValues = Array(34, "btnPendingDeployment", null,_
917
                           """_modify_product_state.asp?state_id=3&rfile=""& ScriptName &""&pv_id=""& parPv_id &""&rtag_id=""& parRtag_id",_
5190 dpurdie 918
                           """vixConfirm('Do you want to proceed to make this product pending for DEPLOYMENT?',{title:'Make Deploy', button:'Deploy', url: 'HREF'});""""""",_
127 ghuddy 919
                           "icons/PendingDeployment.gif",_
920
                           null,_
921
                           "Make this product pending for Deployment.",_
922
                           "Y",_
923
                           "Y",_
4083 dpurdie 924
                           "N",_
127 ghuddy 925
                           "N")
926
         rsQry.AddNew varFields, varValues
927
      End If
928
 
929
      If isAbtnRequired(aAbtnList, "btnRejectProduct") Then
930
         varValues = Array(35, "btnRejectProduct", null,_
931
                           """_modify_product_state.asp?state_id=4&rfile=""& ScriptName &""&pv_id=""& parPv_id &""&rtag_id=""& parRtag_id",_
5190 dpurdie 932
                           """vixConfirm('Do you want to REJECT this product from DEPLOYMENT?',{title:'Reject Product', button:'Reject', url: 'HREF'});""""""",_
127 ghuddy 933
                           "icons/i_reject_pending.gif",_
934
                           null,_
935
                           "Reject this product from Deployment.",_
936
                           "Y",_
937
                           "Y",_
4083 dpurdie 938
                           "N",_
127 ghuddy 939
                           "N")
940
         rsQry.AddNew varFields, varValues
941
      End If
942
 
943
      If isAbtnRequired(aAbtnList, "btnPendingIntegrateAndDeploy") Then
944
         varValues = Array(36, "btnPendingIntegrateAndDeploy", null,_
945
                           """_modify_product_state.asp?state_id=5&rfile=""& ScriptName &""&pv_id=""& parPv_id &""&rtag_id=""& parRtag_id",_
5190 dpurdie 946
                           """vixConfirm('Do you want to proceed to make this product pending for INTEGRATION and DEPLOYMENT?',{title:'Pending Product', button:'Confirm', url: 'HREF'});""""""",_
127 ghuddy 947
                           "icons/PendingDeployment.gif",_
948
                           null,_
949
                           "Make this product pending for Integration and Deployment.",_
950
                           "Y",_
951
                           "Y",_
4083 dpurdie 952
                           "N",_
127 ghuddy 953
                           "N")
954
         rsQry.AddNew varFields, varValues
955
      End If
956
 
957
      If isAbtnRequired(aAbtnList, "btnDeleteSchedule") Then
958
         varValues = Array(37, "btnDeleteSchedule", null,_
959
                           """_DeleteSchedule.asp?scheduled_id=""& scheduled_id &""&""& objPMod.ComposeURL()",_
5190 dpurdie 960
                           """vixConfirm('Remove Schedule from this list?',{title:'Remove Schedule', button:'Remove', url: 'HREF'});""""""",_
127 ghuddy 961
                           "icons/i_remove.gif",_
177 brianf 962
                           "icons/i_remove_dis.gif",_
127 ghuddy 963
                           "Delete Schedule",_
964
                           "Y",_
965
                           "Y",_
4083 dpurdie 966
                           "N",_
127 ghuddy 967
                           "N")
968
         rsQry.AddNew varFields, varValues
969
      End If
970
 
971
      If isAbtnRequired(aAbtnList, "btnApproveMerge") Then
972
         varValues = Array(38, "btnApproveMerge", null,_
973
                           """_approve_merge.asp?rfile=""& ScriptName &""&pv_id=""& parPv_id &""&rtag_id=""& parRtag_id",_
5190 dpurdie 974
                           """vixConfirm('The release will be updated by this merge operation',{title:'Approve Merge', button:'Merge', url: 'HREF'});""""""",_
127 ghuddy 975
                           "icons/i_make_released.gif",_
976
                           "icons/i_make_released_off.gif",_
977
                           "Approve and carry out the pending merge operation",_
978
                           "Y",_
979
                           "Y",_
4083 dpurdie 980
                           "N",_
127 ghuddy 981
                           "N")
982
         rsQry.AddNew varFields, varValues
983
      End If
984
 
143 ghuddy 985
      If isAbtnRequired(aAbtnList, "btnRejectAutobuildPackage") Then
986
         varValues = Array( 39, "btnRejectAutobuildPackage", null,_
987
                           """_make_rejected.asp?rfile=""& ScriptName &""&pv_id=""& parPv_id &""&rtag_id=""& parRtag_id ",_
5190 dpurdie 988
                           """vixConfirm('Rejecting a package already approved for autobuild will set it back to Work-In-Progress',{title:'Reject Package', button:'Reject', url: 'HREF'});""""""",_
143 ghuddy 989
                           "icons/i_reject_pending.gif",_
990
                           "icons/i_reject_pending_off.gif",_
991
                           "Unapprove autobuild, move back to Work-In-Progress.",_
992
                           "Y",_
993
                           "Y",_
4083 dpurdie 994
                           "N",_
143 ghuddy 995
                           "N")
996
         rsQry.AddNew varFields, varValues
997
      End If
998
 
147 ghuddy 999
      If isAbtnRequired(aAbtnList, "btnDeleteDaemonInst") Then
1000
         varValues = Array(40, "btnDeleteDaemonInst", null,_
1001
                           """_DeleteDaemonInstruction.asp?rfile=""& ScriptName &""&inst_id=""& daemonInstId &""&""& objPMod.ComposeURL()",_
5190 dpurdie 1002
                           """vixConfirm('Delete the Daemon Instruction from this list?',{title:'Delete Instruction', button:'Delete', url: 'HREF', width : 350, height : 150});""""""",_
147 ghuddy 1003
                           "icons/i_remove.gif",_
1004
                           null,_
1005
                           "Delete this Daemon Instruction",_
1006
                           "Y",_
1007
                           "Y",_
4083 dpurdie 1008
                           "N",_
147 ghuddy 1009
                           "N")
1010
         rsQry.AddNew varFields, varValues
1011
      End If
1012
 
1013
      If isAbtnRequired(aAbtnList, "btnEditDaemonInst") Then
1014
         varValues = Array(41, "btnEditDaemonInst", null,_
5590 dpurdie 1015
                           """javascript:;""",_
1016
                           """onClick=""""MM_openVixIFrame('wAddDaemonInstruction.asp?edit=true&inst_id=""& daemonInstId & ""&sort="" & parSortOrder & ""&rfile=""& ScriptName &""&""& objPMod.ComposeURL() &""','Edit Daemon Instruction');""""""",_
147 ghuddy 1017
                           "icons/i_edit.gif",_
5983 dpurdie 1018
                           NULL,_
147 ghuddy 1019
                           "Edit this Daemon Instruction",_
1020
                           "Y",_
1021
                           "Y",_
4083 dpurdie 1022
                           "N",_
147 ghuddy 1023
                           "N")
1024
         rsQry.AddNew varFields, varValues
1025
      End If
1026
 
1027
      If isAbtnRequired(aAbtnList, "btnAddDaemonInstRipplePackage") Then
1028
         varValues = Array(42, "btnAddDaemonInstRipplePackage", null,_
5590 dpurdie 1029
                           """javascript:;""",_
1030
                           """onClick=""""MM_openVixIFrame('wAddDaemonInstructionSimple.asp?op_code=0"" &""&rfile=""& ScriptName &""&""& objPMod.ComposeURL() &""','Ripple or Test Build Package');""""""",_
147 ghuddy 1031
                           "images/ripplesquare.gif",_
6185 dpurdie 1032
                           NULL,_
147 ghuddy 1033
                           "Request the Build Daemon to ripple this package version",_
1034
                           "Y",_
1035
                           "Y",_
4083 dpurdie 1036
                           "N",_
1037
                           "Y")
147 ghuddy 1038
         rsQry.AddNew varFields, varValues
1039
      End If
1040
 
6185 dpurdie 1041
      If isAbtnRequired(aAbtnList, "btnDelDaemonInstRipplePackage") Then
1042
         varValues = Array(42, "btnDelDaemonInstRipplePackage", null,_
1043
                           """_DeleteDaemonInstruction.asp?rfile=""& ScriptName &""&opCode="" & OP_CODE_0_RIPPLE_BUILD_PACKAGE & ""&""& objPMod.ComposeURL()",_
1044
                           """vixConfirm('Delete the Ripple Request?',{title:'Delete Ripple Request', button:'Delete', url: 'HREF', width : 350, height : 150});""""""",_
6187 dpurdie 1045
                           "images/CascadeSquareDel.gif",_
6185 dpurdie 1046
                           NULL,_
1047
                           "Delete the Ripple Request",_
1048
                           "Y",_
1049
                           "Y",_
1050
                           "N",_
1051
                           "Y")
1052
         rsQry.AddNew varFields, varValues
1053
      End If
1054
 
1055
      If isAbtnRequired(aAbtnList, "btnDelDaemonInstTestPackage") Then
1056
         varValues = Array(42, "btnDelDaemonInstTestPackage", null,_
1057
                           """_DeleteDaemonInstruction.asp?rfile=""& ScriptName &""&opCode="" & OP_CODE_1_TEST_BUILD_PACKAGE & ""&""& objPMod.ComposeURL()",_
1058
                           """vixConfirm('Delete the Test Build Request?',{title:'Delete Test Build Request', button:'Delete', url: 'HREF', width : 350, height : 150});""""""",_
6187 dpurdie 1059
                           "images/testSquareDel.gif",_
6185 dpurdie 1060
                           NULL,_
1061
                           "Delete the Test Build Request",_
1062
                           "Y",_
1063
                           "Y",_
1064
                           "N",_
1065
                           "Y")
1066
         rsQry.AddNew varFields, varValues
1067
      End If
1068
 
1069
 
149 ghuddy 1070
      If isAbtnRequired(aAbtnList, "btnAddDaemonInstTestBuildPackage") Then
1071
         varValues = Array(43, "btnAddDaemonInstTestBuildPackage", null,_
5590 dpurdie 1072
                           """javascript:;""",_
1073
                           """onClick=""""MM_openVixIFrame('wAddDaemonInstruction.asp?op_code=1"" &""&rfile=""& ScriptName &""&""& objPMod.ComposeURL() &""','Add Daemon Instruction');""""""",_
149 ghuddy 1074
                           "images/abtn_test_build.gif",_
6188 dpurdie 1075
                           NULL,_
149 ghuddy 1076
                           "Request the Build Daemon to test build this WIP package version",_
1077
                           "Y",_
1078
                           "Y",_
4083 dpurdie 1079
                           "N",_
149 ghuddy 1080
                           "N")
1081
         rsQry.AddNew varFields, varValues
1082
      End If
1083
 
157 ghuddy 1084
      If isAbtnRequired(aAbtnList, "btnMoveWIPToRelease") Then
1085
         varValues = Array( 44, "btnMoveWIPToRelease", null,_
1086
                           """javascript:;""",_
5590 dpurdie 1087
                           """onClick=""""MM_openVixIFrame('_wform_move_wip.asp"" &""?rfile=""& ScriptName &""&""&  objPMod.ComposeURL() &""','Move WIP');""""""",_
157 ghuddy 1088
                           "images/abtn_move_wip_to_release.gif",_
4670 dpurdie 1089
                           "images/abtn_move_wip_to_release_off.gif",_
157 ghuddy 1090
                           "Move this WIP to another release.",_
1091
                           "Y",_
1092
                           "Y",_
4083 dpurdie 1093
                           "N",_
157 ghuddy 1094
                           "N")
1095
         rsQry.AddNew varFields, varValues
1096
      End If
1097
 
183 brianf 1098
      If isAbtnRequired(aAbtnList, "btnLockPackage") Then
1099
         varValues = Array( 45, "btnLockPackage", null,_
1100
                           """_s_lock_package.asp?pv_id=""& parPv_id &""&rtag_id=""& parRtag_id ",_
5190 dpurdie 1101
                           """vixConfirm('Lock Package.<p>This will prevent changes to the package.',{title:'Lock Package', button:'Lock', url: 'HREF'});""""""",_
183 brianf 1102
                           "icons/i_lock.gif",_
1103
                           "icons/i_lock_off.gif",_
1104
                           "Lock this package.",_
1105
                           "Y",_
1106
                           "Y",_
4083 dpurdie 1107
                           "N",_
183 brianf 1108
                           "N")
1109
         rsQry.AddNew varFields, varValues
1110
      End If
1111
 
1112
      If isAbtnRequired(aAbtnList, "btnUnLockPackage") Then
1113
         varValues = Array( 46, "btnUnLockPackage", null,_
1114
                           """_s_unlock_package.asp?pv_id=""& parPv_id &""&rtag_id=""& parRtag_id ",_
5190 dpurdie 1115
                           """vixConfirm('Unlock Package.<p>This may have serious side effects.',{title:'Unlock Package', button:'Unlock', url: 'HREF'});""""""",_
183 brianf 1116
                           "icons/i_unlock.gif",_
1117
                           "icons/i_unlock_off.gif",_
1118
                           "Unlock this package.",_
1119
                           "Y",_
1120
                           "Y",_
4083 dpurdie 1121
                           "N",_
183 brianf 1122
                           "N")
1123
         rsQry.AddNew varFields, varValues
1124
      End If
1125
 
4293 dpurdie 1126
 
1127
 
3959 dpurdie 1128
      If isAbtnRequired(aAbtnList, "btnEditProjectExtensions") Then
1129
         varValues = Array(29, "btnEditProjectExtensions", null,_
1130
                           """javascript:;""",_
5590 dpurdie 1131
                           """onClick=""""MM_openVixIFrame('wAddProjectExtension.asp?type=edit&ext=""& extName &""&rfile=""& SCRIPT_NAME &""&""& objPMod.ComposeURL() &""','Edit Project Extension');""""""",_
3959 dpurdie 1132
                           "icons/i_edit.gif",_
5983 dpurdie 1133
                           NULL,_
3959 dpurdie 1134
                           "Edit Project Extensions",_
1135
                           "Y",_
1136
                           "Y",_
4083 dpurdie 1137
                           "N",_
3959 dpurdie 1138
                           "N")
1139
         rsQry.AddNew varFields, varValues
1140
      End If
1141
 
1142
      If isAbtnRequired(aAbtnList, "btnDeleteProjectExtension") Then
1143
         varValues = Array(30, "btnDeleteProjectExtension", null,_
1144
                           """_DeleteProjectExtension.asp?rfile=""& SCRIPT_NAME &""&ext=""& extName &""&""& objPMod.ComposeURL()",_
5190 dpurdie 1145
                           """vixConfirm('Remove Project Extension:  \'""& extName &""\' from this list?<p>This will prevent it from being used in new package versions.',{title:'Remove Project Extension', button:'Remove', url: 'HREF'});""""""",_
3959 dpurdie 1146
                           "icons/i_remove.gif",_
1147
                           null,_
1148
                           "Delete Project Extension",_
1149
                           "Y",_
1150
                           "Y",_
4083 dpurdie 1151
                           "N",_
3959 dpurdie 1152
                           "N")
1153
         rsQry.AddNew varFields, varValues
1154
      End If
4029 dpurdie 1155
 
1156
      If isAbtnRequired(aAbtnList, "btnEditGBE_Machclass") Then
1157
         varValues = Array(31, "btnEditGBE_Machclass", null,_
1158
                           """javascript:;""",_
5590 dpurdie 1159
                           """onClick=""""MM_openVixIFrame('wAddMachclass.asp?type=edit&bm_id=""& bm_id &""&rfile=""& SCRIPT_NAME &""&""& objPMod.ComposeURL() &""','Edit Machine Class');""""""",_
4029 dpurdie 1160
                           "icons/i_edit.gif",_
5983 dpurdie 1161
                           NULL,_
4029 dpurdie 1162
                           "Edit this GBE MachClass value",_
1163
                           "Y",_
1164
                           "Y",_
4083 dpurdie 1165
                           "N",_
4029 dpurdie 1166
                           "N")
1167
         rsQry.AddNew varFields, varValues
1168
      End If
1169
 
1170
      If isAbtnRequired(aAbtnList, "btnDeleteGBE_Machclass") Then
1171
         varValues = Array(32, "btnDeleteGBE_Machclass", null,_
4040 dpurdie 1172
                           """wAddMachclass.asp?type=delete&bm_id=""& bm_id &""&rfile=""& SCRIPT_NAME &""&""& objPMod.ComposeURL()",_
5190 dpurdie 1173
                           """vixConfirm('Delete the \'""& GBE_VALUE &""\' Machine Class',{title:'Delete Machine Class', button:'Delete', url: 'HREF'});""""""",_
4029 dpurdie 1174
                           "icons/i_remove.gif",_
1175
                           null,_
1176
                           "Delete this GBE MachClass value",_
1177
                           "Y",_
1178
                           "Y",_
4083 dpurdie 1179
                           "N",_
4029 dpurdie 1180
                           "N")
1181
         rsQry.AddNew varFields, varValues
1182
      End If
4670 dpurdie 1183
 
5122 dpurdie 1184
      If isAbtnRequired(aAbtnList, "btnEditGBE_BuildStandard") Then
1185
         varValues = Array(48, "btnEditGBE_BuildStandard", null,_
1186
                           """javascript:;""",_
5590 dpurdie 1187
                           """onClick=""""MM_openVixIFrame('wAddBuildStandard.asp?type=edit&bsa_id=""& bsa_id &""&rfile=""& SCRIPT_NAME &""&""& objPMod.ComposeURL() &""','Edit Build Standard');""""""",_
5122 dpurdie 1188
                           "icons/i_edit.gif",_
5983 dpurdie 1189
                           NULL,_
5122 dpurdie 1190
                           "Edit this Build Standard",_
1191
                           "Y",_
1192
                           "Y",_
1193
                           "N",_
1194
                           "N")
1195
         rsQry.AddNew varFields, varValues
1196
      End If
1197
 
1198
      If isAbtnRequired(aAbtnList, "btnDeleteGBE_BuildStandard") Then
1199
         varValues = Array(49, "btnDeleteGBE_BuildStandard", null,_
1200
                           """_DeleteBuildStandard.asp?rfile=""& SCRIPT_NAME &""&bsa_id=""& bsa_id &""&""& objPMod.ComposeURL()",_
5190 dpurdie 1201
                           """vixConfirm('Delete the \'""& GBE_VALUE &""\' Build Standard',{title : 'Delete Build Standard', button:'Delete', url: 'HREF'});""""""",_
5122 dpurdie 1202
                           "icons/i_remove.gif",_
1203
                           null,_
1204
                           "Delete this Build Standard",_
1205
                           "Y",_
1206
                           "Y",_
1207
                           "N",_
1208
                           "N")
1209
         rsQry.AddNew varFields, varValues
1210
      End If
4029 dpurdie 1211
 
3959 dpurdie 1212
 
127 ghuddy 1213
      ' Move cursor to the first record
1214
      rsQry.MoveFirst
1215
 
1216
      If ((NOT rsQry.BOF) AND (NOT rsQry.EOF)) Then
1217
         Call LoadButtons ( rsQry.GetRows() )
1218
      End If
1219
 
1220
      rsQry.Close
1221
      Set rsQry = Nothing
1222
   End Sub
1223
   '-----------------------------------------------------------------------------------------------------------------
1224
   Public Sub LoadButtons ( aRows )
1225
      Dim nProperty, newArrayDim, LastRow, rowNum
1226
 
1227
      LastRow = UBound( aRows, 2 )
1228
 
1229
      For rowNum = 0 To LastRow
1230
         ' Increase array by 1
1231
         newArrayDim = LastRowInx() + 1
1232
         ReDim Preserve mArrAbtnDef( mNumOfProperties, newArrayDim )
1233
 
1234
 
1235
         mobjNameDefMap.Item ( Cstr( aRows ( InxName, rowNum ) ) ) = newArrayDim
1236
 
1237
         For nProperty = 0 To mLastPropertyInx
1238
            mArrAbtnDef ( nProperty, newArrayDim ) = aRows ( nProperty, rowNum )
1239
 
1240
         Next
1241
 
1242
      Next
1243
 
1244
   End Sub
1245
   '-----------------------------------------------------------------------------------------------------------------
1246
   Private Function LastRowInx ()
1247
       LastRowInx = UBound ( mArrAbtnDef, 2 )
1248
   End Function
1249
   '-----------------------------------------------------------------------------------------------------------------
1250
   Public Sub AddSeparatorAfter ( sItemName, sSeparatorWidth )
1251
      If InStr( sItemName, " " ) > 0 Then   Err.Raise 8, "Method AddSeparatorAfter", "Item Name '"& sItemName &"' cannot have spaces."
1252
      mobjSeparator.Add (Cstr(sItemName)), CStr(sSeparatorWidth)
1253
   End Sub
1254
   '-----------------------------------------------------------------------------------------------------------------
1255
   Public Sub AddSeparator ( sSeparatorWidth )
1256
      mobjSeparator.Add ( Cstr(mArrAbtnDef(InxName, LastItemInx())) ), CStr(sSeparatorWidth)
1257
   End Sub
1258
   '-----------------------------------------------------------------------------------------------------------------
1259
   Private Sub SetItemDefaults ( sItemName )
1260
      ' Additional default setup
1261
      Call SetItemPropertyByIndex ( mobjNameDefMap.Item (Cstr(sItemName)), InxActive, enumDB_YES )         ' Default Active = enumDB_YES
1262
   End Sub
1263
   '-----------------------------------------------------------------------------------------------------------------
1264
   Public Sub Text ( sItemName, Value )
1265
      Call SetItemPropertyByIndex ( mobjNameDefMap.Item (Cstr(sItemName)), InxTxt, Value )
1266
   End Sub
1267
   '-----------------------------------------------------------------------------------------------------------------
1268
   Public Sub ItemID ( sItemName, Value )
1269
      Call SetItemPropertyByIndex ( mobjNameDefMap.Item (Cstr(sItemName)), InxID, Value )
1270
   End Sub
1271
   '-----------------------------------------------------------------------------------------------------------------
1272
   Public Sub Image ( sItemName, Value )
1273
      Call SetItemPropertyByIndex ( mobjNameDefMap.Item (Cstr(sItemName)), InxImg, Value )
1274
      Call SetItemPropertyByIndex ( mobjNameDefMap.Item (Cstr(sItemName)), InxImgOff, Value )         ' Default image disable to be the same as image
1275
   End Sub
1276
   '-----------------------------------------------------------------------------------------------------------------
1277
   Public Sub ImageOff ( sItemName, Value )
1278
      Call SetItemPropertyByIndex ( mobjNameDefMap.Item (Cstr(sItemName)), InxImgOff, Value )
1279
   End Sub
1280
   '-----------------------------------------------------------------------------------------------------------------
1281
   Public Sub Link ( sItemName, Value )
1282
      Call SetItemPropertyByIndex ( mobjNameDefMap.Item (Cstr(sItemName)), InxLink, Value )
1283
   End Sub
1284
   '-----------------------------------------------------------------------------------------------------------------
1285
   Public Sub EventHandler ( sItemName, Value )
1286
      Call SetItemPropertyByIndex ( mobjNameDefMap.Item (Cstr(sItemName)), InxEventHandler, Value )
1287
   End Sub
1288
   '-----------------------------------------------------------------------------------------------------------------
1289
   Public Sub Hint ( sItemName, Value )
1290
      Call SetItemPropertyByIndex ( mobjNameDefMap.Item (Cstr(sItemName)), InxHint, Value )
1291
   End Sub
1292
   '-----------------------------------------------------------------------------------------------------------------
1293
   Public Sub Visible ( sItemName, Value )
1294
      'Response.write sItemName &"here"& mobjNameDefMap.Item (Cstr(sItemName))
1295
      Call SetItemPropertyByIndex ( mobjNameDefMap.Item (Cstr(sItemName)), InxVisible, Value )
1296
   End Sub
1297
   '-----------------------------------------------------------------------------------------------------------------
5929 dpurdie 1298
   Public Sub ReadOnly ( sItemName, Value )
1299
      Call SetItemPropertyByIndex ( mobjNameDefMap.Item (Cstr(sItemName)), InxIsReadonlyAction, Value )
1300
   End Sub
1301
   '-----------------------------------------------------------------------------------------------------------------
143 ghuddy 1302
   Public Function IsVisible ( sItemName )
1303
      'Response.write sItemName &"here"& mobjNameDefMap.Item (Cstr(sItemName))
1304
      IsVisible = GetItemPropertyByIndex ( mobjNameDefMap.Item (Cstr(sItemName)), InxVisible )
1305
   End Function
1306
   '-----------------------------------------------------------------------------------------------------------------
127 ghuddy 1307
   Public Sub Active ( sItemName, Value )
1308
      'Response.write sItemName &"here"& mobjNameDefMap.Item (Cstr(sItemName))
1309
      Call SetItemPropertyByIndex ( mobjNameDefMap.Item (Cstr(sItemName)), InxActive, Value )
1310
   End Sub
1311
   '-----------------------------------------------------------------------------------------------------------------
143 ghuddy 1312
   Public Function IsActive ( sItemName )
1313
      IsActive = GetItemPropertyByIndex ( mobjNameDefMap.Item (Cstr(sItemName)), InxActive )
1314
   End Function
1315
   '-----------------------------------------------------------------------------------------------------------------
127 ghuddy 1316
   Private Sub Class_Initialize()
1317
      '// Perform action on creation of object. e.g. Set myObj = New ThisClassName
1318
      Set mobjNameDefMap = CreateObject("Scripting.Dictionary")
1319
      Set mobjIdDefMap = CreateObject("Scripting.Dictionary")
1320
      Set mobjSeparator = CreateObject("Scripting.Dictionary")
1321
      Set mobjACActionsMap = CreateObject("Scripting.Dictionary")
1322
 
1323
      'mbIsReadonly = FALSE   ' Tell control that it should use only readonly action buttons (i.e. actions which will not alter database )
1324
      mReadonlyActionBehaviour = enumABTNCTRL_ON_READONLY_HIDE      ' Tell control what to do by default if mbIsReadonly = TRUE
1325
 
1326
      mnButtonSpacer = 0
1327
      mnImageHspace = 4
1328
 
4083 dpurdie 1329
      mNumOfProperties = 12     ' Number of properties in array which define one menu item.
127 ghuddy 1330
      mLastPropertyInx = mNumOfProperties - 1
1331
 
1332
      mbDisableAll = FALSE
1333
 
1334
      ReDim mArrAbtnDef ( mNumOfProperties, -1 )
4083 dpurdie 1335
      InxID                 = 0
127 ghuddy 1336
      InxName               = 1
4083 dpurdie 1337
      InxTxt                = 2
127 ghuddy 1338
      InxLink               = 3
4083 dpurdie 1339
      InxEventHandler       = 4
1340
      InxImg                = 5
1341
      InxImgOff             = 6
127 ghuddy 1342
      InxHint               = 7
1343
      InxVisible            = 8
4083 dpurdie 1344
      InxActive             = 9
1345
      InxIsReadonlyAction   = 10
1346
      InxHideOnClosed       = 11
127 ghuddy 1347
 
1348
   End Sub
1349
   '-----------------------------------------------------------------------------------------------------------------
1350
   Private Sub Class_Terminate()
1351
      '// Perform action on object disposal. e.g. Set myObj = Nothing
1352
      Set mobjNameDefMap = Nothing
1353
      Set mobjIdDefMap = Nothing
1354
      Set mobjSeparator = Nothing
1355
      Set mobjACActionsMap = Nothing
1356
 
1357
 
1358
   End Sub
1359
   '-----------------------------------------------------------------------------------------------------------------
119 ghuddy 1360
End Class
127 ghuddy 1361
%>