diff options
author | Rüdiger Timm <rt@openoffice.org> | 2004-10-22 12:49:06 +0000 |
---|---|---|
committer | Rüdiger Timm <rt@openoffice.org> | 2004-10-22 12:49:06 +0000 |
commit | 594f565720f2ba28b8ea8db79c961c9aeb3190dd (patch) | |
tree | 2186a3d3b9b9230feba5fd2cd87fc62669972580 | |
parent | c5c55615c635b00ced0fa3751e4f8e1584b4e167 (diff) |
INTEGRATION: CWS scriptingf6 (1.2.22); FILE MERGED
2004/09/16 14:26:45 dfoster 1.2.22.2: #i33670#
Rename the context variable to XSCRIPTCONTEXT
2004/07/23 09:55:17 dfoster 1.2.22.1: #i30606#
Add descriptions to code in examples.
-rw-r--r-- | scripting/examples/beanshell/Highlight/ButtonPressHandler.bsh | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/scripting/examples/beanshell/Highlight/ButtonPressHandler.bsh b/scripting/examples/beanshell/Highlight/ButtonPressHandler.bsh index acfe56e2a65f..363e12bb82b0 100644 --- a/scripting/examples/beanshell/Highlight/ButtonPressHandler.bsh +++ b/scripting/examples/beanshell/Highlight/ButtonPressHandler.bsh @@ -1,3 +1,6 @@ +// this code is bound to the events generated by the buttons in the dialog +// it will close the dialog or find and highlight the text entered in the +// dialog (depending on the button pressed) import com.sun.star.uno.*; import com.sun.star.awt.*; import com.sun.star.lang.*; @@ -48,7 +51,7 @@ else int red = cRed.getRGB(); XReplaceable replaceable = (XReplaceable) - UnoRuntime.queryInterface(XReplaceable.class, context.getDocument()); + UnoRuntime.queryInterface(XReplaceable.class, XSCRIPTCONTEXT.getDocument()); XReplaceDescriptor descriptor = (XReplaceDescriptor) replaceable.createReplaceDescriptor(); |