Ignore:
Timestamp:
06/21/19 15:16:05 (5 years ago)
Author:
bln4
Message:

Fixed bug with surrogate inheritance.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/expeditee/gui/FrameGraphics.java

    r1218 r1410  
    3232import org.expeditee.core.Image;
    3333import org.expeditee.core.bounds.PolygonBounds;
     34import org.expeditee.encryption.items.surrogates.Label.LabelResult;
     35import org.expeditee.encryption.items.surrogates.Label;
     36import org.expeditee.encryption.items.surrogates.Surrogate;
    3437import org.expeditee.gio.EcosystemManager;
    3538import org.expeditee.gio.input.KBMInputEvent.Key;
     
    454457                if (i == null) {
    455458                        return;
     459                }
     460               
     461                String encryptionLabel = i.getEncryptionLabel();
     462                if (encryptionLabel != null && encryptionLabel.length() > 0 && !i.isSurrogate()) {
     463                        LabelResult result = Label.resolveKey(encryptionLabel);
     464                        if (result != LabelResult.SuccessResolveLabelToKey) {
     465                                for(Surrogate s: i.getSurrogates()) {
     466                                        PaintItem(s.getSurrogateItem());
     467                                }
     468                                return;
     469                        }
    456470                }
    457471
Note: See TracChangeset for help on using the changeset viewer.