Ignore:
Timestamp:
06/22/13 21:51:33 (11 years ago)
Author:
psniegowski
Message:

HIGHLIGHTS:

  • simplification of entities management model
  • cleanup around params (improve hierarchy)
  • migrate from JUnit to TestNG
  • introduce FEST to automatically test GUI
  • improve slider control
  • loosen synchronization between gui tree and backend representation
  • and many other bug fixes

NOTICE:

  • a great many of lines is changed only because of substituting spaces with tabs

CHANGELOG (oldest changes at the bottom):

Some cleaning after fix found.

Fix bug with tree.

More changes with TreeNodes?.

Finally fix issue with tree.

Improve gui tree management.

Decouple update of values from fetch request in gui.

Minor changes.

Minor changes.

Minor change.

Change Path construction wording.

More fixes to SliderControl?.

Fix SliderControl?.

Fix SliderControl?.

Minor improvement.

Several changes.

Make NumberParam? a generic class.

Add robot to the gui test.

Setup common testing logging configuration.

Remove Parameters class.

Remove entityOwner from Parameters.

Move name out from Parameters class.

Move configuration to after the construction.

Simplify observers and endpoints.

Remove superfluous configureEntity overrides.

Add dependency on fest-swing-testng.

Use FEST for final print test.

Use FEST for more concise and readable assertions.

Divide test of F0Parser into multiple methods.

Migrate to TestNG

Minor change.

Change convention from LOGGER to log.

Fix reporting of errors during controls filling.

Bound maximal height of SliderControl?.

Minor improvements.

Improve tooltips for controls.

Also use Delimeted in more places.

Move static control utilities to Gui.

Rename package gui.components to controls.

Some cleaning in controls.

Improve Param classes placing.

Move ValueParam?, PrimitiveParam? and CompositeParam? one package up.

Improve ParamBuilder?.

Move getDef to ValueParam? and PrimitiveParam?.

Move getMax and getDef to ValueParam?.

Move getMin to ValueParam?.

Upgrade to laters apache commons versions.

Use filterInstanceof extensively.

Add instanceof filters.

Make ValueParam? in many places of Param.

Place assertions about ValueParam?.

Add ValueParam?

Rename ValueParam? to PrimitiveParam?

Minor changes.

Several improvements to params types.

Add NumberParam?.

Add TextControl? component.

Add .swp files to .gitignore

Greatly improved slider component.

Some improvements.

Make Param.reassign return also a state.

Add IterableIterator?.

Several changes.

  • Move util classes to better packages.
  • Remove warnings from eclim.

Several improvements.

Fix bug with BooleanParam?.

Some experiments with visualization.

Another fix to panel management.

Improve panel management.

Some refactorization around panels.

Add root class for panel.

Location:
java/main
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • java/main

    • Property svn:ignore set to
      target
  • java/main/src/main/java/com/framsticks/gui/view/TreeCellRenderer.java

    r77 r84  
    66import javax.swing.*;
    77import javax.swing.tree.DefaultTreeCellRenderer;
     8
     9import org.apache.log4j.Logger;
     10
    811import java.awt.*;
    912
     
    1316@SuppressWarnings("serial")
    1417public class TreeCellRenderer extends DefaultTreeCellRenderer {
     18        private static final Logger log =
     19                Logger.getLogger(TreeCellRenderer.class);
    1520
    16     public TreeCellRenderer() {
    17         setOpenIcon(null);
    18         setClosedIcon(null);
    19         setLeafIcon(null);
    20     }
     21
     22        public TreeCellRenderer() {
     23                setOpenIcon(null);
     24                setClosedIcon(null);
     25                setLeafIcon(null);
     26        }
    2127
    2228        @Override
    2329        public Component getTreeCellRendererComponent(JTree tree, Object value,
    24                                                       boolean sel, boolean expanded, boolean leaf, int row,
    25                                                       boolean hasFocus) {
     30                        boolean sel, boolean expanded, boolean leaf, int row,
     31                        boolean hasFocus) {
    2632
    2733                //super.getTreeCellRendererComponent(tree, value, sel, expanded, leaf,
     
    3137                }
    3238                if (!(value instanceof TreeNode)) {
    33             setIcon(ImageProvider.loadImage(ImageProvider.SERVER));
    34             setText("framsticks");
     39                        setIcon(ImageProvider.loadImage(ImageProvider.SERVER));
     40                        setText("framsticks");
    3541                        return this;
    3642                }
    3743                TreeNode treeNode = (TreeNode)value;
    38         assert treeNode.getFrame().isActive();
    39         setToolTipText(treeNode.getTooltip());
    40         setIcon(ImageProvider.loadImage(treeNode.getIconName()));
    41         setText(treeNode.getName());
     44                assert treeNode.getFrame().isActive();
     45                setToolTipText(treeNode.getTooltip());
     46                setIcon(ImageProvider.loadImage(treeNode.getIconName()));
     47                setText(treeNode.getName());
    4248                return this;
    4349        }
    4450
    4551        public static String findIconName(String nodeName, String path) {
    46         if (path == null || nodeName == null) {
    47             return null;
    48         }
    49         if (path.equals("/")) {
     52                if (nodeName == null || path == null) {
     53                        log.warn("given invalid parameters: " + nodeName + " " + path);
     54                        // return null;
     55                        return ImageProvider.SERVER;
     56                }
     57                if (path.equals("/")) {
    5058                        return ImageProvider.SERVER;
    5159                }
     
    133141                return ImageProvider.SERVER;
    134142        }
    135        
    136        
     143
     144
    137145}
Note: See TracChangeset for help on using the changeset viewer.