Package javax.swing

Examples of javax.swing.JRadioButton


    PanelBuilder panelBuilder = new PanelBuilder(new FormLayout("5dlu, pref, default:grow",
        "pref, 5dlu, pref, 5dlu, pref, 5dlu, pref, 5dlu, pref"));

    panelBuilder.add(new JLabel(mMainQuestion), cc.xyw(1, 1, 3));
    panelBuilder
        .add(mTitleRb = new JRadioButton(mLocalizer.msg("option.title", "I like this program:")), cc.xy(2, 3));
    panelBuilder.add(mProgramNameTf = new JTextField(), cc.xy(3, 3));
    panelBuilder.add(mTopicRb = new JRadioButton(mLocalizer.msg("option.topic", "I like this subject:")), cc.xy(2, 5));
    panelBuilder.add(mTopicTf = new JTextField(), cc.xy(3, 5));

    panelBuilder.add(mActorsRb = new JRadioButton(mLocalizer.msg("option.actors","I like these actors:")), cc.xy(2,7));
    mActorsCb = new JComboBox();
    mActorsCb.setEditable(true);
    panelBuilder.add(mActorsCb, cc.xy(3,7));
    panelBuilder.setBorder(Borders.DLU4_BORDER);
    panelBuilder.add(expertBtn, cc.xyw(1, 9, 3));
View Full Code Here


      JPanel boxPanel = new JPanel(new FormLayout("10dlu,pref:grow","default,2dlu,default,default"));
      CellConstraints cc = new CellConstraints();
     
      mAutoUpdate = new JCheckBox(mLocalizer.msg("autoUpdateMessage", "Update data automatically"));
     
      mStartUpdate = new JRadioButton(mLocalizer.msg("onStartUp", "Only on TV-Browser startup"), false);
      mRecurrentUpdate = new JRadioButton(mLocalizer.msg("recurrent", "Recurrent"), true);
     
      mStartUpdate.setEnabled(false);
      mRecurrentUpdate.setEnabled(false);
     
      boxPanel.add(mAutoUpdate, cc.xyw(1,1,2));
View Full Code Here

   
    //filter settings
    ButtonGroup filter = new ButtonGroup();
   
    msg = mLocalizer.msg("trayFilterAll", "Filter all programs");
    mFilterAll = new JRadioButton(msg);

    msg = mLocalizer.msg("trayFilterNotMarked", "Filter programs, if not marked");
    checked = Settings.propTrayFilterNotMarked.getBoolean();
    mNoMarkedFiltering = new JRadioButton(msg, checked);

    msg = mLocalizer.msg("trayFilterNot", "Don't filter programs");
    checked = Settings.propTrayFilterNot.getBoolean();
    mNoFiltering = new JRadioButton(msg, checked);
   
    if(!mNoFiltering.isSelected() && !mNoMarkedFiltering.isSelected()) {
      mFilterAll.setSelected(true);
    }
   
View Full Code Here

        "10dlu,pref,5dlu,pref,pref,fill:default:grow,pref"));
    builder.setDefaultDialogBorder();
   
    mIsEnabled = new JCheckBox(mLocalizer.msg("soonEnabled","Show Soon running programs"),Settings.propTraySoonProgramsEnabled.getBoolean());
   
    mShowIconAndName = new JRadioButton(mLocalizer.msg("showIconName","Show channel icon and channel name"),Settings.propTraySoonProgramsContainsName.getBoolean() && Settings.propTraySoonProgramsContainsIcon.getBoolean());
    mShowName = new JRadioButton(mLocalizer.msg("showName","Show channel name"),Settings.propTraySoonProgramsContainsName.getBoolean() && !Settings.propTraySoonProgramsContainsIcon.getBoolean());
    mShowIcon = new JRadioButton(mLocalizer.msg("showIcon","Show channel icon"),!Settings.propTraySoonProgramsContainsName.getBoolean() && Settings.propTraySoonProgramsContainsIcon.getBoolean());
   
    ButtonGroup bg = new ButtonGroup();
    bg.add(mShowIconAndName);
    bg.add(mShowIcon);
    bg.add(mShowName);
View Full Code Here

    mIsEnabled = new JCheckBox(mLocalizer.msg("importantEnabled","Show important programs"),Settings.propTrayImportantProgramsEnabled.getBoolean());
    mIsEnabled.setToolTipText(mLocalizer.msg("importantToolTip","Important programs are all marked programs."));
   
    ButtonGroup bg = new ButtonGroup();
   
    mShowInSubMenu = new JRadioButton(mLocalizer.msg("inSubMenu","in a sub menu"),Settings.propTrayImportantProgramsInSubMenu.getBoolean());
    mShowInTray = new JRadioButton(mLocalizer.msg("inTray","in the tray menu"), !mShowInSubMenu.isSelected());
   
    bg.add(mShowInSubMenu);
    bg.add(mShowInTray);
   
    int maxSizeValue = Settings.propTrayImportantProgramsInSubMenu.getBoolean() ? 30 : 15;
   
    mSize = new JSpinner(new SpinnerNumberModel(Settings.propTrayImportantProgramsSize.getInt(), 1, maxSizeValue, 1));
   
    mShowIconAndName = new JRadioButton(mLocalizer.msg("showIconName","Show channel icon and channel name"),Settings.propTrayImportantProgramsContainsName.getBoolean() && Settings.propTrayImportantProgramsContainsIcon.getBoolean());
    mShowName = new JRadioButton(mLocalizer.msg("showName","Show channel name"),Settings.propTrayImportantProgramsContainsName.getBoolean() && !Settings.propTrayImportantProgramsContainsIcon.getBoolean());
    mShowIcon = new JRadioButton(mLocalizer.msg("showIcon","Show channel icon"),!Settings.propTrayImportantProgramsContainsName.getBoolean() && Settings.propTrayImportantProgramsContainsIcon.getBoolean());
   
    ButtonGroup bg1 = new ButtonGroup();
    bg1.add(mShowIconAndName);
    bg1.add(mShowIcon);
    bg1.add(mShowName);
View Full Code Here

   
    mIsEnabled = new JCheckBox(mLocalizer.msg("nowEnabled","Show Now running programs"),Settings.propTrayNowProgramsEnabled.getBoolean());
   
    ButtonGroup bg = new ButtonGroup();
   
    mShowInSubMenu = new JRadioButton(mLocalizer.msg("inSubMenu","in a sub menu"),Settings.propTrayNowProgramsInSubMenu.getBoolean());
    mShowInTray = new JRadioButton(mLocalizer.msg("inTray","in the tray menu"), !mShowInSubMenu.isSelected());
   
    bg.add(mShowInSubMenu);
    bg.add(mShowInTray);
   
    mShowIconAndName = new JRadioButton(mLocalizer.msg("showIconName","Show channel icon and channel name"),Settings.propTrayNowProgramsContainsName.getBoolean() && Settings.propTrayNowProgramsContainsIcon.getBoolean());
    mShowIcon = new JRadioButton(mLocalizer.msg("showIcon","Show channel icon"),!Settings.propTrayNowProgramsContainsName.getBoolean() && Settings.propTrayNowProgramsContainsIcon.getBoolean());
    mShowName = new JRadioButton(mLocalizer.msg("showName","Show channel name"),Settings.propTrayNowProgramsContainsName.getBoolean() && !Settings.propTrayNowProgramsContainsIcon.getBoolean());
       
    ButtonGroup bg1 = new ButtonGroup();
    bg1.add(mShowIconAndName);
    bg1.add(mShowIcon);
    bg1.add(mShowName);
View Full Code Here

    PanelBuilder pb = new PanelBuilder(new FormLayout("5dlu, default:grow, 5dlu",
    "default,5dlu,default,default,default,5dlu,default,10dlu,default,5dlu,default,default,default"));
    pb.setDefaultDialogBorder();

    pb.addSeparator(mLocalizer.msg("programTable","Program table"), cc.xyw(1,1,3));
    pb.add(mShowIconAndNameInProgramTable = new JRadioButton(mLocalizer.msg("showIconAndName","Show channel icon and channel name"), Settings.propShowChannelIconsInProgramTable.getBoolean() && Settings.propShowChannelNamesInProgramTable.getBoolean()), cc.xy(2,3));
    pb.add(mShowOnlyIconInProgramTable = new JRadioButton(mLocalizer.msg("showOnlyIcon","Show channel icon"), Settings.propShowChannelIconsInProgramTable.getBoolean() && !Settings.propShowChannelNamesInProgramTable.getBoolean()), cc.xy(2,4));
    pb.add(mShowOnlyNameInProgramTable = new JRadioButton(mLocalizer.msg("showOnlyName","Show channel name"), Settings.propShowChannelNamesInProgramTable.getBoolean() && !Settings.propShowChannelIconsInProgramTable.getBoolean()), cc.xy(2,5));
    pb.add(mShowTooltipInProgramTable = new JCheckBox(mLocalizer.msg("showToolTip","Show large channel icons in tooltip"), Settings.propShowChannelTooltipInProgramTable.getBoolean()), cc.xy(2,7));

    mShowTooltipInProgramTable.setEnabled(!mShowOnlyNameInProgramTable.isSelected());
   
    mShowOnlyNameInProgramTable.addItemListener(new ItemListener() {
      public void itemStateChanged(ItemEvent e) {
        mShowTooltipInProgramTable.setEnabled(e.getStateChange() == ItemEvent.DESELECTED);
      }
    });
   
    ButtonGroup programTable = new ButtonGroup();
    programTable.add(mShowIconAndNameInProgramTable);
    programTable.add(mShowOnlyIconInProgramTable);
    programTable.add(mShowOnlyNameInProgramTable);
   
    pb.addSeparator(mLocalizer.msg("channelLists","Channel lists"), cc.xyw(1,9,3));
    pb.add(mShowIconAndNameInChannelLists = new JRadioButton(mLocalizer.msg("showIconAndName","Show channel icon and channel name"), Settings.propShowChannelIconsInChannellist.getBoolean() && Settings.propShowChannelNamesInChannellist.getBoolean()), cc.xy(2,11));
    pb.add(mShowOnlyIconInChannelLists = new JRadioButton(mLocalizer.msg("showOnlyIcon","Show channel icon"), Settings.propShowChannelIconsInChannellist.getBoolean() && !Settings.propShowChannelNamesInChannellist.getBoolean()), cc.xy(2,12));
    pb.add(mShowOnlyNameInChannelLists = new JRadioButton(mLocalizer.msg("showOnlyName","Show channel name"), Settings.propShowChannelNamesInChannellist.getBoolean() && !Settings.propShowChannelIconsInChannellist.getBoolean()), cc.xy(2,13));

    ButtonGroup channelLists = new ButtonGroup();
    channelLists.add(mShowIconAndNameInChannelLists);
    channelLists.add(mShowOnlyIconInChannelLists);
    channelLists.add(mShowOnlyNameInChannelLists);
View Full Code Here

    mSettingsPn.add(testButton, cc.xyw(2, 5, 7));

    mSettingsPn.add(new JLabel(mLocalizer.msg("whichBrowser", "which browser")), cc.xyw(2,7,7));

    JRadioButton useDefault = new JRadioButton(mLocalizer.msg("defaultWebbrowser", "Default Webbrowser"));
    useDefault.setSelected(Settings.propUserDefinedWebbrowser.getString() == null);
    useDefault.addActionListener(new ActionListener() {
      public void actionPerformed(ActionEvent e) {
        updateInputFields();
      }
    });

    mSettingsPn.add(useDefault, cc.xyw(2, 9, 4));

    mUseWebbrowser = new JRadioButton(mLocalizer.msg("userDefinedWebbrowser","user defined webbrowser"));
    mUseWebbrowser.setSelected(Settings.propUserDefinedWebbrowser.getString() != null);

    mUseWebbrowser.addActionListener(new ActionListener() {
      public void actionPerformed(ActionEvent e) {
        updateInputFields();
View Full Code Here

    mSettingsPn.add(DefaultComponentFactory.getInstance().createSeparator(mLocalizer.msg("titleTimeFormat", "Time format")), cc.xyw(1,9,5));

    mSettingsPn.add(new JLabel(mLocalizer.msg("timeFormat", "Time format:")), cc.xy(2,11));

    mTwentyfourHourFormat = new JRadioButton(mLocalizer.msg("twentyFour", "24 hour format"));
    mTwelveHourFormat = new JRadioButton(mLocalizer.msg("twelve", "12 hour format"));
    ButtonGroup group = new ButtonGroup();
    group.add(mTwentyfourHourFormat);
    group.add(mTwelveHourFormat);

    mSettingsPn.add(mTwentyfourHourFormat, cc.xy(4, 11));
View Full Code Here

    refreshSettings.addSeparator(mLocalizer.msg("titleRefresh", "Startup"), cc.xyw(
        1, 1, 6));

    mAutoDownload = new JCheckBox(mLocalizer.msg("autoUpdate","Update TV listings automatically"));

    mStartDownload = new JRadioButton(mLocalizer.msg("onStartUp", "Only on TV-Browser startup"));
    mRecurrentDownload = new JRadioButton(mLocalizer.msg("recurrent","Recurrent"));

    ButtonGroup bg = new ButtonGroup();

    bg.add(mStartDownload);
    bg.add(mRecurrentDownload);

    refreshSettings.add(mAutoDownload, cc.xyw(2, 3, 5));

    refreshSettings.add(mStartDownload, cc.xyw(3, 5, 4));
    refreshSettings.add(mRecurrentDownload, cc.xyw(3, 6, 4));

    mAutoDownloadCombo = new JComboBox(AUTO_DOWNLOAD_MSG_ARR);
    String dlType = Settings.propAutoDownloadType.getString();
    if (dlType.equals("daily")) {
      mAutoDownloadCombo.setSelectedIndex(0);
    } else if (dlType.equals("every3days")) {
      mAutoDownloadCombo.setSelectedIndex(1);
    } else if (dlType.equals("weekly")) {
      mAutoDownloadCombo.setSelectedIndex(2);
    }

    JPanel panel = new JPanel(new FormLayout("10dlu, pref, 3dlu, pref", "pref, 3dlu, pref, 3dlu, pref, 5dlu, pref"));

    mStartDownload.setSelected(!dlType.equals("never") && !Settings.propAutoDataDownloadEnabled.getBoolean());
    mRecurrentDownload.setSelected(Settings.propAutoDataDownloadEnabled.getBoolean());

    mAutoDownload.setSelected(mStartDownload.isSelected() || mRecurrentDownload.isSelected());
    mStartDownload.setSelected(!mAutoDownload.isSelected() || mStartDownload.isSelected());

    mStartDownload.setEnabled(mAutoDownload.isSelected());
    mRecurrentDownload.setEnabled(mAutoDownload.isSelected());

    mHowOften = new JLabel(mLocalizer.msg("autoDownload.howOften", "How often?"));
    panel.add(mHowOften, cc.xy(2, 1));
    panel.add(mAutoDownloadCombo, cc.xy(4, 1));

    mAskBeforeDownloadRadio = new JRadioButton(mLocalizer.msg("autoDownload.ask", "Ask before downloading"));
    mAutoDownloadPeriodCB = new JComboBox(PeriodItem.getPeriodItems());

    int autoDLPeriod = Settings.propAutoDownloadPeriod.getInt();
    PeriodItem pi = new PeriodItem(autoDLPeriod);
    mAutoDownloadPeriodCB.setSelectedItem(pi);

    panel.add(mAskBeforeDownloadRadio, cc.xyw(2, 3, 3));

    mAskTimeRadio = new JRadioButton(mLocalizer.msg("autoDownload.duration", "Automatically refresh for"));
    panel.add(mAskTimeRadio, cc.xy(2, 5));
    panel.add(mAutoDownloadPeriodCB, cc.xy(4, 5));

    ButtonGroup group = new ButtonGroup();
    group.add(mAskBeforeDownloadRadio);
View Full Code Here

TOP

Related Classes of javax.swing.JRadioButton

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.