mirror of
https://github.com/NationalSecurityAgency/ghidra.git
synced 2026-09-28 17:11:11 -09:00
Test fixes: put dialog creation on the swing thread; put layout change
call into a task
This commit is contained in:
@@ -31,6 +31,7 @@ import ghidra.framework.plugintool.Plugin;
|
||||
import ghidra.framework.plugintool.PluginTool;
|
||||
import ghidra.framework.remote.User;
|
||||
import ghidra.util.Msg;
|
||||
import ghidra.util.Swing;
|
||||
import ghidra.util.exception.CancelledException;
|
||||
import ghidra.util.task.*;
|
||||
import resources.ResourceManager;
|
||||
@@ -107,6 +108,7 @@ public class VersionControlCheckOutAction extends VersionControlAction {
|
||||
private class CheckOutTask extends Task {
|
||||
private Collection<DomainFile> files;
|
||||
private boolean exclusive = true;
|
||||
private CheckoutDialog checkout;
|
||||
|
||||
CheckOutTask(Collection<DomainFile> files) {
|
||||
super("Check Out", true, true, true);
|
||||
@@ -144,7 +146,9 @@ public class VersionControlCheckOutAction extends VersionControlAction {
|
||||
// note: a 'null' user means that we are using a local repository
|
||||
User user = getUser();
|
||||
if (user != null && user.hasWritePermission()) {
|
||||
CheckoutDialog checkout = new CheckoutDialog();
|
||||
|
||||
checkout = Swing.runNow(() -> new CheckoutDialog());
|
||||
|
||||
if (checkout.showDialog(tool) != CheckoutDialog.OK) {
|
||||
return false;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user