Package javax.swing

Examples of javax.swing.JFrame


  /**
   * @see net.sourceforge.squirrel_sql.client.update.UpdateController#showUpdateDialog()
   */
  public void showUpdateDialog()
  {
    final JFrame parent = _app.getMainFrame();
    final IUpdateSettings settings = getUpdateSettings();
    final boolean isRemoteUpdateSite = settings.isRemoteUpdateSite();
    GUIUtils.processOnSwingEventThread(new Runnable()
    {

View Full Code Here


    logDebug("handleDownloadStarted: launching progress monitor");
    GUIUtils.processOnSwingEventThread(new Runnable()
    {
      public void run()
      {
        final JFrame frame = controller.getMainFrame();
        progressMonitor =
          new ProgressMonitor(frame, i18n.DOWNLOADING_UPDATES_MSG, i18n.DOWNLOADING_UPDATES_MSG, 0,
            totalFiles);
        setProgress(0);
      }
View Full Code Here

    private void showMessageDialog(final String message,
                                   final String title,
                                   final int messageType)
    {
        final JFrame f = _app.getMainFrame();
        SwingUtilities.invokeLater(new Runnable() {
            public void run() {
                JOptionPane.showMessageDialog(f,
                        message,
                        title,
View Full Code Here

    setPreferredWidth( rows );
  }

  public static void main(String[] args)
  {
    JFrame frame = new JFrame("LineNumberDemo");
    frame.setDefaultCloseOperation( JFrame.EXIT_ON_CLOSE );

    JPanel panel = new JPanel();
    frame.setContentPane( panel );
    panel.setBorder(BorderFactory.createEmptyBorder(20,20,20,20));
    panel.setLayout(new BorderLayout());

    JTextPane textPane = new JTextPane();
    textPane.setFont( new Font("monospaced", Font.PLAIN, 12) );
    textPane.setText("abc");

    JScrollPane scrollPane = new JScrollPane(textPane);
    panel.add(scrollPane);
    scrollPane.setPreferredSize(new Dimension(300, 250));

    LineNumber lineNumber = new LineNumber( textPane );
    scrollPane.setRowHeaderView( lineNumber );

    frame.pack();
    frame.setVisible(true);
  }
View Full Code Here

    /**
     **/
    public void createFrame() {
        stopTimer();

        frame = new JFrame();
        frame.setContentPane(this);
        frame.pack();
        frame.setSize(new Dimension(400, 420));
        frame.setIconImage(Standard.getImage("frameicon.png"));

View Full Code Here

                t.restart();

            return;
        }

        JFrame frame = panel.getContainingFrame();

        if (frame != null) {
            frame.setVisible(true);
            frame.toFront();
        }

        panel.getInputComponent().requestFocus();
    }
View Full Code Here

        clearButton.setToolTipText(resources.getString("clear"));
        emoteButton.addActionListener(
            new ActionListener() {
                public void actionPerformed(ActionEvent e) {
                    JFrame f = frame;
                    if (f == null) {
                        f = BuddyList.getInstance().getTabFrame();
                    }
                    ConversationFormatter.getInstance().displayEmoticonChooser(f, emoteButton,
                            textEntryArea);
View Full Code Here

                public void run() {
                    String extraInfo = delayInfo;
                    setIsTyping(false);
                    receiveMessage();

                    JFrame f = frame;
                    if (f == null) {
                        f = BuddyList.getInstance().getTabFrame();
                    }

                    if (f.isFocused() == true) {
//                    SwingUtilities.invokeLater(new Runnable() {
//                         public void run() {
                        buddy.sendNotDisplayedID();
//                         }
//                    });
View Full Code Here

    /**
     *  Creates the containing frame
     */
    public void createFrame() {
        frame = new JFrame();
        frame.setContentPane(this);
        frame.pack();

        frame.setIconImage(Standard.getImage("frameicon.png"));

View Full Code Here

    /**
     * @param args
     */
    public static void main(String[] args) throws Exception {
        JFrame f = new JFrame();
        f.getContentPane().setLayout(new BorderLayout());
        ApplicationArguments.initialize(new String[0]);
        SQLScriptPreferencesManager.initialize(new DummyPlugin());
        SQLScriptPreferenceBean bean = SQLScriptPreferencesManager.getPreferences();
        final SQLScriptPreferencesPanel p = new SQLScriptPreferencesPanel(bean);
        JScrollPane sp = new JScrollPane(p);
        f.getContentPane().add(sp, BorderLayout.CENTER);
        JButton button = new JButton("Save");
        button.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent e) {
                p.applyChanges();
                SQLScriptPreferencesManager.unload();
            }
        });
        JButton exitButton = new JButton("Exit");
        exitButton.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent e) {
                System.exit(0);
            }
        });
        JPanel buttonPanel = new JPanel();
        buttonPanel.add(button);
        buttonPanel.add(exitButton);
        f.getContentPane().add(buttonPanel, BorderLayout.SOUTH);
        f.setBounds(200, 50,700, 700);
        f.setVisible(true);
    }
View Full Code Here

TOP

Related Classes of javax.swing.JFrame

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.