From: David ‘Bombe’ Roden Date: Sat, 31 May 2008 04:28:18 +0000 (+0200) Subject: disable set default on directories X-Git-Url: https://git.pterodactylus.net/?a=commitdiff_plain;h=5171f0d892b04dd504534cf2819c9578bcffcd1d;p=jSite2.git disable set default on directories --- diff --git a/src/net/pterodactylus/jsite/gui/FileManager.java b/src/net/pterodactylus/jsite/gui/FileManager.java index c90614a..77df538 100644 --- a/src/net/pterodactylus/jsite/gui/FileManager.java +++ b/src/net/pterodactylus/jsite/gui/FileManager.java @@ -432,6 +432,7 @@ public class FileManager extends JDialog implements I18nable, ActionListener, Tr } fileTree.setSelectionPath(clickedPath); ProjectFileWrapper projectFileWrapper = (ProjectFileWrapper) clickedPath.getLastPathComponent(); + setDefaultFileAction.setEnabled(projectFileWrapper.getProjectFile().isFile() && !isHidden(projectFileWrapper)); insertCheckBoxMenuItem.setSelected(!isHidden(projectFileWrapper)); treeContextMenu.show(fileTree, eventLocation.x, eventLocation.y); }