快速为view的工具条中加个下拉列表2
1.初始化Action testAction
class InnerAction extends Action{ private String text; InnerAction(String text){ super(text); this.text = text; } @Override public void run() { super.run(); if("One".equals(text)){ //do one something }else{ //do two something } } }