Ignore:
Timestamp:
2017-08-22T22:26:32+02:00 (7 years ago)
Author:
Don-vip
Message:

see #15182 - deprecate all Main logging methods and introduce suitable replacements in Logging for most of them

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/gui/MapStatus.java

    r12391 r12620  
    7979import org.openstreetmap.josm.tools.GBC;
    8080import org.openstreetmap.josm.tools.ImageProvider;
     81import org.openstreetmap.josm.tools.Logging;
    8182import org.openstreetmap.josm.tools.Utils;
    8283
     
    203204        public void appendLogMessage(String message) {
    204205            if (message != null && !message.isEmpty()) {
    205                 Main.info("appendLogMessage not implemented for background tasks. Message was: " + message);
     206                Logging.info("appendLogMessage not implemented for background tasks. Message was: " + message);
    206207            }
    207208        }
     
    357358                    oldMousePos = ms.mousePos;
    358359                } catch (ConcurrentModificationException ex) {
    359                     Main.warn(ex);
     360                    Logging.warn(ex);
    360361                } finally {
    361362                    if (ds != null) {
     
    415416                        EventQueue.invokeAndWait(new CollectorWorker(ms));
    416417                    } catch (InvocationTargetException e) {
    417                         Main.warn(e);
     418                        Logging.warn(e);
    418419                    }
    419420                }
    420421            } catch (InterruptedException e) {
    421422                // Occurs frequently during JOSM shutdown, log set to trace only
    422                 Main.trace("InterruptedException in "+MapStatus.class.getSimpleName());
     423                Logging.trace("InterruptedException in "+MapStatus.class.getSimpleName());
    423424                Thread.currentThread().interrupt();
    424425            } finally {
     
    686687            incomingMouseState.clear();
    687688            if (!incomingMouseState.offer(ms)) {
    688                 Main.warn("Unable to handle new MouseState: " + ms);
     689                Logging.warn("Unable to handle new MouseState: " + ms);
    689690            }
    690691        }
     
    739740                    AWTEvent.KEY_EVENT_MASK | AWTEvent.MOUSE_EVENT_MASK | AWTEvent.MOUSE_MOTION_EVENT_MASK);
    740741        } catch (SecurityException ex) {
    741             Main.trace(ex);
     742            Logging.trace(ex);
    742743            mv.addMouseMotionListener(mouseMotionListener);
    743744            mv.addKeyListener(keyAdapter);
     
    750751        } catch (SecurityException e) {
    751752            // Don't care, awtListener probably wasn't registered anyway
    752             Main.trace(e);
     753            Logging.trace(e);
    753754        }
    754755        mv.removeMouseMotionListener(mouseMotionListener);
     
    11111112                thread.interrupt();
    11121113            } catch (SecurityException e) {
    1113                 Main.error(e);
     1114                Logging.error(e);
    11141115            }
    11151116        }
Note: See TracChangeset for help on using the changeset viewer.