Skip to content

Commit 9b08d00

Browse files
committed
tool bar buttons disable/enable and gray scale when inactive
1 parent 21c663e commit 9b08d00

40 files changed

+279
-301
lines changed

CSciExtender.cls

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,9 @@ Option Explicit
1717
Public Event MarginClick(lLine As Long, Position As Long, margin As Long, modifiers As Long)
1818
Public Event MouseDwellStart(lLine As Long, Position As Long)
1919
Public Event MouseDwellEnd(lLine As Long, Position As Long)
20+
'Public Event UpdateUI()
2021

21-
Private WithEvents sc As CSubclass2
22+
Private WithEvents sc As clsSubClass
2223
Attribute sc.VB_VarHelpID = -1
2324
Private ucHwnd As Long
2425
Private owner As SciSimple
@@ -29,6 +30,7 @@ Private Const SCI_LINEFROMPOSITION = 2166
2930
Private Const SCN_MARGINCLICK = 2010
3031
Private Const SCN_DWELLSTART = 2016
3132
Private Const SCN_DWELLEND = 2017
33+
Private Const SCN_UPDATEUI = 2007
3234

3335
Private Type NMHDR
3436
hwndFrom As Long
@@ -80,7 +82,7 @@ Function Init(scivb As SciSimple, Optional dwelltime As Long = 600) As Boolean
8082
Dim i As Long
8183

8284
Set owner = scivb
83-
Set sc = New CSubclass2
85+
Set sc = New clsSubClass
8486

8587
ucHwnd = GetUCHwnd(scivb)
8688
If sc.AttachMessage(ucHwnd, WM_NOTIFY) Then
@@ -122,6 +124,9 @@ Private Sub HandleSciMsg(tHdr As NMHDR, scMsg As SCNotification)
122124

123125
Select Case tHdr.Code
124126

127+
'Case SCN_UPDATEUI
128+
' RaiseEvent UpdateUI 'PosChanged was depreceated and removed...
129+
125130
Case SCN_MARGINCLICK
126131
lLine = owner.DirectSCI.SendEditor(SCI_LINEFROMPOSITION, scMsg.Position)
127132
RaiseEvent MarginClick(lLine, scMsg.Position, scMsg.margin, scMsg.modifiers)

0 commit comments

Comments
 (0)