@Subscribe public void changeShotcutStyle(ChangeShotCutEvent event) { for (ShotcutSection section : shotcutPanelList) { for (NativeButton shotcutBtn : section.getShotcuts()) { ShotcutItem shotcut = (ShotcutItem) shotcutBtn.getData(); if (event.getAction().equals(shotcut.getAction())) { shotcutBtn.addStyleName("v-nativebutton-selected"); } else { shotcutBtn.removeStyleName("v-nativebutton-selected"); } } } }
public void setActionNotifyNumber(String action, int number) { for (ShotcutSection section : shotcutPanelList) { section.setShotcutLabel(action, number); } }