diff options
Diffstat (limited to 'logo/src/xlogo/kernel')
-rw-r--r-- | logo/src/xlogo/kernel/userspace/UserSpace.java | 9 | ||||
-rw-r--r-- | logo/src/xlogo/kernel/userspace/files/LogoFilesManager.java | 6 |
2 files changed, 9 insertions, 6 deletions
diff --git a/logo/src/xlogo/kernel/userspace/UserSpace.java b/logo/src/xlogo/kernel/userspace/UserSpace.java index 6f2c065..bd1bf86 100644 --- a/logo/src/xlogo/kernel/userspace/UserSpace.java +++ b/logo/src/xlogo/kernel/userspace/UserSpace.java @@ -30,7 +30,6 @@ package xlogo.kernel.userspace; import java.util.ArrayList; import java.util.Collection; -import xlogo.AppSettings; import xlogo.Logo; import xlogo.interfaces.BroadcasterErrorFileContainer; import xlogo.interfaces.X4SModeSwitcher; @@ -300,10 +299,6 @@ public class UserSpace implements X4SModeSwitcher, LogoFileContainer, Broadcaste @Override public void createFile(String fileName) throws IOException { - if (contextManager.getContext().hasTooManyEmptyFiles()){ - DialogMessenger.getInstance().dispatchMessage(AppSettings.getInstance().translate("message.too.many.empty.files")); - return; - } try { filesManager.createFile(fileName); @@ -462,6 +457,10 @@ public class UserSpace implements X4SModeSwitcher, LogoFileContainer, Broadcaste return true; } + public boolean hasTooManyEmptyFiles(){ + return contextManager.getContext().hasTooManyEmptyFiles(); + } + public boolean hasErrors(String fileName) { try diff --git a/logo/src/xlogo/kernel/userspace/files/LogoFilesManager.java b/logo/src/xlogo/kernel/userspace/files/LogoFilesManager.java index 4fb05a3..ece7bdb 100644 --- a/logo/src/xlogo/kernel/userspace/files/LogoFilesManager.java +++ b/logo/src/xlogo/kernel/userspace/files/LogoFilesManager.java @@ -384,7 +384,11 @@ public class LogoFilesManager implements LogoFileContainer, FileErrorCollector {
return context.isFilesListEditAllowed();
}
-
+
+ public boolean hasTooManyEmptyFiles(){
+ return context.hasTooManyEmptyFiles();
+ }
+
/**
* the name of the file that was edited last in this context.
*/
|