亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? dialogdemo.java

?? java tutotrials or beginners
?? JAVA
?? 第 1 頁 / 共 2 頁
字號:
/* * Copyright (c) 1995 - 2008 Sun Microsystems, Inc.  All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * *   - Redistributions of source code must retain the above copyright *     notice, this list of conditions and the following disclaimer. * *   - Redistributions in binary form must reproduce the above copyright *     notice, this list of conditions and the following disclaimer in the *     documentation and/or other materials provided with the distribution. * *   - Neither the name of Sun Microsystems nor the names of its *     contributors may be used to endorse or promote products derived *     from this software without specific prior written permission. * * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS * IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE ARE DISCLAIMED.  IN NO EVENT SHALL THE COPYRIGHT OWNER OR * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ package components;import javax.swing.JOptionPane;import javax.swing.JDialog;import javax.swing.JButton;import javax.swing.JRadioButton;import javax.swing.ButtonGroup;import javax.swing.JLabel;import javax.swing.ImageIcon;import javax.swing.BoxLayout;import javax.swing.Box;import javax.swing.BorderFactory;import javax.swing.border.Border;import javax.swing.JTabbedPane;import javax.swing.JPanel;import javax.swing.JFrame;import java.beans.*; //Property change stuffimport java.awt.*;import java.awt.event.*;/* * DialogDemo.java requires these files: *   CustomDialog.java *   images/middle.gif */public class DialogDemo extends JPanel {    JLabel label;    ImageIcon icon = createImageIcon("images/middle.gif");    JFrame frame;    String simpleDialogDesc = "Some simple message dialogs";    String iconDesc = "A JOptionPane has its choice of icons";    String moreDialogDesc = "Some more dialogs";    CustomDialog customDialog;    /** Creates the GUI shown inside the frame's content pane. */    public DialogDemo(JFrame frame) {        super(new BorderLayout());        this.frame = frame;        customDialog = new CustomDialog(frame, "geisel", this);        customDialog.pack();        //Create the components.        JPanel frequentPanel = createSimpleDialogBox();        JPanel featurePanel = createFeatureDialogBox();        JPanel iconPanel = createIconDialogBox();        label = new JLabel("Click the \"Show it!\" button"                           + " to bring up the selected dialog.",                           JLabel.CENTER);        //Lay them out.        Border padding = BorderFactory.createEmptyBorder(20,20,5,20);        frequentPanel.setBorder(padding);        featurePanel.setBorder(padding);        iconPanel.setBorder(padding);        JTabbedPane tabbedPane = new JTabbedPane();        tabbedPane.addTab("Simple Modal Dialogs", null,                          frequentPanel,                          simpleDialogDesc); //tooltip text        tabbedPane.addTab("More Dialogs", null,                          featurePanel,                          moreDialogDesc); //tooltip text        tabbedPane.addTab("Dialog Icons", null,                          iconPanel,                          iconDesc); //tooltip text        add(tabbedPane, BorderLayout.CENTER);        add(label, BorderLayout.PAGE_END);        label.setBorder(BorderFactory.createEmptyBorder(10,10,10,10));    }    /** Sets the text displayed at the bottom of the frame. */    void setLabel(String newText) {        label.setText(newText);    }    /** Returns an ImageIcon, or null if the path was invalid. */    protected static ImageIcon createImageIcon(String path) {        java.net.URL imgURL = DialogDemo.class.getResource(path);        if (imgURL != null) {            return new ImageIcon(imgURL);        } else {            System.err.println("Couldn't find file: " + path);            return null;        }    }    /** Creates the panel shown by the first tab. */    private JPanel createSimpleDialogBox() {        final int numButtons = 4;        JRadioButton[] radioButtons = new JRadioButton[numButtons];        final ButtonGroup group = new ButtonGroup();        JButton showItButton = null;        final String defaultMessageCommand = "default";        final String yesNoCommand = "yesno";        final String yeahNahCommand = "yeahnah";        final String yncCommand = "ync";        radioButtons[0] = new JRadioButton("OK (in the L&F's words)");        radioButtons[0].setActionCommand(defaultMessageCommand);        radioButtons[1] = new JRadioButton("Yes/No (in the L&F's words)");        radioButtons[1].setActionCommand(yesNoCommand);        radioButtons[2] = new JRadioButton("Yes/No "                      + "(in the programmer's words)");        radioButtons[2].setActionCommand(yeahNahCommand);        radioButtons[3] = new JRadioButton("Yes/No/Cancel "                           + "(in the programmer's words)");        radioButtons[3].setActionCommand(yncCommand);        for (int i = 0; i < numButtons; i++) {            group.add(radioButtons[i]);        }        radioButtons[0].setSelected(true);        showItButton = new JButton("Show it!");        showItButton.addActionListener(new ActionListener() {            public void actionPerformed(ActionEvent e) {                String command = group.getSelection().getActionCommand();                //ok dialog                if (command == defaultMessageCommand) {                    JOptionPane.showMessageDialog(frame,                                "Eggs aren't supposed to be green.");                //yes/no dialog                } else if (command == yesNoCommand) {                    int n = JOptionPane.showConfirmDialog(                            frame, "Would you like green eggs and ham?",                            "An Inane Question",                            JOptionPane.YES_NO_OPTION);                    if (n == JOptionPane.YES_OPTION) {                        setLabel("Ewww!");                    } else if (n == JOptionPane.NO_OPTION) {                        setLabel("Me neither!");                    } else {                        setLabel("Come on -- tell me!");                    }                //yes/no (not in those words)                } else if (command == yeahNahCommand) {                    Object[] options = {"Yes, please", "No way!"};                    int n = JOptionPane.showOptionDialog(frame,                                    "Would you like green eggs and ham?",                                    "A Silly Question",                                    JOptionPane.YES_NO_OPTION,                                    JOptionPane.QUESTION_MESSAGE,                                    null,                                    options,                                    options[0]);                    if (n == JOptionPane.YES_OPTION) {                        setLabel("You're kidding!");                    } else if (n == JOptionPane.NO_OPTION) {                        setLabel("I don't like them, either.");                    } else {                        setLabel("Come on -- 'fess up!");                    }                //yes/no/cancel (not in those words)                } else if (command == yncCommand) {                    Object[] options = {"Yes, please",                                        "No, thanks",                                        "No eggs, no ham!"};                    int n = JOptionPane.showOptionDialog(frame,                                    "Would you like some green eggs to go "                                    + "with that ham?",                                    "A Silly Question",                                    JOptionPane.YES_NO_CANCEL_OPTION,                                    JOptionPane.QUESTION_MESSAGE,                                    null,                                    options,                                    options[2]);                    if (n == JOptionPane.YES_OPTION) {                        setLabel("Here you go: green eggs and ham!");                    } else if (n == JOptionPane.NO_OPTION) {                        setLabel("OK, just the ham, then.");                    } else if (n == JOptionPane.CANCEL_OPTION) {                        setLabel("Well, I'm certainly not going to eat them!");                    } else {                        setLabel("Please tell me what you want!");                    }                }                return;            }        });        return createPane(simpleDialogDesc + ":",                          radioButtons,                          showItButton);    }    /**     * Used by createSimpleDialogBox and createFeatureDialogBox     * to create a pane containing a description, a single column     * of radio buttons, and the Show it! button.     */    private JPanel createPane(String description,                              JRadioButton[] radioButtons,                              JButton showButton) {        int numChoices = radioButtons.length;        JPanel box = new JPanel();        JLabel label = new JLabel(description);        box.setLayout(new BoxLayout(box, BoxLayout.PAGE_AXIS));        box.add(label);        for (int i = 0; i < numChoices; i++) {            box.add(radioButtons[i]);        }        JPanel pane = new JPanel(new BorderLayout());        pane.add(box, BorderLayout.PAGE_START);        pane.add(showButton, BorderLayout.PAGE_END);        return pane;    }    /**     * Like createPane, but creates a pane with 2 columns of radio     * buttons.  The number of buttons passed in *must* be even.     */     private JPanel create2ColPane(String description,                                  JRadioButton[] radioButtons,                                  JButton showButton) {        JLabel label = new JLabel(description);        int numPerColumn = radioButtons.length/2;        JPanel grid = new JPanel(new GridLayout(0, 2));        for (int i = 0; i < numPerColumn; i++) {            grid.add(radioButtons[i]);            grid.add(radioButtons[i + numPerColumn]);        }        JPanel box = new JPanel();        box.setLayout(new BoxLayout(box, BoxLayout.PAGE_AXIS));        box.add(label);        grid.setAlignmentX(0.0f);        box.add(grid);        JPanel pane = new JPanel(new BorderLayout());        pane.add(box, BorderLayout.PAGE_START);        pane.add(showButton, BorderLayout.PAGE_END);        return pane;    }    /*     * Creates the panel shown by the 3rd tab.     * These dialogs are implemented using showMessageDialog, but     * you can specify the icon (using similar code) for any other     * kind of dialog, as well.     */    private JPanel createIconDialogBox() {        JButton showItButton = null;        final int numButtons = 6;        JRadioButton[] radioButtons = new JRadioButton[numButtons];        final ButtonGroup group = new ButtonGroup();        final String plainCommand = "plain";        final String infoCommand = "info";        final String questionCommand = "question";        final String errorCommand = "error";        final String warningCommand = "warning";        final String customCommand = "custom";        radioButtons[0] = new JRadioButton("Plain (no icon)");        radioButtons[0].setActionCommand(plainCommand);        radioButtons[1] = new JRadioButton("Information icon");        radioButtons[1].setActionCommand(infoCommand);        radioButtons[2] = new JRadioButton("Question icon");        radioButtons[2].setActionCommand(questionCommand);

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
三级欧美韩日大片在线看| 夜夜夜精品看看| 国产欧美va欧美不卡在线 | 午夜精品在线看| 天天亚洲美女在线视频| 韩国v欧美v日本v亚洲v| 欧美在线视频日韩| 国产精品麻豆欧美日韩ww| 爽好久久久欧美精品| 9色porny自拍视频一区二区| 日韩精品最新网址| 亚洲五月六月丁香激情| 成人avav影音| 日韩欧美国产一区二区三区| wwwwww.欧美系列| 亚洲一区二区五区| 成人综合激情网| 天堂久久一区二区三区| 91免费精品国自产拍在线不卡| 日韩欧美高清在线| 日本在线播放一区二区三区| 99re亚洲国产精品| 欧美mv和日韩mv的网站| 日韩国产欧美三级| 91美女片黄在线观看| 亚洲一线二线三线久久久| 韩国三级在线一区| 欧美成人video| 老色鬼精品视频在线观看播放| 欧美精品99久久久**| 亚洲欧美日本在线| 91麻豆免费观看| 久久久久99精品一区| 国产精品一级片| 欧美xxxx老人做受| 图片区小说区区亚洲影院| 欧美在线免费播放| 亚洲女爱视频在线| 在线视频一区二区三区| 亚洲欧美一区二区在线观看| 青娱乐精品在线视频| 91精品国产综合久久久久久漫画| 一级精品视频在线观看宜春院 | 国产精品一级片| 欧美r级在线观看| 国产一区二区三区不卡在线观看 | 国内精品久久久久影院薰衣草| 91精品国产综合久久国产大片| 亚洲h在线观看| 91精品国产综合久久福利软件 | 国产精品美女视频| 国产91丝袜在线播放| 欧美成人女星排行榜| 国产精品亚洲午夜一区二区三区 | 成人一区二区三区视频| 精品少妇一区二区三区视频免付费| 日韩电影在线观看电影| 7777女厕盗摄久久久| 精品一区二区国语对白| 精品捆绑美女sm三区| 亚洲靠逼com| 日韩午夜在线观看视频| 久久精品理论片| 国产精品久久久一本精品| 在线视频亚洲一区| 久久99热狠狠色一区二区| 欧美日韩精品电影| 狠狠狠色丁香婷婷综合久久五月| 久久精品一区二区三区不卡牛牛| 一本在线高清不卡dvd| 日日夜夜免费精品视频| 91精品国产91热久久久做人人| 丝袜诱惑制服诱惑色一区在线观看 | 成人av先锋影音| 午夜av一区二区| 久久久精品国产免费观看同学| 国产成人av电影免费在线观看| 亚洲成av人片在www色猫咪| 欧美精品久久久久久久多人混战| 久久精品999| 亚洲宅男天堂在线观看无病毒| 精品日本一线二线三线不卡| 色94色欧美sute亚洲线路二| 奇米影视在线99精品| 自拍av一区二区三区| 91浏览器在线视频| 亚洲第一主播视频| 日韩三级视频中文字幕| 9久草视频在线视频精品| 亚洲成人在线观看视频| 91精品国产91久久久久久最新毛片 | 一区二区国产盗摄色噜噜| 91麻豆精品国产91久久久久| 亚洲自拍偷拍综合| 国产精品久久久久久久岛一牛影视| 欧美综合天天夜夜久久| 日韩va欧美va亚洲va久久| 国产精品麻豆欧美日韩ww| 日韩欧美综合一区| 91在线播放网址| 日韩va亚洲va欧美va久久| 国产精品福利一区二区| 日韩欧美久久久| 在线观看91视频| 国产91丝袜在线播放| 久久99久久99| 成人免费一区二区三区在线观看| 欧美日韩精品系列| 99视频精品全部免费在线| 国产一区二区三区美女| 日本免费新一区视频| 亚洲一区二区三区不卡国产欧美 | 国产精品国产三级国产| 欧美日韩国产欧美日美国产精品| 中文字幕一区在线观看| 国产精品国产三级国产a| 91免费观看国产| 国产精品99久久久久| 首页欧美精品中文字幕| 亚洲桃色在线一区| 91精品国产综合久久久蜜臀粉嫩 | 国产精品久99| 久久久久亚洲综合| 久久综合色8888| 欧美xxxx在线观看| 欧美一级欧美一级在线播放| 粗大黑人巨茎大战欧美成人| av一区二区三区在线| 国产成人精品一区二区三区四区 | 91精品国产综合久久久久| 99精品在线免费| 成人禁用看黄a在线| 蜜臀精品一区二区三区在线观看| 午夜精品一区二区三区电影天堂| 亚洲综合精品久久| 欧美日韩国产影片| 日韩欧美在线一区二区三区| 欧美理论在线播放| 日韩和的一区二区| 欧美日韩卡一卡二| 美女www一区二区| 国产风韵犹存在线视精品| 国产超碰在线一区| 色88888久久久久久影院按摩| 欧美丝袜丝交足nylons图片| 欧美日韩国产美| 2023国产精品自拍| 欧美国产日韩精品免费观看| 一区二区成人在线视频| 日韩福利电影在线观看| 成人做爰69片免费看网站| 91精品办公室少妇高潮对白| 在线观看免费成人| 日韩你懂的在线观看| 综合精品久久久| 亚洲成av人片一区二区三区| 视频一区二区三区中文字幕| 极品少妇一区二区| 国产制服丝袜一区| 欧美日韩视频不卡| 欧美成人免费网站| 一区二区三区鲁丝不卡| 美女网站色91| 成人av综合在线| 色噜噜狠狠色综合中国| 日韩一级在线观看| 中文字幕日韩一区| 亚洲福利一区二区| 国产一区二区三区黄视频 | 一区二区三区欧美激情| 奇米影视7777精品一区二区| 国产成人在线观看| 经典一区二区三区| 99麻豆久久久国产精品免费优播| 日本精品一区二区三区高清| 国产欧美精品区一区二区三区| 亚洲一区二区三区四区的| 国产成人综合自拍| 欧美丰满少妇xxxbbb| 亚洲日穴在线视频| 久久精品国产一区二区三区免费看 | 精品一区二区三区欧美| 国产sm精品调教视频网站| 欧美日韩中文字幕一区| 国产欧美日本一区二区三区| 青青草原综合久久大伊人精品| 国产成人午夜视频| 精品电影一区二区| 亚洲国产精品天堂| 99久久伊人久久99| 久久久综合精品| 亚洲精品中文在线影院| 黄色小说综合网站| 欧美女孩性生活视频| 亚洲视频免费看| 国产盗摄女厕一区二区三区| 欧美一区二区女人| 夜夜操天天操亚洲| 国产不卡免费视频| 欧美tickle裸体挠脚心vk|