-
Notifications
You must be signed in to change notification settings - Fork 3
/
RibbonModifier2.bas
48 lines (36 loc) · 1.15 KB
/
RibbonModifier2.bas
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
Attribute VB_Name = "RibbonModifier"
Option Explicit
Option Private Module
Private Type THelper
UIRibbon As IRibbonUI
RibbonMonitorer As RibbonUIUpdater
RibbonUpdater As RibbonUIUpdater
End Type
Private this As THelper
Public Sub InitializeSubSuperScriptingAddin2(ByRef ribbon As IRibbonUI) 'Callback for customUI.onLoad
Stop
Debug.Print 1 / 0
Set this.RibbonMonitorer = New RibbonUIUpdater
Set this.RibbonUpdater = New RibbonUIUpdater
Set this.UIRibbon = ribbon
SubSuperScript.InitializeScriptCharacters
End Sub
Public Sub SyncUIControls()
UIRibbon.Invalidate
End Sub
Public Property Get UIRibbon() As IRibbonUI
Set UIRibbon = this.UIRibbon
End Property
Public Property Get RibbonUpdater() As RibbonUIUpdater
If this.RibbonUpdater Is Nothing Then
Set this.RibbonUpdater = New RibbonUIUpdater
End If
Set RibbonUpdater = this.RibbonUpdater
End Property
Public Property Let RibbonUpdater(ByVal newUpdater As RibbonUIUpdater)
Set RibbonUpdater = newUpdater
End Property
Public Property Get RibbonMonitorer() As RibbonUIUpdater
Stop
Set RibbonMonitorer = this.RibbonMonitorer
End Property