Skip to content

Commit 3d210e7

Browse files
committed
no more click-lag
1 parent 8ab87c1 commit 3d210e7

File tree

1 file changed

+9
-1
lines changed

1 file changed

+9
-1
lines changed

RetailCoder.VBE/App.cs

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -126,10 +126,18 @@ private void HandleKeyboardMessage()
126126
RefreshSelection();
127127
}
128128

129+
private ParserState _lastStatus;
129130
private void RefreshSelection()
130131
{
131132
_stateBar.SetSelectionText(_parser.State.FindSelectedDeclaration(_vbe.ActiveCodePane));
132-
_appMenus.EvaluateCanExecute(_parser.State);
133+
134+
var currentStatus = _parser.State.Status;
135+
if (_lastStatus != currentStatus)
136+
{
137+
_appMenus.EvaluateCanExecute(_parser.State);
138+
}
139+
140+
_lastStatus = currentStatus;
133141
}
134142

135143
private void _configService_SettingsChanged(object sender, EventArgs e)

0 commit comments

Comments
 (0)