From: rnayabed Date: Tue, 23 Feb 2021 20:09:47 +0530 Subject: work --- work --- --- 'a/src/main/java/com/stream_pi/server/connection/MainServer.java' +++ b/src/main/java/com/stream_pi/server/connection/MainServer.java @@ -4,6 +4,7 @@ import com.stream_pi.server.window.Excep import com.stream_pi.util.exception.SevereException; import java.io.IOException; +import java.net.BindException; import java.net.ServerSocket; import java.net.Socket; import java.net.SocketException; @@ -92,8 +93,11 @@ public class MainServer extends Thread{ catch (SocketException e) { logger.info("Main Server stopped accepting calls ..."); - e.printStackTrace(); //more likely stopped listening; - } catch (IOException e) { + exceptionAndAlertHandler.handleSevereException(new SevereException("Sorry","Unable to Start Server. Check logs, stacktrace. \n\n"+e.getMessage())); + e.printStackTrace(); + } + catch (IOException e) + { exceptionAndAlertHandler.handleSevereException(new SevereException("MainServer io Exception occurred!")); e.printStackTrace(); } --- 'a/src/main/java/com/stream_pi/server/window/dashboard/actiondetailpane/ActionDetailsPane.java' +++ b/src/main/java/com/stream_pi/server/window/dashboard/actiondetailpane/ActionDetailsPane.java @@ -207,6 +207,7 @@ public class ActionDetailsPane extends V hideIconCheckBox.setSelected(false); clearIconButton.setDisable(true); + setSendIcon(false); iconFileTextField.clear(); }); --- 'a/src/main/java/com/stream_pi/server/window/dashboard/actiongridpane/ActionBox.java' +++ b/src/main/java/com/stream_pi/server/window/dashboard/actiongridpane/ActionBox.java @@ -238,22 +238,21 @@ public class ActionBox extends StackPane getStyleClass().remove("action_box_icon_present"); getStyleClass().add("action_box_icon_not_present"); setBackground(null); - return; } else { getStyleClass().add("action_box_icon_present"); getStyleClass().remove("action_box_icon_not_present"); - + setBackground( - new Background( - new BackgroundImage(new Image( - new ByteArrayInputStream(iconByteArray), size, size, false, true - ), BackgroundRepeat.NO_REPEAT, BackgroundRepeat.NO_REPEAT, BackgroundPosition.CENTER, - - new BackgroundSize(100, 100, true, true, true, false)) - ) + new Background( + new BackgroundImage(new Image( + new ByteArrayInputStream(iconByteArray), size, size, false, false + ), BackgroundRepeat.NO_REPEAT, BackgroundRepeat.NO_REPEAT, BackgroundPosition.CENTER, + + new BackgroundSize(size, size, false, false, true, false)) + ) ); } }