Ignore:
Timestamp:
Sep 1, 2010, 11:59:17 PM (14 years ago)
Author:
mlg
Message:

Features implementation :
feature:0001829 : the user is now informed that the application is performing an action. It displays what action it is and also a progress bar for time consuming actions like sending images. (calls to jiwigo's webservice are done in threads).

File:
1 edited

Legend:

Unmodified
Added
Removed
  • extensions/jiwigo/trunk/src/main/java/fr/mael/jiwigo/ui/mainframe/MainFrame.java

    r6832 r6833  
    1414import javax.swing.JMenuItem;
    1515import javax.swing.JPanel;
     16import javax.swing.JProgressBar;
    1617import javax.swing.JScrollPane;
    1718import javax.swing.JSplitPane;
     
    9798    private static MainFrame instance;
    9899
     100    private JProgressBar progressBar;
     101
    99102    /**
    100103     * @return le singleton
     
    128131        this.add(splitPane, BorderLayout.WEST);
    129132        JPanel panel = new JPanel(new FlowLayout(FlowLayout.LEFT));
     133        progressBar = new JProgressBar(0, 100);
     134        panel.add(progressBar);
    130135        panel.add(labelMessage);
    131136
     
    175180    }
    176181
    177     public static void reduceHeightOfComponent(JComponent comp) {
    178         comp.setMaximumSize(new Dimension(comp.getMaximumSize().width, comp.getPreferredSize().height));
    179     }
    180 
    181     public static void reduceWidthOfComponent(JComponent comp) {
    182         comp.setMaximumSize(new Dimension(comp.getPreferredSize().width, comp.getMaximumSize().height));
    183     }
    184 
    185182    public static void reduceSizeOfComponent(JComponent comp) {
    186183        comp.setMaximumSize(comp.getPreferredSize());
    187184    }
    188185
     186    /**
     187     * @return the progressBar
     188     */
     189    public JProgressBar getProgressBar() {
     190        return progressBar;
     191    }
     192
    189193}
Note: See TracChangeset for help on using the changeset viewer.