one pass on layout
build.xml exclude javafx ( remark lost with doit.sh ant ).
This commit is contained in:
@@ -17,7 +17,9 @@
|
|||||||
<target name="compile" depends="init"
|
<target name="compile" depends="init"
|
||||||
description="compile the source " >
|
description="compile the source " >
|
||||||
<!-- Compile the java code from ${src} into ${build} -->
|
<!-- Compile the java code from ${src} into ${build} -->
|
||||||
<javac srcdir="${src}" destdir="${build}"/>
|
<javac srcdir="${src}" destdir="${build}" includeantruntime="false">
|
||||||
|
<exclude name="org/artisanlogiciel/games/javafx/*"/>
|
||||||
|
</javac>
|
||||||
</target>
|
</target>
|
||||||
|
|
||||||
<target name="dist" depends="compile"
|
<target name="dist" depends="compile"
|
||||||
@@ -25,8 +27,8 @@
|
|||||||
<!-- Create the distribution directory -->
|
<!-- Create the distribution directory -->
|
||||||
<mkdir dir="${dist}/lib"/>
|
<mkdir dir="${dist}/lib"/>
|
||||||
|
|
||||||
<!-- Put everything in ${build} into the artloglaby-0.0.1.jar file ( ${DSTAMP} not used yet )-->
|
<!-- Put everything in ${build} into the artloglaby-0.1.jar file ( ${DSTAMP} not used yet )-->
|
||||||
<jar jarfile="${dist}/lib/artloglaby-0.0.1.jar" basedir="${build}">
|
<jar jarfile="${dist}/lib/artloglaby-0.1.jar" basedir="${build}">
|
||||||
<manifest>
|
<manifest>
|
||||||
<attribute name="Main-Class" value="org.artisanlogiciel.games.Display"/>
|
<attribute name="Main-Class" value="org.artisanlogiciel.games.Display"/>
|
||||||
</manifest>
|
</manifest>
|
||||||
|
|||||||
@@ -190,6 +190,8 @@ public class Display extends JFrame
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
add(buttonCreate);
|
add(buttonCreate);
|
||||||
|
if ( params != null )
|
||||||
|
{
|
||||||
JLabel widthLabel = new JLabel("width");
|
JLabel widthLabel = new JLabel("width");
|
||||||
textWidth = new JTextField("0" + params.getWidth());
|
textWidth = new JTextField("0" + params.getWidth());
|
||||||
add(widthLabel);
|
add(widthLabel);
|
||||||
@@ -203,6 +205,7 @@ public class Display extends JFrame
|
|||||||
add(depthLabel);
|
add(depthLabel);
|
||||||
add(textDepth);
|
add(textDepth);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
public MazeParams getParams()
|
public MazeParams getParams()
|
||||||
{
|
{
|
||||||
@@ -285,10 +288,12 @@ public class Display extends JFrame
|
|||||||
|
|
||||||
private MazeSettings settings = null;
|
private MazeSettings settings = null;
|
||||||
|
|
||||||
|
private JPanel resizecontrol = null;
|
||||||
|
|
||||||
public MazeControler(MazeParams params)
|
public MazeControler(MazeParams params)
|
||||||
{
|
{
|
||||||
controlPanel = new JPanel();
|
super(new BorderLayout());
|
||||||
|
controlPanel = new JPanel(new BorderLayout());
|
||||||
settings = new MazeSettings(params);
|
settings = new MazeSettings(params);
|
||||||
JButton button = new JButton("Resolve");
|
JButton button = new JButton("Resolve");
|
||||||
button.addActionListener(new ActionListener()
|
button.addActionListener(new ActionListener()
|
||||||
@@ -350,7 +355,7 @@ public class Display extends JFrame
|
|||||||
};
|
};
|
||||||
JButton south = addDirection(this, "South", "DOWN", goSouth);
|
JButton south = addDirection(this, "South", "DOWN", goSouth);
|
||||||
|
|
||||||
add(button, BorderLayout.CENTER);
|
controlPanel.add(button, BorderLayout.CENTER);
|
||||||
controlPanel.add(north, BorderLayout.NORTH);
|
controlPanel.add(north, BorderLayout.NORTH);
|
||||||
controlPanel.add(west, BorderLayout.WEST);
|
controlPanel.add(west, BorderLayout.WEST);
|
||||||
controlPanel.add(east, BorderLayout.EAST);
|
controlPanel.add(east, BorderLayout.EAST);
|
||||||
@@ -359,7 +364,7 @@ public class Display extends JFrame
|
|||||||
|
|
||||||
// control display panel contains controls for display
|
// control display panel contains controls for display
|
||||||
// zoom , autozoom.
|
// zoom , autozoom.
|
||||||
final JPanel controlDisplayPanel = new JPanel();
|
final JPanel controlDisplayPanel = new JPanel(new BorderLayout());
|
||||||
final JSlider slider = new JSlider(2, 40);
|
final JSlider slider = new JSlider(2, 40);
|
||||||
slider.addChangeListener(new ChangeListener()
|
slider.addChangeListener(new ChangeListener()
|
||||||
{
|
{
|
||||||
@@ -386,11 +391,14 @@ public class Display extends JFrame
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
savePngButton.addActionListener(savePngAction);
|
savePngButton.addActionListener(savePngAction);
|
||||||
controlDisplayPanel.add(slider, BorderLayout.WEST);
|
|
||||||
controlDisplayPanel.add(autoSlide, BorderLayout.EAST);
|
resizecontrol = new JPanel();
|
||||||
controlDisplayPanel.add(savePngButton, BorderLayout.SOUTH);
|
resizecontrol.add(slider, BorderLayout.WEST);
|
||||||
|
resizecontrol.add(autoSlide, BorderLayout.EAST);
|
||||||
|
resizecontrol.add(savePngButton, BorderLayout.SOUTH);
|
||||||
|
|
||||||
add(controlDisplayPanel, BorderLayout.SOUTH);
|
add(controlDisplayPanel, BorderLayout.SOUTH);
|
||||||
|
add(resizecontrol,BorderLayout.WEST);
|
||||||
add(settings,BorderLayout.EAST);
|
add(settings,BorderLayout.EAST);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -399,6 +407,11 @@ public class Display extends JFrame
|
|||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private JPanel getResizeControl()
|
||||||
|
{
|
||||||
|
return resizecontrol;
|
||||||
|
}
|
||||||
|
|
||||||
private JPanel getGenerationControl()
|
private JPanel getGenerationControl()
|
||||||
{
|
{
|
||||||
return settings;
|
return settings;
|
||||||
|
|||||||
@@ -3,5 +3,5 @@ project_default=dist
|
|||||||
project_basedir=$(pwd)
|
project_basedir=$(pwd)
|
||||||
project_mainpackage=org.artisanlogiciel.games
|
project_mainpackage=org.artisanlogiciel.games
|
||||||
project_mainclass=$project_mainpackage.Display
|
project_mainclass=$project_mainpackage.Display
|
||||||
project_version=0.0.1
|
project_version=0.1
|
||||||
default_args='lab/lab30x30.raw'
|
default_args='lab/lab30x30.raw'
|
||||||
|
|||||||
Reference in New Issue
Block a user