summaryrefslogtreecommitdiff
path: root/odk/examples/DevelopersGuide/Components/Addons/ProtocolHandlerAddon_java/ProtocolHandlerAddon.java
diff options
context:
space:
mode:
Diffstat (limited to 'odk/examples/DevelopersGuide/Components/Addons/ProtocolHandlerAddon_java/ProtocolHandlerAddon.java')
-rw-r--r--odk/examples/DevelopersGuide/Components/Addons/ProtocolHandlerAddon_java/ProtocolHandlerAddon.java16
1 files changed, 8 insertions, 8 deletions
diff --git a/odk/examples/DevelopersGuide/Components/Addons/ProtocolHandlerAddon_java/ProtocolHandlerAddon.java b/odk/examples/DevelopersGuide/Components/Addons/ProtocolHandlerAddon_java/ProtocolHandlerAddon.java
index f4f3b7cf6a95..0653ee11055d 100644
--- a/odk/examples/DevelopersGuide/Components/Addons/ProtocolHandlerAddon_java/ProtocolHandlerAddon.java
+++ b/odk/examples/DevelopersGuide/Components/Addons/ProtocolHandlerAddon_java/ProtocolHandlerAddon.java
@@ -150,12 +150,12 @@ public class ProtocolHandlerAddon {
/*IN*/String sTargetFrameName,
/*IN*/int iSearchFlags ) {
XDispatch xRet = null;
- if ( aURL.Protocol.compareTo("org.openoffice.Office.addon.example:") == 0 ) {
- if ( aURL.Path.compareTo( "Function1" ) == 0 )
+ if ( aURL.Protocol.equals("org.openoffice.Office.addon.example:") ) {
+ if ( aURL.Path.equals( "Function1" ) )
xRet = this;
- if ( aURL.Path.compareTo( "Function2" ) == 0 )
+ if ( aURL.Path.equals( "Function2" ) )
xRet = this;
- if ( aURL.Path.compareTo( "Help" ) == 0 )
+ if ( aURL.Path.equals( "Help" ) )
xRet = this;
}
return xRet;
@@ -177,17 +177,17 @@ public class ProtocolHandlerAddon {
public void dispatch( /*IN*/com.sun.star.util.URL aURL,
/*IN*/com.sun.star.beans.PropertyValue[] aArguments ) {
- if ( aURL.Protocol.compareTo("org.openoffice.Office.addon.example:") == 0 )
+ if ( aURL.Protocol.equals("org.openoffice.Office.addon.example:") )
{
- if ( aURL.Path.compareTo( "Function1" ) == 0 )
+ if ( aURL.Path.equals( "Function1" ) )
{
showMessageBox("SDK DevGuide Add-On example", "Function 1 activated");
}
- if ( aURL.Path.compareTo( "Function2" ) == 0 )
+ if ( aURL.Path.equals( "Function2" ) )
{
showMessageBox("SDK DevGuide Add-On example", "Function 2 activated");
}
- if ( aURL.Path.compareTo( "Help" ) == 0 )
+ if ( aURL.Path.equals( "Help" ) )
{
showMessageBox("About SDK DevGuide Add-On example", "This is the SDK Add-On example");
}