Changeset 4540 in josm for trunk/src/org


Ignore:
Timestamp:
2011-10-24T15:00:55+02:00 (13 years ago)
Author:
Don-vip
Message:

see #6821 - Proper error dialog with HTTP 509 error code

File:
1 edited

Legend:

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

    r4020 r4540  
    299299
    300300    /**
     301     * Explains a {@see OsmApiException} which was thrown because of a
     302     * bandwidth limit (HTTP 509)
     303     *
     304     * @param e the exception
     305     */
     306    public static void explainBandwidthLimitExceeded(OsmApiException e) {
     307        HelpAwareOptionPane.showOptionDialog(
     308                Main.parent,
     309                ExceptionUtil.explainBandwidthLimitExceeded(e),
     310                tr("Bandwidth Limit Exceeded"),
     311                JOptionPane.ERROR_MESSAGE,
     312                ht("/ErrorMessages#BandwidthLimit")
     313        );
     314    }
     315
     316    /**
    301317     * Explains a {@see OsmApiException} with a generic error
    302318     * message.
     
    441457                explainClientTimeout(oae);
    442458                return;
     459            case 509:
     460                explainBandwidthLimitExceeded(oae);
     461                return;
    443462            default:
    444463                explainGenericHttpException(oae);
Note: See TracChangeset for help on using the changeset viewer.