Changeset 12414 in josm


Ignore:
Timestamp:
2017-06-18T01:36:38+02:00 (7 years ago)
Author:
Don-vip
Message:

fix more SonarQube issues

Location:
trunk/src/org/openstreetmap/josm
Files:
1 added
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/data/osm/FilterModel.java

    r12400 r12414  
    4242    private boolean changed;
    4343
    44     /**
    45      * Constructs a new {@code FilterTableModel}.
    46      */
    47     public FilterModel() {
    48     }
    49 
    50     private final transient List<Filter> filters = new LinkedList<>();
    51     private final transient FilterMatcher filterMatcher = new FilterMatcher();
     44    private final List<Filter> filters = new LinkedList<>();
     45    private final FilterMatcher filterMatcher = new FilterMatcher();
    5246
    5347    private void updateFilterMatcher() {
  • trunk/src/org/openstreetmap/josm/gui/autofilter/AutoFilterRule.java

    r12403 r12414  
    9999            new AutoFilterRule("voltage", 5)
    100100                .setValueFormatter(s -> s.replaceAll("000$", "k") + 'V')
    101                 .setValueComparator(Comparator.comparingInt(s -> Integer.parseInt(s)))
     101                .setValueComparator(Comparator.comparingInt(Integer::parseInt))
    102102        };
    103103    }
  • trunk/src/org/openstreetmap/josm/io/audio/JavaFxMediaPlayer.java

    r12413 r12414  
    3535    private final ListenerList<AudioListener> listeners = ListenerList.create();
    3636
    37     private URL url;
    3837    private MediaPlayer mediaPlayer;
    3938
     
    5049
    5150        // Note, this method is called on the FX Application Thread
    52         PlatformImpl.startup(() -> startupLatch.countDown());
     51        PlatformImpl.startup(startupLatch::countDown);
    5352
    5453        // Wait for FX platform to start
     
    5958    public void play(Execute command, State stateChange, URL playingUrl) throws AudioException, IOException {
    6059        try {
    61             url = command.url();
     60            final URL url = command.url();
    6261            if (playingUrl != url) {
    6362                if (mediaPlayer != null) {
     
    6968                }
    7069                mediaPlayer = new MediaPlayer(new Media(url.toString()));
    71                 mediaPlayer.setOnPlaying(() -> {
    72                     listeners.fireEvent(l -> l.playing(url));
    73                 });
     70                mediaPlayer.setOnPlaying(() ->
     71                    listeners.fireEvent(l -> l.playing(url))
     72                );
    7473            }
    7574            mediaPlayer.setRate(command.speed());
  • trunk/src/org/openstreetmap/josm/io/audio/JavaSoundPlayer.java

    r12413 r12414  
    3737
    3838    private double bytesPerSecond;
    39     private byte[] abData = new byte[chunk];
     39    private final byte[] abData = new byte[chunk];
    4040
    4141    private double position; // seconds
Note: See TracChangeset for help on using the changeset viewer.