private static void RecordAllBeforeQueryStatus(object sender, EventArgs e) { var menuCommand = (OleMenuCommand)sender; menuCommand.Enabled = UnusedCssExtension.IsAnyConnectionAlive; menuCommand.Visible = menuCommand.Enabled && !UnusedCssExtension.Any(x => x.IsRecording); }
private static void StopRecordAllBeforeQueryStatus(object sender, EventArgs e) { var menu = (OleMenuCommand)sender; menu.Visible = UnusedCssExtension.Any(x => x.IsRecording); }