8068007: [Findbugs] SA com.sun.java.swing.action.ActionManager.manager should be package protect

Fixed java programming style nit

Reviewed-by: dholmes, jbachorik, sspitsyn
This commit is contained in:
Dmitry Samersoff 2015-04-02 13:20:49 -07:00
parent 56a4782b81
commit fcf9563213
2 changed files with 11 additions and 4 deletions

View File

@ -46,6 +46,11 @@ public abstract class ActionManager
return manager;
}
protected static void setInstance(ActionManager m)
{
manager = m;
}
protected abstract void addActions();
protected void addAction(String cmdname, Action action)
@ -90,6 +95,6 @@ public abstract class ActionManager
private HashMap actions;
private static ActionUtilities utilities = new ActionUtilities();
protected static ActionManager manager;
private static ActionManager manager;
}

View File

@ -32,10 +32,12 @@ import com.sun.java.swing.action.ActionManager;
public class HSDBActionManager extends ActionManager {
public static ActionManager getInstance() {
if (manager == null) {
manager = new HSDBActionManager();
ActionManager m = ActionManager.getInstance();
if (m == null) {
m = new HSDBActionManager();
ActionManager.setInstance(m);
}
return manager;
return m;
}
protected void addActions() {