Subversion Repositories DevTools

Rev

Rev 7225 | Rev 7240 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 7225 Rev 7235
Line 10... Line 10...
10
'--------------- Global Constants ----------------
10
'--------------- Global Constants ----------------
11
Const enumABTNCTRL_ON_READONLY_HIDE = 1
11
Const enumABTNCTRL_ON_READONLY_HIDE = 1
12
Const enumABTNCTRL_ON_READONLY_DISABLE = 2
12
Const enumABTNCTRL_ON_READONLY_DISABLE = 2
13
'-------------------------------------------------
13
'-------------------------------------------------
14
 
14
 
-
 
15
Class ActionButton
-
 
16
    Public ABTN_NAME
-
 
17
    Public TEXT
-
 
18
    Public ACTION_LINK
-
 
19
    Public EVENT_HANDLER
-
 
20
    Public IMG_ENABLED
-
 
21
    Public IMG_DISABLED
-
 
22
    Public HINT
-
 
23
    Public VISIBLE
-
 
24
    Public ACTIVE
-
 
25
    Public IS_READONLY_ACTION
-
 
26
    Public HIDE_ON_CLOSED
-
 
27
 
-
 
28
    Public Sub Class_Initialize
-
 
29
        ABTN_NAME = "NONE"
-
 
30
        VISIBLE = "Y"
-
 
31
        ACTIVE = "Y"
-
 
32
        IS_READONLY_ACTION = "N"
-
 
33
        HIDE_ON_CLOSED = "N" 
-
 
34
    End Sub
-
 
35
 
-
 
36
    Public Sub Class_Terminate
-
 
37
    End Sub
-
 
38
 
-
 
39
	' Psuedo constructor
-
 
40
	' Use: Set myButton = New ActionButton.Init("btnName")
-
 
41
    Public Sub Init(bName)
-
 
42
        ABTN_NAME = bName
-
 
43
        Set Init = Me
-
 
44
    End Sub
-
 
45
 
-
 
46
End Class
-
 
47
 
15
Class ActionButtonControl
48
Class ActionButtonControl
16
 
49
 
17
   Private mArrAbtnDef()
50
   Private mArrAbtnDef()
18
   Private mobjNameDefMap        ' Item can be accesed by name. Must be unique within one page
51
   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
52
   Private mobjIdDefMap          ' Item can be accesed by id. Must be unique within one page. If NULL, ubound is assigned to it
Line 150... Line 183...
150
                " "& uevent &" class='menu_link' title='"& hint &"'>"&_
183
                " "& uevent &" class='menu_link' title='"& hint &"'>"&_
151
                btnImage & mArrAbtnDef( InxTxt, itemInx ) &"</a>"&_
184
                btnImage & mArrAbtnDef( InxTxt, itemInx ) &"</a>"&_
152
                "</td>"
185
                "</td>"
153
         End If
186
         End If
154
 
187
 
155
			'-- Define Disabled Button
188
            '-- Define Disabled Button
156
            '   A Null value of '' will use InxImg with the lessOpacity Class
189
            '   A Null value of '' will use InxImg with the lessOpacity Class
157
            hint = hint & " [Disabled]" 
190
            hint = hint & " [Disabled]" 
158
            If IsNull(mArrAbtnDef( InxImgOff, itemInx )) Then
191
            If IsNull(mArrAbtnDef( InxImgOff, itemInx )) Then
159
                ButtonStrDisabled = _
192
                ButtonStrDisabled = _
160
                    "<td nowrap>"&_
193
                    "<td nowrap>"&_