diff options
author | Kurt Zenker <kz@openoffice.org> | 2005-03-01 12:07:38 +0000 |
---|---|---|
committer | Kurt Zenker <kz@openoffice.org> | 2005-03-01 12:07:38 +0000 |
commit | e0c59e2068887f371e89dacc1d39032673d89c7e (patch) | |
tree | c6080a8edbd41e9859f9c82323c7c142a74141fa /scripting/java/com/sun/star/script/framework/provider/beanshell/ScriptProviderForBeanShell.java | |
parent | INTEGRATION: CWS scriptingf11 (1.11.2); FILE MERGED (diff) | |
download | core-e0c59e2068887f371e89dacc1d39032673d89c7e.tar.gz core-e0c59e2068887f371e89dacc1d39032673d89c7e.zip |
INTEGRATION: CWS scriptingf11 (1.7.22); FILE MERGED
2005/02/18 17:13:53 toconnor 1.7.22.1: #i41597# return after invoking script using editor
Diffstat (limited to 'scripting/java/com/sun/star/script/framework/provider/beanshell/ScriptProviderForBeanShell.java')
-rwxr-xr-x | scripting/java/com/sun/star/script/framework/provider/beanshell/ScriptProviderForBeanShell.java | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/scripting/java/com/sun/star/script/framework/provider/beanshell/ScriptProviderForBeanShell.java b/scripting/java/com/sun/star/script/framework/provider/beanshell/ScriptProviderForBeanShell.java index a4edb221cf0c..90f1a58d2de4 100755 --- a/scripting/java/com/sun/star/script/framework/provider/beanshell/ScriptProviderForBeanShell.java +++ b/scripting/java/com/sun/star/script/framework/provider/beanshell/ScriptProviderForBeanShell.java @@ -2,9 +2,9 @@ * * $RCSfile: ScriptProviderForBeanShell.java,v $ * -* $Revision: 1.7 $ +* $Revision: 1.8 $ * -* last change: $Author: rt $ $Date: 2004-10-22 14:49:31 $ +* last change: $Author: kz $ $Date: 2005-03-01 13:07:38 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -335,21 +335,21 @@ class ScriptImpl implements XScript ScriptEditorForBeanShell editor = ScriptEditorForBeanShell.getEditor( sourceUrl ); + if ( editor != null ) { - editor.execute(); - } + result = editor.execute(); - if (editor != null && editor.isModified()) - { - source = editor.getText(); - } - else - { - metaData.loadSource(); - source = metaData.getSource(); + if (result == null) + { + return new Any(new Type(), null); + } + return result; } + metaData.loadSource(); + source = metaData.getSource(); + if ( source == null || source.length() == 0 ) { throw new ScriptFrameworkErrorException( |