Ignore:
Timestamp:
2015-05-17T06:02:07+02:00 (10 years ago)
Author:
Don-vip
Message:

code style - A getX() method which returns a boolean should be named isX()

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/tools/Shortcut.java

    r8378 r8380  
    8282    }
    8383
    84     public boolean getAssignedDefault() {
     84    public boolean isAssignedDefault() {
    8585        return assignedDefault;
    8686    }
    8787
    88     public boolean getAssignedUser() {
     88    public boolean isAssignedUser() {
    8989        return assignedUser;
    9090    }
    9191
    92     public boolean getAutomatic() {
     92    public boolean isAutomatic() {
    9393        return automatic;
    9494    }
     
    9898    }
    9999
    100     private boolean getReset() {
     100    private boolean isReset() {
    101101        return reset;
    102102    }
     
    167167    // get a string that can be put into the preferences
    168168    private boolean save() {
    169         if (getAutomatic() || getReset() || !getAssignedUser()) {
     169        if (isAutomatic() || isReset() || !isAssignedUser()) {
    170170            return Main.pref.putCollection("shortcut.entry."+shortText, null);
    171171        } else {
     
    316316
    317317        for(Shortcut sc : newshortcuts) {
    318             if (sc.getAssignedUser()
     318            if (sc.isAssignedUser()
    319319            && findShortcut(sc.getAssignedKey(), sc.getAssignedModifier()) == null) {
    320320                shortcuts.put(sc.getShortText(), sc);
     
    323323        // Shortcuts at their default values
    324324        for(Shortcut sc : newshortcuts) {
    325             if (!sc.getAssignedUser() && sc.getAssignedDefault()
     325            if (!sc.isAssignedUser() && sc.isAssignedDefault()
    326326            && findShortcut(sc.getAssignedKey(), sc.getAssignedModifier()) == null) {
    327327                shortcuts.put(sc.getShortText(), sc);
     
    330330        // Shortcuts that were automatically moved
    331331        for(Shortcut sc : newshortcuts) {
    332             if (!sc.getAssignedUser() && !sc.getAssignedDefault()
     332            if (!sc.isAssignedUser() && !sc.isAssignedDefault()
    333333            && findShortcut(sc.getAssignedKey(), sc.getAssignedModifier()) == null) {
    334334                shortcuts.put(sc.getShortText(), sc);
Note: See TracChangeset for help on using the changeset viewer.