mirror of
https://github.com/DSheirer/sdrtrunk.git
synced 2026-11-09 15:17:24 -05:00
Allow Streaming Configuration Text Inputs to Expand (#2591)
This commit is contained in:
@@ -23,6 +23,7 @@ import io.github.dsheirer.audio.broadcast.BroadcastConfiguration;
|
||||
import io.github.dsheirer.audio.broadcast.BroadcastEvent;
|
||||
import io.github.dsheirer.audio.broadcast.BroadcastServerType;
|
||||
import io.github.dsheirer.gui.control.AccessibleToggleSwitch;
|
||||
import io.github.dsheirer.gui.control.IntegerTextField;
|
||||
import io.github.dsheirer.gui.playlist.Editor;
|
||||
import io.github.dsheirer.playlist.PlaylistManager;
|
||||
import javafx.application.Platform;
|
||||
@@ -68,6 +69,26 @@ public abstract class AbstractBroadcastEditor<T extends BroadcastConfiguration>
|
||||
buttonBox.setSpacing(10);
|
||||
buttonBox.getChildren().addAll(getSaveButton(), getResetButton());
|
||||
|
||||
/**
|
||||
* Allow column 1 (Primary input fields) to expand with editor width
|
||||
*/
|
||||
for(Node node : getEditorPane().getChildren())
|
||||
{
|
||||
Integer column = GridPane.getColumnIndex(node);
|
||||
|
||||
if(column != null && column == 1)
|
||||
{
|
||||
if(node instanceof IntegerTextField)
|
||||
{
|
||||
GridPane.setFillWidth(node, false);
|
||||
}
|
||||
else if(node instanceof TextField)
|
||||
{
|
||||
GridPane.setHgrow(node, Priority.ALWAYS);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
HBox editorBox = new HBox();
|
||||
HBox.setHgrow(getEditorPane(), Priority.ALWAYS);
|
||||
editorBox.getChildren().addAll(getEditorPane(), buttonBox);
|
||||
|
||||
Reference in New Issue
Block a user