Package javax.microedition.lcdui

Examples of javax.microedition.lcdui.ChoiceGroup


            fileSelectScreen = new FileSelectScreen(display);
            fileSelectScreen.setListener(this);
        }

        // ---------------------------------------------------------------
        newGameBoardSize = new ChoiceGroup(T._("Board Size"), Choice.POPUP, boardSizeList, null);
        newGameBoardSize.setSelectedIndex(0, true);
        newGameCustomBoardSize = new TextField(T._("Custom Value"), null, 2, TextField.NUMERIC);
        newGameHandicap = new TextField(T._("Handicap"), "0", 1, TextField.NUMERIC);
        newGameKomi = new TextField(T._("Komi"), "5.5", 8, TextField.DECIMAL);
        newGameRuleSet = new ChoiceGroup(T._("Rule Set"), Choice.POPUP, ruleSetList, null);
        newGameRuleSet.setSelectedIndex(0, true);
        newGameTimeSystem = new ChoiceGroup(T._("Time System"), Choice.POPUP, timeSystemList, null);
        newGameTimeSystem.setSelectedIndex(0, true);
        newGameMainTime = new TextField(T._("Main Time"), "180", 5, TextField.NUMERIC);
        newGameByoYomiTime = new TextField(T._("Byo-Yomi Time"), "30", 5, TextField.NUMERIC);
        newGameByoYomiAttr = new TextField(T._("Byo-Yomi Attr"), "5", 5, TextField.NUMERIC);

        newGameWhitePlayerName = new TextField(T._("White"), T._("White"), 32, TextField.ANY);
        newGameBlackPlayerName = new TextField(T._("Black"), T._("Black"), 32, TextField.ANY);

        newGameForm = new Form(T._("New game"));
        newGameForm.setCommandListener(this);
        newGameForm.addCommand(startCommand);
        newGameForm.addCommand(backCommand);
        newGameForm.append(newGameRuleSet);
        newGameForm.append(newGameBoardSize);
        newGameForm.append(newGameCustomBoardSize);
        newGameForm.append(newGameHandicap);
        newGameForm.append(newGameKomi);
        newGameForm.append(newGameTimeSystem);
        newGameForm.append(newGameMainTime);
        newGameForm.append(newGameByoYomiTime);
        newGameForm.append(newGameByoYomiAttr);
        newGameForm.append(newGameWhitePlayerName);
        newGameForm.append(newGameBlackPlayerName);

        // ---------------------------------------------------------------
        optPlayForm = new Form(T._("Play mode"));
        optPlayForm.setCommandListener(this);
        optPlayForm.addCommand(backCommand);
        optPlaySwitches = new ChoiceGroup(T._("On board"), Choice.MULTIPLE, playOptList, null);
        optPlaySwitches.setSelectedIndex(PLAY_OPT_MOVE_STATUS, true); // default show move status
        optPlayCommentLines = new TextField(T._("Comment lines"), "0", 1, TextField.NUMERIC);
        optPlayForm.append(optPlaySwitches);
        optPlayForm.append(optPlayCommentLines);

        optProbForm = new Form(T._("Problem mode"));
        optProbForm.setCommandListener(this);
        optProbForm.addCommand(backCommand);
        optProbSwitches = new ChoiceGroup(T._("On board"), Choice.MULTIPLE, probOptList, null);
        optProbSwitches.setSelectedIndex(PROB_OPT_COLOR_TO_PLAY, true);
        optProbSwitches.setSelectedIndex(PROB_OPT_SOLVED_FAILED, true);
        optProbCommentLines = new TextField(T._("Comment lines"), "1", 1, TextField.NUMERIC);
        optProbForm.append(optProbSwitches);
        optProbForm.append(optProbCommentLines);

        optGenForm = new Form(T._("General"));
        optGenForm.setCommandListener(this);
        optGenForm.addCommand(backCommand);
        optGenSwitches = new ChoiceGroup(null, Choice.MULTIPLE, genOptList, null);
        optGenSwitches.setSelectedIndex(GEN_OPT_SOUND, true);
        optCommentFontSize = new TextField(T._("Comment font size"), "14", 2, TextField.NUMERIC);
        optGenForm.append(optGenSwitches);
        optGenForm.append(optCommentFontSize);

        optForm = new List(T._("Options"), Choice.IMPLICIT, optGroupList, null);
        optForm.setCommandListener(this);
        optForm.addCommand(backCommand);
        optForm.addCommand(selectCommand);

        // -- In-game submenus -------------------------------------------
        igProblemMenuList = new List(T._("Problem"), Choice.IMPLICIT, igProblemMenuItems, null);
        igProblemMenuList.setCommandListener(this);
        igProblemMenuList.addCommand(backCommand);
        igPlayMenuList = new List(T._("Play"), Choice.IMPLICIT, igPlayMenuItems, null);
        igPlayMenuList.setCommandListener(this);
        igPlayMenuList.addCommand(backCommand);
        igViewMenuList = new List(T._("View"), Choice.IMPLICIT, igViewMenuItems, null);
        igViewMenuList.setCommandListener(this);
        igViewMenuList.addCommand(backCommand);
        igScoreMenuList = new List(T._("Score"), Choice.IMPLICIT, igScoreMenuItems, null);
        igScoreMenuList.setCommandListener(this);
        igScoreMenuList.addCommand(backCommand);

        // -- Problem filter ---------------------------------------------
        probFilterForm = new Form(T._("Problem filter"));
        probFilterForm.setCommandListener(this);
        if (fileSelectScreen != null)
            probFilterForm.addCommand(updPathsCommand);
        probFilterForm.addCommand(startCommand);
        probFilterForm.addCommand(backCommand);

        probFilterGenre = new ChoiceGroup(T._("Genre"), Choice.POPUP);
        //probFilterGenre.setSelectedIndex(0, true);
        probFilterDiffFrom = new ChoiceGroup(T._("Difficulty From"), Choice.POPUP, levelList, null);
        probFilterDiffFrom.setSelectedIndex(0, true);
        probFilterDiffTo = new ChoiceGroup(T._("Difficulty To"), ChoiceGroup.POPUP, levelList, null);
        probFilterDiffTo.setSelectedIndex(0, true);
        probFilterDiffTo.setSelectedIndex(levelList.length - 1, true);
        probFilterSortByGenre = new ChoiceGroup(T._("Sort By Genre"), ChoiceGroup.POPUP, sortList, null);
        probFilterSortByGenre.setSelectedIndex(0, true);
        probFilterSortByDifficulty = new ChoiceGroup(T._("Sort By Difficulty"), ChoiceGroup.POPUP, sortList, null);
        probFilterSortByDifficulty.setSelectedIndex(0, true);
        probFilterSortByPopularity = new ChoiceGroup(T._("Sort By Popularity"), ChoiceGroup.POPUP, sortList, null);
        probFilterSortByPopularity.setSelectedIndex(0, true);
        probFilterShow = new ChoiceGroup(T._("Show"), ChoiceGroup.MULTIPLE, showList, null);
        probFilterShow.setSelectedIndex(0, true);
        probFilterShow.setSelectedIndex(2, true);
        probFilterShow.setSelectedIndex(3, true);
        probFilterPath = new ChoiceGroup(T._("Path"), ChoiceGroup.MULTIPLE);

        probFilterForm.append(probFilterGenre);
        probFilterForm.append(probFilterDiffFrom);
        probFilterForm.append(probFilterDiffTo);
        probFilterForm.append(probFilterShow);
View Full Code Here


            props.append(new StringItem(T._("Location"), currDirName));
            props.append(new StringItem(T._("Type"), fc.isDirectory() ? T._("Directory") : T._("Regular File")));
            props.append(new StringItem(T._("Size"), Long.toString((fc.isDirectory() ? fc.directorySize(true) : fc.fileSize()))));
            props.append(new StringItem(T._("Modified"), myDate(fc.lastModified())));

            ChoiceGroup attrs = new ChoiceGroup(T._("Attributes"), Choice.MULTIPLE, attrList, null);
            attrs.setSelectedFlags(new boolean[] { fc.canRead(), fc.canWrite(), fc.isHidden() });
            props.append(attrs);

            if (fileName.toLowerCase().endsWith(".sgf"))
                try {
                    StringBuffer sb = new StringBuffer();
View Full Code Here

    }

    void createFile() {
        Form creator = new Form(T._("New File"));
        nameInput = new TextField(T._("Enter Name"), null, 256, TextField.ANY);
        typeInput = new ChoiceGroup(T._("Enter File Type"), Choice.EXCLUSIVE,
                typeList, iconList);
        creator.append(nameInput);
        creator.append(typeInput);
        creator.addCommand(newOkCommand);
        creator.addCommand(backToBCommand);
View Full Code Here

            fileSelectScreen = new FileSelectScreen(display);
            fileSelectScreen.setListener(this);
        }

        // ---------------------------------------------------------------
        newGameBoardSize = new ChoiceGroup(T._("Board Size"), Choice.POPUP, boardSizeList, null);
        newGameBoardSize.setSelectedIndex(0, true);
        newGameCustomBoardSize = new TextField(T._("Custom Value"), null, 2, TextField.NUMERIC);
        newGameHandicap = new TextField(T._("Handicap"), "0", 1, TextField.NUMERIC);
        newGameKomi = new TextField(T._("Komi"), "5.5", 8, TextField.DECIMAL);
        newGameRuleSet = new ChoiceGroup(T._("Rule Set"), Choice.POPUP, ruleSetList, null);
        newGameRuleSet.setSelectedIndex(0, true);
        newGameTimeSystem = new ChoiceGroup(T._("Time System"), Choice.POPUP, timeSystemList, null);
        newGameTimeSystem.setSelectedIndex(0, true);
        newGameMainTime = new TextField(T._("Main Time"), "180", 5, TextField.NUMERIC);
        newGameByoYomiTime = new TextField(T._("Byo-Yomi Time"), "30", 5, TextField.NUMERIC);
        newGameByoYomiAttr = new TextField(T._("Byo-Yomi Attr"), "5", 5, TextField.NUMERIC);

        newGameWhitePlayerName = new TextField(T._("White"), T._("White"), 32, TextField.ANY);
        newGameBlackPlayerName = new TextField(T._("Black"), T._("Black"), 32, TextField.ANY);

        newGameForm = new Form(T._("New game"));
        newGameForm.setCommandListener(this);
        newGameForm.addCommand(startCommand);
        newGameForm.addCommand(backCommand);
        newGameForm.append(newGameRuleSet);
        newGameForm.append(newGameBoardSize);
        newGameForm.append(newGameCustomBoardSize);
        newGameForm.append(newGameHandicap);
        newGameForm.append(newGameKomi);
        newGameForm.append(newGameTimeSystem);
        newGameForm.append(newGameMainTime);
        newGameForm.append(newGameByoYomiTime);
        newGameForm.append(newGameByoYomiAttr);
        newGameForm.append(newGameWhitePlayerName);
        newGameForm.append(newGameBlackPlayerName);

        // ---------------------------------------------------------------
        optPlayForm = new Form(T._("Play mode"));
        optPlayForm.setCommandListener(this);
        optPlayForm.addCommand(backCommand);
        optPlaySwitches = new ChoiceGroup(T._("On board"), Choice.MULTIPLE, playOptList, null);
        optPlaySwitches.setSelectedIndex(PLAY_OPT_MOVE_STATUS, true); // default show move status
        optPlayCommentLines = new TextField(T._("Comment lines"), "0", 1, TextField.NUMERIC);
        optPlayForm.append(optPlaySwitches);
        optPlayForm.append(optPlayCommentLines);

        optProbForm = new Form(T._("Problem mode"));
        optProbForm.setCommandListener(this);
        optProbForm.addCommand(backCommand);
        optProbSwitches = new ChoiceGroup(T._("On board"), Choice.MULTIPLE, probOptList, null);
        optProbSwitches.setSelectedIndex(PROB_OPT_COLOR_TO_PLAY, true);
        optProbSwitches.setSelectedIndex(PROB_OPT_SOLVED_FAILED, true);
        optProbCommentLines = new TextField(T._("Comment lines"), "1", 1, TextField.NUMERIC);
        optProbForm.append(optProbSwitches);
        optProbForm.append(optProbCommentLines);

        optGenForm = new Form(T._("General"));
        optGenForm.setCommandListener(this);
        optGenForm.addCommand(backCommand);
        optGenSwitches = new ChoiceGroup(null, Choice.MULTIPLE, genOptList, null);
        optGenSwitches.setSelectedIndex(GEN_OPT_SOUND, true);
        optCommentFontSize = new TextField(T._("Comment font size"), "14", 2, TextField.NUMERIC);
        optGenForm.append(optGenSwitches);
        optGenForm.append(optCommentFontSize);

        optForm = new List(T._("Options"), Choice.IMPLICIT, optGroupList, null);
        optForm.setCommandListener(this);
        optForm.addCommand(backCommand);
        optForm.addCommand(selectCommand);

        // -- In-game submenus -------------------------------------------
        igProblemMenuList = new List(T._("Problem"), Choice.IMPLICIT, igProblemMenuItems, null);
        igProblemMenuList.setCommandListener(this);
        igProblemMenuList.addCommand(backCommand);
        igPlayMenuList = new List(T._("Play"), Choice.IMPLICIT, igPlayMenuItems, null);
        igPlayMenuList.setCommandListener(this);
        igPlayMenuList.addCommand(backCommand);
        igViewMenuList = new List(T._("View"), Choice.IMPLICIT, igViewMenuItems, null);
        igViewMenuList.setCommandListener(this);
        igViewMenuList.addCommand(backCommand);
        igScoreMenuList = new List(T._("Score"), Choice.IMPLICIT, igScoreMenuItems, null);
        igScoreMenuList.setCommandListener(this);
        igScoreMenuList.addCommand(backCommand);

        // -- Problem filter ---------------------------------------------
        probFilterForm = new Form(T._("Problem filter"));
        probFilterForm.setCommandListener(this);
        if (fileSelectScreen != null)
            probFilterForm.addCommand(updPathsCommand);
        probFilterForm.addCommand(startCommand);
        probFilterForm.addCommand(backCommand);

        probFilterGenre = new ChoiceGroup(T._("Genre"), Choice.POPUP);
        //probFilterGenre.setSelectedIndex(0, true);
        probFilterDiffFrom = new ChoiceGroup(T._("Difficulty From"), Choice.POPUP, levelList, null);
        probFilterDiffFrom.setSelectedIndex(0, true);
        probFilterDiffTo = new ChoiceGroup(T._("Difficulty To"), ChoiceGroup.POPUP, levelList, null);
        probFilterDiffTo.setSelectedIndex(0, true);
        probFilterDiffTo.setSelectedIndex(levelList.length - 1, true);
        probFilterSortByGenre = new ChoiceGroup(T._("Sort By Genre"), ChoiceGroup.POPUP, sortList, null);
        probFilterSortByGenre.setSelectedIndex(0, true);
        probFilterSortByDifficulty = new ChoiceGroup(T._("Sort By Difficulty"), ChoiceGroup.POPUP, sortList, null);
        probFilterSortByDifficulty.setSelectedIndex(0, true);
        probFilterSortByPopularity = new ChoiceGroup(T._("Sort By Popularity"), ChoiceGroup.POPUP, sortList, null);
        probFilterSortByPopularity.setSelectedIndex(0, true);
        probFilterShow = new ChoiceGroup(T._("Show"), ChoiceGroup.MULTIPLE, showList, null);
        probFilterShow.setSelectedIndex(0, true);
        probFilterShow.setSelectedIndex(2, true);
        probFilterShow.setSelectedIndex(3, true);
        probFilterPath = new ChoiceGroup(T._("Path"), ChoiceGroup.MULTIPLE);

        probFilterForm.append(probFilterGenre);
        probFilterForm.append(probFilterDiffFrom);
        probFilterForm.append(probFilterDiffTo);
        probFilterForm.append(probFilterShow);
View Full Code Here

            fileSelectScreen = new FileSelectScreen(display);
            fileSelectScreen.setListener(this);
        }

        // ---------------------------------------------------------------
        newGameBoardSize = new ChoiceGroup(T._("Board Size"), Choice.POPUP, boardSizeList, null);
        newGameBoardSize.setSelectedIndex(0, true);
        newGameCustomBoardSize = new TextField(T._("Custom Value"), null, 2, TextField.NUMERIC);
        newGameHandicap = new TextField(T._("Handicap"), "0", 1, TextField.NUMERIC);
        newGameKomi = new TextField(T._("Komi"), "5.5", 8, TextField.DECIMAL);
        newGameRuleSet = new ChoiceGroup(T._("Rule Set"), Choice.POPUP, ruleSetList, null);
        newGameRuleSet.setSelectedIndex(0, true);
        newGameTimeSystem = new ChoiceGroup(T._("Time System"), Choice.POPUP, timeSystemList, null);
        newGameTimeSystem.setSelectedIndex(0, true);
        newGameMainTime = new TextField(T._("Main Time"), "180", 5, TextField.NUMERIC);
        newGameByoYomiTime = new TextField(T._("Byo-Yomi Time"), "30", 5, TextField.NUMERIC);
        newGameByoYomiAttr = new TextField(T._("Byo-Yomi Attr"), "5", 5, TextField.NUMERIC);

        newGameWhitePlayerName = new TextField(T._("White"), T._("White"), 32, TextField.ANY);
        newGameBlackPlayerName = new TextField(T._("Black"), T._("Black"), 32, TextField.ANY);

        newGameForm = new Form(T._("New game"));
        newGameForm.setCommandListener(this);
        newGameForm.addCommand(startCommand);
        newGameForm.addCommand(backCommand);
        newGameForm.append(newGameRuleSet);
        newGameForm.append(newGameBoardSize);
        newGameForm.append(newGameCustomBoardSize);
        newGameForm.append(newGameHandicap);
        newGameForm.append(newGameKomi);
        newGameForm.append(newGameTimeSystem);
        newGameForm.append(newGameMainTime);
        newGameForm.append(newGameByoYomiTime);
        newGameForm.append(newGameByoYomiAttr);
        newGameForm.append(newGameWhitePlayerName);
        newGameForm.append(newGameBlackPlayerName);

        // ---------------------------------------------------------------
        optPlayForm = new Form(T._("Play mode"));
        optPlayForm.setCommandListener(this);
        optPlayForm.addCommand(backCommand);
        optPlaySwitches = new ChoiceGroup(T._("On board"), Choice.MULTIPLE, playOptList, null);
        optPlaySwitches.setSelectedIndex(PLAY_OPT_MOVE_STATUS, true); // default show move status
        optPlayCommentLines = new TextField(T._("Comment lines"), "0", 1, TextField.NUMERIC);
        optPlayForm.append(optPlaySwitches);
        optPlayForm.append(optPlayCommentLines);

        optProbForm = new Form(T._("Problem mode"));
        optProbForm.setCommandListener(this);
        optProbForm.addCommand(backCommand);
        optProbSwitches = new ChoiceGroup(T._("On board"), Choice.MULTIPLE, probOptList, null);
        optProbSwitches.setSelectedIndex(PROB_OPT_COLOR_TO_PLAY, true);
        optProbSwitches.setSelectedIndex(PROB_OPT_SOLVED_FAILED, true);
        optProbCommentLines = new TextField(T._("Comment lines"), "1", 1, TextField.NUMERIC);
        optProbForm.append(optProbSwitches);
        optProbForm.append(optProbCommentLines);

        optGenForm = new Form(T._("General"));
        optGenForm.setCommandListener(this);
        optGenForm.addCommand(backCommand);
        optGenSwitches = new ChoiceGroup(null, Choice.MULTIPLE, genOptList, null);
        optGenSwitches.setSelectedIndex(GEN_OPT_SOUND, true);
        optCommentFontSize = new TextField(T._("Comment font size"), "14", 2, TextField.NUMERIC);
        optGenForm.append(optGenSwitches);
        optGenForm.append(optCommentFontSize);

        optForm = new List(T._("Options"), Choice.IMPLICIT, optGroupList, null);
        optForm.setCommandListener(this);
        optForm.addCommand(backCommand);
        optForm.addCommand(selectCommand);

        // -- In-game submenus -------------------------------------------
        igProblemMenuList = new List(T._("Problem"), Choice.IMPLICIT, igProblemMenuItems, null);
        igProblemMenuList.setCommandListener(this);
        igProblemMenuList.addCommand(backCommand);
        igPlayMenuList = new List(T._("Play"), Choice.IMPLICIT, igPlayMenuItems, null);
        igPlayMenuList.setCommandListener(this);
        igPlayMenuList.addCommand(backCommand);
        igViewMenuList = new List(T._("View"), Choice.IMPLICIT, igViewMenuItems, null);
        igViewMenuList.setCommandListener(this);
        igViewMenuList.addCommand(backCommand);
        igScoreMenuList = new List(T._("Score"), Choice.IMPLICIT, igScoreMenuItems, null);
        igScoreMenuList.setCommandListener(this);
        igScoreMenuList.addCommand(backCommand);

        // -- Problem filter ---------------------------------------------
        probFilterForm = new Form(T._("Problem filter"));
        probFilterForm.setCommandListener(this);
        if (fileSelectScreen != null)
            probFilterForm.addCommand(updPathsCommand);
        probFilterForm.addCommand(startCommand);
        probFilterForm.addCommand(backCommand);

        probFilterGenre = new ChoiceGroup(T._("Genre"), Choice.POPUP);
        //probFilterGenre.setSelectedIndex(0, true);
        probFilterDiffFrom = new ChoiceGroup(T._("Difficulty From"), Choice.POPUP, levelList, null);
        probFilterDiffFrom.setSelectedIndex(0, true);
        probFilterDiffTo = new ChoiceGroup(T._("Difficulty To"), ChoiceGroup.POPUP, levelList, null);
        probFilterDiffTo.setSelectedIndex(0, true);
        probFilterDiffTo.setSelectedIndex(levelList.length - 1, true);
        probFilterSortByGenre = new ChoiceGroup(T._("Sort By Genre"), ChoiceGroup.POPUP, sortList, null);
        probFilterSortByGenre.setSelectedIndex(0, true);
        probFilterSortByDifficulty = new ChoiceGroup(T._("Sort By Difficulty"), ChoiceGroup.POPUP, sortList, null);
        probFilterSortByDifficulty.setSelectedIndex(0, true);
        probFilterSortByPopularity = new ChoiceGroup(T._("Sort By Popularity"), ChoiceGroup.POPUP, sortList, null);
        probFilterSortByPopularity.setSelectedIndex(0, true);
        probFilterShow = new ChoiceGroup(T._("Show"), ChoiceGroup.MULTIPLE, showList, null);
        probFilterShow.setSelectedIndex(0, true);
        probFilterShow.setSelectedIndex(2, true);
        probFilterShow.setSelectedIndex(3, true);
        probFilterPath = new ChoiceGroup(T._("Path"), ChoiceGroup.MULTIPLE);

        probFilterForm.append(probFilterGenre);
        probFilterForm.append(probFilterDiffFrom);
        probFilterForm.append(probFilterDiffTo);
        probFilterForm.append(probFilterShow);
View Full Code Here

            props.append(new StringItem(T._("Location"), currDirName));
            props.append(new StringItem(T._("Type"), fc.isDirectory() ? T._("Directory") : T._("Regular File")));
            props.append(new StringItem(T._("Size"), Long.toString((fc.isDirectory() ? fc.directorySize(true) : fc.fileSize()))));
            props.append(new StringItem(T._("Modified"), myDate(fc.lastModified())));

            ChoiceGroup attrs = new ChoiceGroup(T._("Attributes"), Choice.MULTIPLE, attrList, null);
            attrs.setSelectedFlags(new boolean[] { fc.canRead(), fc.canWrite(), fc.isHidden() });
            props.append(attrs);

            if (fileName.toLowerCase().endsWith(".sgf"))
                try {
                    StringBuffer sb = new StringBuffer();
View Full Code Here

    }

    void createFile() {
        Form creator = new Form(T._("New File"));
        nameInput = new TextField(T._("Enter Name"), null, 256, TextField.ANY);
        typeInput = new ChoiceGroup(T._("Enter File Type"), Choice.EXCLUSIVE,
                typeList, iconList);
        creator.append(nameInput);
        creator.append(typeInput);
        creator.addCommand(newOkCommand);
        creator.addCommand(backToBCommand);
View Full Code Here

            props.append(new StringItem(T._("Location"), currDirName));
            props.append(new StringItem(T._("Type"), fc.isDirectory() ? T._("Directory") : T._("Regular File")));
            props.append(new StringItem(T._("Size"), Long.toString((fc.isDirectory() ? fc.directorySize(true) : fc.fileSize()))));
            props.append(new StringItem(T._("Modified"), myDate(fc.lastModified())));

            ChoiceGroup attrs = new ChoiceGroup(T._("Attributes"), Choice.MULTIPLE, attrList, null);
            attrs.setSelectedFlags(new boolean[] { fc.canRead(), fc.canWrite(), fc.isHidden() });
            props.append(attrs);

            if (fileName.toLowerCase().endsWith(".sgf"))
                try {
                    StringBuffer sb = new StringBuffer();
View Full Code Here

    }

    void createFile() {
        Form creator = new Form(T._("New File"));
        nameInput = new TextField(T._("Enter Name"), null, 256, TextField.ANY);
        typeInput = new ChoiceGroup(T._("Enter File Type"), Choice.EXCLUSIVE,
                typeList, iconList);
        creator.append(nameInput);
        creator.append(typeInput);
        creator.addCommand(newOkCommand);
        creator.addCommand(backToBCommand);
View Full Code Here

    private Choice appendChoice( final String label, final String[] choices )
    {
        final Spacer spacer = new Spacer( POPUP_MENUS_SHIFT, 0 );
        spacer.setLayout( Item.LAYOUT_NEWLINE_BEFORE + Item.LAYOUT_2 );
        final ChoiceGroup group = new ChoiceGroup( null, Choice.POPUP );
        group.setLayout( Item.LAYOUT_2 );
        for( int choice = 0; choice < choices.length; ++choice )
            group.append( choices[choice], null );
        appendMessage( label );
        append( spacer );
        append( group );
        return group;
    }
View Full Code Here

TOP

Related Classes of javax.microedition.lcdui.ChoiceGroup

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.