From 23a05a41778f38a9956dcce0f9e9a4b7ebf74731 Mon Sep 17 00:00:00 2001 From: dragonmacher <48328597+dragonmacher@users.noreply.github.com> Date: Thu, 6 Jun 2019 15:35:13 -0400 Subject: [PATCH] Screenshots - fixed broken screenshot generators --- .../src/main/java/ghidra/framework/ToolUtils.java | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/Ghidra/Framework/Project/src/main/java/ghidra/framework/ToolUtils.java b/Ghidra/Framework/Project/src/main/java/ghidra/framework/ToolUtils.java index c1fcc556ca..76d0108b60 100644 --- a/Ghidra/Framework/Project/src/main/java/ghidra/framework/ToolUtils.java +++ b/Ghidra/Framework/Project/src/main/java/ghidra/framework/ToolUtils.java @@ -70,6 +70,10 @@ public class ToolUtils { Set toolNames = ResourceManager.getResourceNames("defaultTools", ".tool"); for (String toolName : toolNames) { + if (skipTool(toolName)) { + continue; + } + ToolTemplate tool = readToolTemplate(toolName); if (tool != null) { set.add(tool); @@ -290,10 +294,6 @@ public class ToolUtils { public static ToolTemplate readToolTemplate(String resourceFileName) { - if (skipTool(resourceFileName)) { - return null; - } - try (InputStream is = ResourceManager.getResourceAsStream(resourceFileName)) { if (is == null) { return null; @@ -346,7 +346,8 @@ public class ToolUtils { } /** - * Returns the user's personal tool chest directory path. + * Returns the user's personal tool chest directory path + * @return the path */ public static String getApplicationToolDirPath() { String userSettingsPath = Application.getUserSettingsDirectory().getAbsolutePath();