mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
[gui-test] GUI-114 execute get current file name on edt
This commit is contained in:
+3
-5
@@ -84,15 +84,13 @@ public class FileEditorFixture extends EditorFixture {
|
||||
*/
|
||||
@Nullable
|
||||
public String getCurrentFileName() {
|
||||
final String[] fileName = {null};
|
||||
execute(new GuiTask() {
|
||||
return execute(new GuiQuery<String>() {
|
||||
@Override
|
||||
protected void executeInEDT() throws Throwable {
|
||||
protected String executeInEDT() throws Throwable {
|
||||
VirtualFile currentFile = getCurrentFile();
|
||||
fileName[0] = currentFile != null ? currentFile.getName() : null;
|
||||
return currentFile != null ? currentFile.getName() : null;
|
||||
}
|
||||
});
|
||||
return fileName[0];
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user