|
@@ -22,12 +22,14 @@ public class Controls extends JPanel implements Observer, Serializable
|
|
|
if (e.getSource() == grid)
|
|
|
{
|
|
|
grid.setSelected(true);
|
|
|
+ grid.setIcon(lightGridIcon);
|
|
|
list.setSelected(false);
|
|
|
model.switchLayout(true);
|
|
|
}
|
|
|
else
|
|
|
{
|
|
|
list.setSelected(true);
|
|
|
+ list.setIcon(lightListIcon);
|
|
|
grid.setSelected(false);
|
|
|
model.switchLayout(false);
|
|
|
}
|
|
@@ -202,11 +204,15 @@ public class Controls extends JPanel implements Observer, Serializable
|
|
|
private Image fullStarImg;
|
|
|
private Image gridImg;
|
|
|
private Image listImg;
|
|
|
+ private Image lightGridImg;
|
|
|
+ private Image lightListImg;
|
|
|
private Image folderImg;
|
|
|
private ImageIcon emptyStarIcon;
|
|
|
private ImageIcon fullStarIcon;
|
|
|
private ImageIcon gridIcon;
|
|
|
- private ImageIcon listIcon;
|
|
|
+ private ImageIcon listIcon;.
|
|
|
+ private ImageIcon lightGridIcon;.
|
|
|
+ private ImageIcon lightListIcon;.
|
|
|
private ImageIcon folderIcon;
|
|
|
private JButton fileButton;
|
|
|
private JRadioButton star1;
|
|
@@ -247,6 +253,16 @@ public class Controls extends JPanel implements Observer, Serializable
|
|
|
this.listImg = ImageIO.read(new File("src/main/resources/list.png"));
|
|
|
} catch(IOException e) {}
|
|
|
|
|
|
+ try
|
|
|
+ {
|
|
|
+ this.lightGridImg = ImageIO.read(new File("src/main/resources/lightgrid.png"));
|
|
|
+ } catch(IOException e) {}
|
|
|
+
|
|
|
+ try
|
|
|
+ {
|
|
|
+ this.lightListImg = ImageIO.read(new File("src/main/resources/lightlist.png"));
|
|
|
+ } catch(IOException e) {}
|
|
|
+
|
|
|
try
|
|
|
{
|
|
|
this.folderImg = ImageIO.read(new File("src/main/resources/folder.jpg"));
|
|
@@ -257,6 +273,8 @@ public class Controls extends JPanel implements Observer, Serializable
|
|
|
this.emptyStarImg = emptyStarImg.getScaledInstance(50, 50, java.awt.Image.SCALE_SMOOTH);
|
|
|
this.gridImg = gridImg.getScaledInstance(50, 50, java.awt.Image.SCALE_SMOOTH);
|
|
|
this.listImg = listImg.getScaledInstance(50, 50, java.awt.Image.SCALE_SMOOTH);
|
|
|
+ this.lightGridImg = lightGridImg.getScaledInstance(50, 50, java.awt.Image.SCALE_SMOOTH);
|
|
|
+ this.lightListImg = lightListImg.getScaledInstance(50, 50, java.awt.Image.SCALE_SMOOTH);
|
|
|
this.folderImg = folderImg.getScaledInstance(50, 50, java.awt.Image.SCALE_SMOOTH);
|
|
|
this.fullStarIcon = new ImageIcon(fullStarImg);
|
|
|
this.emptyStarIcon = new ImageIcon(emptyStarImg);
|