From 10968b25d6a3614d13ed5905afc45b8fe6e0133b Mon Sep 17 00:00:00 2001 From: Fastium <79766552+Fastium@users.noreply.github.com> Date: Wed, 18 May 2022 14:37:24 +0200 Subject: [PATCH] WORKIN ALONE ALONG THE ROAD --- bin/BillGUI/ButtonQuitListener.class | Bin 0 -> 628 bytes bin/BillGUI/HesSoGarage.class | Bin 845 -> 831 bytes bin/BillGUI/ManagerGui.class | Bin 1915 -> 1981 bytes bin/BillGUI/Row.class | Bin 522 -> 522 bytes src/BillGUI/HesSoGarage.java | 2 +- src/BillGUI/ManagerGui.java | 33 +++++++++++++++++++++++---- 6 files changed, 30 insertions(+), 5 deletions(-) create mode 100644 bin/BillGUI/ButtonQuitListener.class diff --git a/bin/BillGUI/ButtonQuitListener.class b/bin/BillGUI/ButtonQuitListener.class new file mode 100644 index 0000000000000000000000000000000000000000..c78f901e30ced19f90c60c0e00fae332d52d9794 GIT binary patch literal 628 zcmZ`#$xg#C6dbpOw4o3vWiPbHwn*g20fbmY5h!c|dV+)78gP{+C~+vig~TFp-~;$5 z#B<6fmcz6C#&5sl@Na2_mC&*DZ-kZiK^3)M8Rwb(#qr0BwD(zY`UA=?# dfQc_fGsaJebM{Rw{i&8l0kgzrm?M4y#W#jhhy?%u literal 0 HcmV?d00001 diff --git a/bin/BillGUI/HesSoGarage.class b/bin/BillGUI/HesSoGarage.class index 2402ace103d006755627cd953155ac412d302495..1928a324b2b58a61e83fb2e1e20107392cda53b4 100644 GIT binary patch delta 28 icmX@hwx4an69Fmr#G=IXRE6BcJRnuXwV8?0n+X7#&k2SA delta 41 ucmdnbc9w0z6FCi=)Lc9F#G=IXRE6BcJRntMqYo5Put_SiQ`q>$n+X6w?GD@k diff --git a/bin/BillGUI/ManagerGui.class b/bin/BillGUI/ManagerGui.class index 723861dbddebeae05eff7cf1cce91e412dd497dd..b394bfef4878e58946707921995edeea92e1752e 100644 GIT binary patch delta 689 zcmY+BJ4{ni7{`C7_ujs|5ha#bFxcP=YP3T^VnGqKVil2xJPJN&vCv|r3Wb82kPzd> zbTb+c^*m_2mj)qJ+Iv5wlCKTf2@U&MuRibXx)KWT1yW7rlx~+c7kk&tyZf zd}=0<&&`pqowWDpT1?#WwQ#s3Nq&*%C+@Lh8 zVDz2}uF+KF{5q|{O`7AUi(Fi%Ehy=>4cdonXce&j7&S}LxL+^Qxxuxe7l!f~KIhxg zFDdYEa3f;8QsBXW1geH{l@MEdsbPKGIo)_cxZBdZp delta 642 zcmY+BOH30{6o$X)%yim15g#BF4G=*CHQEKQIO2ox!9zhQVp|loXr;xmXeo~!iMlXs zXQwL{#x(}pD8U#v8WR^TjVlwk?$}|hXJ}lQ+}!isd;a^Md+uGY+T0%c{O9dEpqsgs z&_iEidk}?VCP4xo9XBxugoI9-oTAtL;_GZUt+36`I!@o%Kr}Y95W=QC#2(Ihl0LUd z-RB=L8RWccs|Woc{YWR;#GC*mGh0&c{=cgaqM zwGwBFoQ*%$l^VUq|GfM|1mPn6mj06Fu>OV%3h%KkEfUsNiEVj!H0F_)Pbxeue_LZB zS>lGJ{R3U}6|wGx6}g?tO_?XDlercR_mjV2DZzej)66|un5UIx+IS}M1&3MZ2p@^^ zRrovY{G@|lbh1Ggn^>g8C{}4)Y;Va*o;l-I<%iky(nj2!AfEAxnefnsofYvfUc^H5)A7ykb;21C#&g=gigkHTMOb%+B1 diff --git a/bin/BillGUI/Row.class b/bin/BillGUI/Row.class index 55b988758f5b1f669c55c9bfe989c3a3dc50b584..69344f021938f61868815a6b2d07a2df36adc1b6 100644 GIT binary patch delta 25 gcmeBT>0;S%osrjtfrY`9L4d)HL7KsR@)Jfi08Nnvl>h($ delta 25 gcmeBT>0;S%osrjxfrY`DL4d)9L7KsJ@)Jfi08KdsjQ{`u diff --git a/src/BillGUI/HesSoGarage.java b/src/BillGUI/HesSoGarage.java index 90e3c50..200d97d 100644 --- a/src/BillGUI/HesSoGarage.java +++ b/src/BillGUI/HesSoGarage.java @@ -4,7 +4,7 @@ public class HesSoGarage { public static void main(String[] args) { GarageManager garageManager = new GarageManager(); ManagerGui managerGui; - String name = "Garage manager
Prestations"; + String name = "Garage manager\nPrestations"; String logoFilePath = "src/logo_garage.png"; managerGui = new ManagerGui(name, logoFilePath, garageManager.getServices()); } diff --git a/src/BillGUI/ManagerGui.java b/src/BillGUI/ManagerGui.java index 0d38a1b..7a3b2e2 100644 --- a/src/BillGUI/ManagerGui.java +++ b/src/BillGUI/ManagerGui.java @@ -30,7 +30,7 @@ public class ManagerGui extends JFrame{ //Create and add header logo = new ImageIcon(logoFilePath); - Jlogo = new JLabel(name); + Jlogo = new JLabel(logo); Jname = new JLabel(name); this.add(Jname); this.add(Jlogo); @@ -48,8 +48,8 @@ public class ManagerGui extends JFrame{ } //Create and add button - JButton ButtonBill = new JButton(); - JButton ButtonQuit = new JButton(); + JButton ButtonBill = new JButton("Show bill"); + JButton ButtonQuit = new JButton("Quit"); this.add(ButtonBill); this.add(ButtonQuit); @@ -58,7 +58,9 @@ public class ManagerGui extends JFrame{ } } - +/** + * + */ class Row { JLabel label; JSpinner spinner; @@ -69,5 +71,28 @@ class Row { } } +/** + * + */ +class ButtonQuitListener implements ActionListener { + JFrame Jf; + /** + * + * @param Jf + */ + ButtonQuitListener(JFrame Jf){ + this.Jf = Jf; + } + /** + * + * @param e + */ + @Override + public void actionPerformed(ActionEvent e){ + Jf.dispose(); + } + +} +