package be.nikiroo.jvcard.tui.panes;
import java.awt.Image;
-import java.util.Base64;
import java.util.LinkedList;
import java.util.List;
+import javax.xml.bind.DatatypeConverter;
import javax.swing.ImageIcon;
import be.nikiroo.jvcard.Contact;
if (encoding != null && encoding.getValue() != null
&& encoding.getValue().equalsIgnoreCase("b")) {
- image = new ImageIcon(Base64.getDecoder().decode(
+ image = new ImageIcon(DatatypeConverter.parseBase64Binary(
photo.getValue())).getImage();
}
}
return false;
}
});
+ // TODO: add "normal" edit and remove this one into RAW edit
+ actions.add(new KeyAction(Mode.CONTACT_DETAILS_RAW, 'e',
+ Trans.StringId.KEY_ACTION_EDIT_CONTACT) {
+ @Override
+ public Object getObject() {
+ return contact;
+ }
+ });
return actions;
}