GamlEditorTickUpdater.java 文件源码

java
阅读 25 收藏 0 点赞 0 评论 0

项目:gama 作者:
@Override
protected void updateEditorImage(final XtextEditor editor) {
    Severity severity = null;
    //
    // try {
    severity = getSeverity(editor);
    //
    // } catch (ResourceException e) {
    // // do nothing, emitted when a marker cannot be found
    // }
    ImageDescriptor descriptor = null;
    if (severity == null || severity == Severity.INFO) {
        descriptor = GamaIcons.create(IGamaIcons.OVERLAY_OK).descriptor();
    } else if (severity == Severity.ERROR) {
        descriptor = GamaIcons.create("overlay.error2").descriptor();
    } else if (severity == Severity.WARNING) {
        descriptor = GamaIcons.create("overlay.warning2").descriptor();
    } else {
        super.updateEditorImage(editor);
        return;
    }
    final DecorationOverlayIcon decorationOverlayIcon = new DecorationOverlayIcon(editor.getDefaultImage(),
            descriptor, IDecoration.BOTTOM_LEFT);
    scheduleUpdateEditor(decorationOverlayIcon);

}
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号