mirror of
				https://github.com/packwiz/packwiz-installer.git
				synced 2025-11-04 12:34:31 +01:00 
			
		
		
		
	Correct dialog parentage
This commit is contained in:
		@@ -166,7 +166,7 @@ public class InstallWindow implements IUserInterface {
 | 
				
			|||||||
	public Future<Boolean> showOptions(List<IOptionDetails> opts) {
 | 
						public Future<Boolean> showOptions(List<IOptionDetails> opts) {
 | 
				
			||||||
		CompletableFuture<Boolean> future = new CompletableFuture<>();
 | 
							CompletableFuture<Boolean> future = new CompletableFuture<>();
 | 
				
			||||||
		EventQueue.invokeLater(() -> {
 | 
							EventQueue.invokeLater(() -> {
 | 
				
			||||||
			OptionsSelectWindow dialog = new OptionsSelectWindow(opts, future);
 | 
								OptionsSelectWindow dialog = new OptionsSelectWindow(opts, future, frmPackwizlauncher);
 | 
				
			||||||
			dialog.setDefaultCloseOperation(JDialog.DISPOSE_ON_CLOSE);
 | 
								dialog.setDefaultCloseOperation(JDialog.DISPOSE_ON_CLOSE);
 | 
				
			||||||
			dialog.setVisible(true);
 | 
								dialog.setVisible(true);
 | 
				
			||||||
		});
 | 
							});
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -25,12 +25,13 @@ public class OptionsSelectWindow extends JDialog implements ActionListener {
 | 
				
			|||||||
	/**
 | 
						/**
 | 
				
			||||||
	 * Create the dialog.
 | 
						 * Create the dialog.
 | 
				
			||||||
	 */
 | 
						 */
 | 
				
			||||||
	OptionsSelectWindow(List<IOptionDetails> optList, CompletableFuture<Boolean> future) {
 | 
						OptionsSelectWindow(List<IOptionDetails> optList, CompletableFuture<Boolean> future, JFrame parentWindow) {
 | 
				
			||||||
 | 
							super(parentWindow, "Select optional mods...", true);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
		tableModel = new OptionTableModel(optList);
 | 
							tableModel = new OptionTableModel(optList);
 | 
				
			||||||
		this.future = future;
 | 
							this.future = future;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
		setModal(true);
 | 
							setLocationRelativeTo(parentWindow);
 | 
				
			||||||
		setTitle("Select optional mods...");
 | 
					 | 
				
			||||||
		setBounds(100, 100, 450, 300);
 | 
							setBounds(100, 100, 450, 300);
 | 
				
			||||||
		getContentPane().setLayout(new BorderLayout());
 | 
							getContentPane().setLayout(new BorderLayout());
 | 
				
			||||||
		JPanel contentPanel = new JPanel();
 | 
							JPanel contentPanel = new JPanel();
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user