X-Git-Url: http://git.nikiroo.be/?a=blobdiff_plain;f=src%2Fbe%2Fnikiroo%2Fjvcard%2Ftui%2FKeyAction.java;h=5686e2edaa7fea1d079c22776f37a1eab2b0deb9;hb=296a0b75515b3a7424b98292c87cbbf2272b73f9;hp=e6aad034a2627da68f1961b18c2d82f879fdbe28;hpb=a3b510ab4bf89a7a2a05f3851ffe0f030b8a78f4;p=jvcard.git diff --git a/src/be/nikiroo/jvcard/tui/KeyAction.java b/src/be/nikiroo/jvcard/tui/KeyAction.java index e6aad03..5686e2e 100644 --- a/src/be/nikiroo/jvcard/tui/KeyAction.java +++ b/src/be/nikiroo/jvcard/tui/KeyAction.java @@ -1,5 +1,7 @@ package be.nikiroo.jvcard.tui; +import java.io.File; + import be.nikiroo.jvcard.Card; import be.nikiroo.jvcard.Contact; import be.nikiroo.jvcard.Data; @@ -24,12 +26,32 @@ public class KeyAction { * @author niki * */ - enum Mode { - NONE, MOVE, BACK, HELP, CONTACT_LIST, CONTACT_DETAILS, SWICTH_FORMAT, + public enum Mode { + NONE, MOVE, BACK, HELP, FILE_LIST, CONTACT_LIST, CONTACT_DETAILS, EDIT_DETAIL, DELETE_CONTACT, SAVE_CARD, } - enum DataType { - CONTACT, CARD, DATA, NONE + public enum DataType { + /** + * A list of Card {@link File}s. + */ + CARD_FILES, + /** + * Contains a list of contacts. + */ + CARD, + /** + * All the known informations about a specific contact person or + * company. + */ + CONTACT, + /** + * An information about a contact. + */ + DATA, + /** + * Empty. + */ + NONE } private StringId id; @@ -124,14 +146,14 @@ public class KeyAction { return null; } - // override this one if needed + // override this one if needed, DO NOT process here as it will be call a lot public Object getObject() { return null; } /** * The method which is called when the action is performed. You can subclass - * it if you want to customize the action (by default, it just accepts the + * it if you want to customise the action (by default, it just accepts the * mode change (see {@link KeyAction#getMode}). * * @return false to cancel mode change