summaryrefslogtreecommitdiff
path: root/swext/mediawiki
diff options
context:
space:
mode:
Diffstat (limited to 'swext/mediawiki')
-rw-r--r--swext/mediawiki/build.xml12
-rw-r--r--swext/mediawiki/src/com/sun/star/wiki/EditPageParser.java22
-rw-r--r--swext/mediawiki/src/com/sun/star/wiki/Helper.java142
-rw-r--r--swext/mediawiki/src/com/sun/star/wiki/MainThreadDialogExecutor.java16
-rw-r--r--swext/mediawiki/src/com/sun/star/wiki/Settings.java88
-rw-r--r--swext/mediawiki/src/com/sun/star/wiki/WikiArticle.java88
-rw-r--r--swext/mediawiki/src/com/sun/star/wiki/WikiCancelException.java2
-rw-r--r--swext/mediawiki/src/com/sun/star/wiki/WikiDialog.java56
-rw-r--r--swext/mediawiki/src/com/sun/star/wiki/WikiEditSettingDialog.java64
-rw-r--r--swext/mediawiki/src/com/sun/star/wiki/WikiEditorImpl.java140
-rw-r--r--swext/mediawiki/src/com/sun/star/wiki/WikiOptionsEventHandlerImpl.java22
-rw-r--r--swext/mediawiki/src/com/sun/star/wiki/WikiPropDialog.java40
-rw-r--r--swext/mediawiki/src/com/sun/star/wiki/WikiProtocolSocketFactory.java12
-rw-r--r--swext/mediawiki/src/registry/data/org/openoffice/Office/Addons.xcu2
-rw-r--r--swext/mediawiki/src/registry/data/org/openoffice/Office/Custom/WikiExtension.xcu10
-rw-r--r--swext/mediawiki/src/registry/data/org/openoffice/Office/OptionsDialog.xcu2
-rw-r--r--swext/mediawiki/src/registry/data/org/openoffice/Office/Paths.xcu2
-rw-r--r--swext/mediawiki/src/registry/data/org/openoffice/Office/ProtocolHandler.xcu2
-rw-r--r--swext/mediawiki/src/registry/data/org/openoffice/TypeDetection/Filter.xcu2
-rw-r--r--swext/mediawiki/src/registry/data/org/openoffice/TypeDetection/Types.xcu2
-rw-r--r--swext/mediawiki/src/uno-extension-manifest.xml48
21 files changed, 387 insertions, 387 deletions
diff --git a/swext/mediawiki/build.xml b/swext/mediawiki/build.xml
index cd51dc9d13d8..916abfbd8966 100644
--- a/swext/mediawiki/build.xml
+++ b/swext/mediawiki/build.xml
@@ -2,23 +2,23 @@
<!--***********************************************************************
*
DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-
+
Copyright 2000, 2010 Oracle and/or its affiliates.
-
+
OpenOffice.org - a multi-platform office productivity suite
-
+
This file is part of OpenOffice.org.
-
+
OpenOffice.org is free software: you can redistribute it and/or modify
it under the terms of the GNU Lesser General Public License version 3
only, as published by the Free Software Foundation.
-
+
OpenOffice.org is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU Lesser General Public License version 3 for more details
(a copy is included in the LICENSE file that accompanied this code).
-
+
You should have received a copy of the GNU Lesser General Public License
version 3 along with OpenOffice.org. If not, see
<http://www.openoffice.org/license.html>
diff --git a/swext/mediawiki/src/com/sun/star/wiki/EditPageParser.java b/swext/mediawiki/src/com/sun/star/wiki/EditPageParser.java
index f91819c6bc2a..42cc7a8c6baf 100644
--- a/swext/mediawiki/src/com/sun/star/wiki/EditPageParser.java
+++ b/swext/mediawiki/src/com/sun/star/wiki/EditPageParser.java
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -32,7 +32,7 @@ import javax.swing.text.MutableAttributeSet;
public class EditPageParser extends HTMLEditorKit.ParserCallback
{
-
+
protected String m_sEditTime = "";
protected String m_sEditToken = "";
protected String m_sLoginToken = "";
@@ -48,12 +48,12 @@ public class EditPageParser extends HTMLEditorKit.ParserCallback
protected int m_nHTMLArticleEnd = -1;
protected int m_nNoArticleInd = -1;
protected int m_nErrorInd = -1;
-
+
/** Creates a new instance of WikiHTMLParser */
public EditPageParser()
{
}
-
+
public void handleComment( char[] data,int pos )
{
// insert code to handle comments
@@ -71,8 +71,8 @@ public class EditPageParser extends HTMLEditorKit.ParserCallback
{
m_nHTMLArticleStart = pos+6;
m_bHTMLStartFound = false;
- }
- }
+ }
+ }
else if ( t == HTML.Tag.HEAD )
{
m_bInHead = false;
@@ -149,7 +149,7 @@ public class EditPageParser extends HTMLEditorKit.ParserCallback
{
m_nWikiArticleHash = t.hashCode();
m_nWikiArticleStart = pos;
- }
+ }
}
}
else if ( t == HTML.Tag.DIV )
@@ -161,7 +161,7 @@ public class EditPageParser extends HTMLEditorKit.ParserCallback
if ( sId.equalsIgnoreCase( "contentSub" ) )
{
m_bHTMLStartFound = true;
- }
+ }
}
if ( sClass != null )
{
@@ -171,7 +171,7 @@ public class EditPageParser extends HTMLEditorKit.ParserCallback
}
else if ( sClass.equalsIgnoreCase( "noarticletext" ) )
{
- m_nNoArticleInd = pos;
+ m_nNoArticleInd = pos;
}
else if ( sClass.equalsIgnoreCase( "errorbox" ) )
{
@@ -186,8 +186,8 @@ public class EditPageParser extends HTMLEditorKit.ParserCallback
{
m_nErrorInd = pos;
}
- }
+ }
}
-
+
}
diff --git a/swext/mediawiki/src/com/sun/star/wiki/Helper.java b/swext/mediawiki/src/com/sun/star/wiki/Helper.java
index 7ecd9ecb0e7c..a94dfc07554c 100644
--- a/swext/mediawiki/src/com/sun/star/wiki/Helper.java
+++ b/swext/mediawiki/src/com/sun/star/wiki/Helper.java
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -78,7 +78,7 @@ import org.apache.commons.httpclient.URI;
import org.apache.commons.httpclient.methods.GetMethod;
import org.apache.commons.httpclient.methods.PostMethod;
-public class Helper
+public class Helper
{
public final static int GENERALSEND_ERROR = 0;
public final static int NOWIKIFILTER_ERROR = 1;
@@ -156,7 +156,7 @@ public class Helper
private static final String sHTMLHeader = "<HTML><HEAD><meta http-equiv=\"Content-Type\" content=\"text/html; charset=utf-8\" /><TITLE></TITLE></HEAD><BODY>";
private static final String sHTMLFooter = "</BODY></HTML>";
-
+
private static Random m_aRandom;
private static MultiThreadedHttpConnectionManager m_aConnectionManager;
private static HttpClient m_aClient;
@@ -226,7 +226,7 @@ public class Helper
{
return m_bAllowConnection;
}
-
+
synchronized protected static boolean GetShowInBrowserByDefault( XComponentContext xContext )
{
if ( m_bShowInBrowser == null )
@@ -304,7 +304,7 @@ public class Helper
return new Protocol( "https", new WikiProtocolSocketFactory(), ( ( nPort < 0 ) ? 443 : nPort ) );
}
- protected static String GetMainURL( String sWebPage, String sVURL )
+ protected static String GetMainURL( String sWebPage, String sVURL )
{
String sResultURL = "";
try
@@ -312,11 +312,11 @@ public class Helper
StringReader aReader = new StringReader( sWebPage );
HTMLEditorKit.Parser aParser = GetHTMLParser();
EditPageParser aCallback = new EditPageParser();
-
+
aParser.parse( aReader, aCallback, true );
sResultURL = aCallback.m_sMainURL;
- if ( !sResultURL.startsWith( "http" ) )
+ if ( !sResultURL.startsWith( "http" ) )
{
//if the url is only relative then complete it
URL aURL = new URL( sVURL );
@@ -336,10 +336,10 @@ public class Helper
if ( nIndex >= 0 )
sResultURL = sVURL.substring( 0, nIndex );
}
-
+
return sResultURL;
}
-
+
protected static String GetRedirectURL( String sWebPage, String sURL )
{
//scrape the HTML source and find the EditURL
@@ -347,7 +347,7 @@ public class Helper
String sResultURL = "";
int nInd = sWebPage.indexOf( "http-equiv=\"refresh\"" );
- if ( nInd != -1 )
+ if ( nInd != -1 )
{
int nContent = sWebPage.indexOf( "content=", nInd );
if ( nContent > 0 )
@@ -361,10 +361,10 @@ public class Helper
}
}
- try
+ try
{
URL aURL = new URL( sURL );
- if ( !sResultURL.startsWith( aURL.getProtocol() ))
+ if ( !sResultURL.startsWith( aURL.getProtocol() ))
{
//if the url is only relative then complete it
if ( sResultURL.startsWith( "/" ) )
@@ -373,16 +373,16 @@ public class Helper
sResultURL = aURL.getProtocol() + "://" + aURL.getHost() + aURL.getPath() + sResultURL;
}
}
- catch ( MalformedURLException ex )
+ catch ( MalformedURLException ex )
{
ex.printStackTrace();
- }
+ }
}
return sResultURL;
-
+
}
-
+
protected static XInputStream SaveHTMLTemp( XComponentContext xContext, String sArticle )
{
XInputStream xResult = null;
@@ -390,7 +390,7 @@ public class Helper
if ( xContext != null )
{
try
- {
+ {
Object oTempFile = xContext.getServiceManager().createInstanceWithContext( "com.sun.star.io.TempFile", xContext );
XStream xStream = ( XStream ) UnoRuntime.queryInterface( XStream.class, oTempFile );
XSeekable xSeekable = ( XSeekable ) UnoRuntime.queryInterface( XSeekable.class, oTempFile );
@@ -402,10 +402,10 @@ public class Helper
{
String sHTML = sHTMLHeader.concat( sArticle );
sHTML = sHTML.concat( sHTMLFooter );
- xOutputStream.writeBytes( sHTML.getBytes( "UTF-8" ) );
+ xOutputStream.writeBytes( sHTML.getBytes( "UTF-8" ) );
// xOutputStream.closeOutput();
- xSeekable.seek( 0 );
-
+ xSeekable.seek( 0 );
+
xResult = xInputStream;
}
}
@@ -418,12 +418,12 @@ public class Helper
return xResult;
}
-
-
- protected static String CreateTempFile( XComponentContext xContext )
+
+
+ protected static String CreateTempFile( XComponentContext xContext )
{
String sURL = "";
- try
+ try
{
Object oTempFile = xContext.getServiceManager().createInstanceWithContext( "com.sun.star.io.TempFile", xContext );
XPropertySet xPropertySet = ( XPropertySet ) UnoRuntime.queryInterface( XPropertySet.class, oTempFile );
@@ -434,27 +434,27 @@ public class Helper
xInputStream.closeInput();
XOutputStream xOutputStream = ( XOutputStream ) UnoRuntime.queryInterface( XOutputStream.class, oTempFile );
xOutputStream.closeOutput();
- } catch ( com.sun.star.uno.Exception ex )
+ } catch ( com.sun.star.uno.Exception ex )
{
ex.printStackTrace();
}
- return sURL;
+ return sURL;
}
-
- protected static String EachLine( String sURL )
+
+ protected static String EachLine( String sURL )
{
String sText = "";
- try
+ try
{
URL aURL = new URL( sURL );
- File aFile = new File( aURL.getFile() );
+ File aFile = new File( aURL.getFile() );
InputStreamReader aInputReader = new InputStreamReader( new FileInputStream( aFile ), "UTF-8" );
BufferedReader aBufReader = new BufferedReader( aInputReader );
StringBuffer aBuf = new StringBuffer();
String sEachLine = aBufReader.readLine();
- while( sEachLine != null )
+ while( sEachLine != null )
{
aBuf.append( sEachLine );
aBuf.append( "\n" );
@@ -462,28 +462,28 @@ public class Helper
sEachLine = aBufReader.readLine();
}
sText = aBuf.toString();
- } catch ( Exception e )
+ } catch ( Exception e )
{
e.printStackTrace();
}
return sText;
}
-
- protected static String GetDocTitle( XModel xDoc )
+
+ protected static String GetDocTitle( XModel xDoc )
{
String sTitle = "";
XDocumentInfoSupplier xDocInfoSup = ( XDocumentInfoSupplier ) UnoRuntime.queryInterface( XDocumentInfoSupplier.class, xDoc );
XPropertySet xPropSet = ( XPropertySet ) UnoRuntime.queryInterface( XPropertySet.class, xDocInfoSup.getDocumentInfo() );
- try
+ try
{
sTitle = ( String ) xPropSet.getPropertyValue( "Title" );
- } catch ( Exception ex )
+ } catch ( Exception ex )
{
ex.printStackTrace();
- }
+ }
return sTitle;
}
-
+
protected static void SetDocTitle( XModel xDoc, String sTitle )
{
XDocumentInfoSupplier xDocInfoSup = ( XDocumentInfoSupplier ) UnoRuntime.queryInterface( XDocumentInfoSupplier.class, xDoc );
@@ -499,10 +499,10 @@ public class Helper
catch ( Exception ex )
{
ex.printStackTrace();
- }
+ }
}
}
- }
+ }
protected static String GetDocServiceName( XComponentContext xContext, XModel xModel )
{
@@ -514,7 +514,7 @@ public class Helper
XMultiComponentFactory xFactory = xContext.getServiceManager();
if ( xFactory == null )
throw new com.sun.star.uno.RuntimeException();
-
+
Object oModuleManager = xFactory.createInstanceWithContext( "com.sun.star.frame.ModuleManager", xContext );
XModuleManager xModuleManager = ( XModuleManager ) UnoRuntime.queryInterface( XModuleManager.class, oModuleManager );
if ( xModuleManager != null )
@@ -528,7 +528,7 @@ public class Helper
return aDocServiceName;
}
-
+
protected static String GetFilterName( XComponentContext xContext, String aTypeName, String aDocServiceName )
{
String aFilterName = "";
@@ -544,7 +544,7 @@ public class Helper
NamedValue[] aRequest = new NamedValue[2];
aRequest[0] = new NamedValue( "Type", aTypeName );
aRequest[1] = new NamedValue( "DocumentService", aDocServiceName );
-
+
XEnumeration xSet = xQuery.createSubSetEnumerationByProperties( aRequest );
if ( xSet != null )
{
@@ -594,7 +594,7 @@ public class Helper
if ( xConfigurationProvider == null )
throw new com.sun.star.uno.RuntimeException();
-
+
return xConfigurationProvider;
}
@@ -609,11 +609,11 @@ public class Helper
aVal.Value = sNodepath;
Object[] aArgs = new Object[1];
aArgs[0] = aVal;
-
+
return GetConfigurationProvider( xContext ).createInstanceWithArguments(
( bWriteAccess ? "com.sun.star.configuration.ConfigurationUpdateAccess"
: "com.sun.star.configuration.ConfigurationAccess" ),
- aArgs );
+ aArgs );
}
protected static XPropertySet GetConfigProps( XComponentContext xContext, String sNodepath )
@@ -622,7 +622,7 @@ public class Helper
XPropertySet xProps = ( XPropertySet ) UnoRuntime.queryInterface( XPropertySet.class, GetConfig( xContext, sNodepath, true ) );
if ( xProps == null )
throw new com.sun.star.uno.RuntimeException();
-
+
return xProps;
}
@@ -633,7 +633,7 @@ public class Helper
XNameContainer xContainer = ( XNameContainer ) UnoRuntime.queryInterface( XNameContainer.class, GetConfig( xContext, sNodepath, true ) );
if ( xContainer == null )
throw new com.sun.star.uno.RuntimeException();
-
+
return xContainer;
}
@@ -643,7 +643,7 @@ public class Helper
XNameAccess xNameAccess = ( XNameAccess ) UnoRuntime.queryInterface( XNameAccess.class, GetConfig( xContext, sNodepath, false ) );
if ( xNameAccess == null )
throw new com.sun.star.uno.RuntimeException();
-
+
return xNameAccess;
}
@@ -651,7 +651,7 @@ public class Helper
{
if ( aHostConfig == null || xContext == null )
return;
-
+
try
{
XNameAccess xNameAccess = GetConfigNameAccess( xContext, "org.openoffice.Inet/Settings" );
@@ -678,13 +678,13 @@ public class Helper
String aNoProxyList = AnyConverter.toString( xNameAccess.getByName( "ooInetNoProxy" ) );
String aProxyName = AnyConverter.toString( xNameAccess.getByName( aProxyNameProp ) );
-
+
int nProxyPort = 80;
Object aPortNo = xNameAccess.getByName( aProxyPortProp );
if ( !AnyConverter.isVoid( aPortNo ) )
nProxyPort = AnyConverter.toInt( aPortNo );
-
+
if ( nProxyPort == -1 )
nProxyPort = 80;
@@ -716,7 +716,7 @@ public class Helper
}
}
}
-
+
protected static void ExecuteMethod( HttpMethodBase aMethod, HostConfiguration aHostConfig, URI aURI, XComponentContext xContext, boolean bSetHost )
throws WikiCancelException, IOException, SSLException
{
@@ -750,7 +750,7 @@ public class Helper
static private class HTMLParse extends HTMLEditorKit
{
- public HTMLEditorKit.Parser getParser()
+ public HTMLEditorKit.Parser getParser()
{
return super.getParser();
}
@@ -760,7 +760,7 @@ public class Helper
{
return new HTMLParse().getParser();
}
-
+
static protected boolean LoginReportsError( String sRespond )
{
boolean bResult = true;
@@ -771,7 +771,7 @@ public class Helper
StringReader aReader = new StringReader( sRespond );
HTMLEditorKit.Parser aParser = GetHTMLParser();
EditPageParser aCallback = new EditPageParser();
-
+
aParser.parse( aReader, aCallback, true );
bResult = ( aCallback.m_nErrorInd >= 0 );
}
@@ -780,7 +780,7 @@ public class Helper
e.printStackTrace();
}
}
-
+
return bResult;
}
@@ -794,7 +794,7 @@ public class Helper
StringReader aReader = new StringReader( sLoginPage );
HTMLEditorKit.Parser aParser = Helper.GetHTMLParser();
EditPageParser aCallbacks = new EditPageParser();
-
+
aParser.parse( aReader, aCallbacks, true );
sResult = aCallbacks.m_sLoginToken;
}
@@ -807,7 +807,7 @@ public class Helper
return sResult;
}
- static protected HostConfiguration Login( URI aMainURL, String sWikiUser, String sWikiPass, XComponentContext xContext )
+ static protected HostConfiguration Login( URI aMainURL, String sWikiUser, String sWikiPass, XComponentContext xContext )
throws com.sun.star.uno.Exception, java.io.IOException, WikiCancelException
{
HostConfiguration aHostConfig = null;
@@ -841,7 +841,7 @@ public class Helper
aPost.addParameter( "wpPassword", sWikiPass );
if ( sLoginToken.length() > 0 )
aPost.addParameter( "wpLoginToken", sLoginToken );
-
+
String[][] pArgs = GetSpecialArgs( xContext, aMainURL.getHost() );
if ( pArgs != null )
for ( int nArgInd = 0; nArgInd < pArgs.length; nArgInd++ )
@@ -849,7 +849,7 @@ public class Helper
aPost.addParameter( pArgs[nArgInd][0], pArgs[nArgInd][1] );
ExecuteMethod( aPost, aNewHostConfig, aPostURI, xContext, false );
-
+
nResultCode = aPost.getStatusCode();
while( nResultCode >= 301 && nResultCode <= 303 || nResultCode == 307 )
@@ -864,14 +864,14 @@ public class Helper
nResultCode = aPost.getStatusCode();
}
-
+
if ( nResultCode == 200 )
{
String sResult = aPost.getResponseBodyAsString();
if ( !LoginReportsError( sResult ) )
aHostConfig = aNewHostConfig;
}
-
+
aPost.releaseConnection();
}
}
@@ -883,7 +883,7 @@ public class Helper
{
XControl xResult = null;
XControlContainer xControlCont = (XControlContainer) UnoRuntime.queryInterface( XControlContainer.class, xDialog );
-
+
if ( xControlCont != null )
{
Object oControl = xControlCont.getControl( aControlName );
@@ -898,7 +898,7 @@ public class Helper
XControl xControl = GetControlFromDialog( xDialog, aControlName );
if ( xControl != null )
return ( XPropertySet ) UnoRuntime.queryInterface( XPropertySet.class, xControl.getModel() );
-
+
return null;
}
@@ -916,7 +916,7 @@ public class Helper
{
e.printStackTrace();
}
- }
+ }
}
protected static String[] GetPasswordsForURLAndUser( XComponentContext xContext, String sURL, String sUserName )
@@ -966,7 +966,7 @@ public class Helper
xPeer = xControl.getPeer();
ShowError( xContext, xPeer, nTitleID, nErrorID, sArg, bQuery );
}
-
+
protected static boolean ShowError( XComponentContext xContext, XWindowPeer xParentPeer, int nTitleID, int nErrorID, String sArg, boolean bQuery )
{
boolean bResult = false;
@@ -977,7 +977,7 @@ public class Helper
String sError = null;
String sTitle = "";
-
+
try
{
sError = GetLocalizedString( xContext, nErrorID );
@@ -1005,7 +1005,7 @@ public class Helper
xMBFactory = (XMessageBoxFactory)UnoRuntime.queryInterface(
XMessageBoxFactory.class,
xFactory.createInstanceWithContext( "com.sun.star.awt.Toolkit", xContext ) );
-
+
if ( xMBFactory != null )
{
if ( bQuery )
@@ -1092,7 +1092,7 @@ public class Helper
XNameAccess xArgument = (XNameAccess)UnoRuntime.queryInterface( XNameAccess.class, xArgs.getByName( pNames[nInd] ) );
if ( xArgument == null )
throw new com.sun.star.uno.RuntimeException();
-
+
pResult[nInd][0] = pNames[nInd];
pResult[nInd][1] = AnyConverter.toString( xArgument.getByName( "Value" ) );
}
@@ -1129,7 +1129,7 @@ public class Helper
e.printStackTrace();
}
}
-
+
return false;
}
diff --git a/swext/mediawiki/src/com/sun/star/wiki/MainThreadDialogExecutor.java b/swext/mediawiki/src/com/sun/star/wiki/MainThreadDialogExecutor.java
index dbf849fa4ef0..ddc7602f9cf0 100644
--- a/swext/mediawiki/src/com/sun/star/wiki/MainThreadDialogExecutor.java
+++ b/swext/mediawiki/src/com/sun/star/wiki/MainThreadDialogExecutor.java
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -50,7 +50,7 @@ public class MainThreadDialogExecutor implements XCallback
MainThreadDialogExecutor aExecutor = new MainThreadDialogExecutor( aWikiDialog );
return GetCallback( xContext, aExecutor );
}
-
+
static public boolean Execute( XComponentContext xContext, XDialog xDialog )
{
MainThreadDialogExecutor aExecutor = new MainThreadDialogExecutor( xDialog );
@@ -86,7 +86,7 @@ public class MainThreadDialogExecutor implements XCallback
XMultiComponentFactory xFactory = xContext.getServiceManager();
if ( xFactory == null )
throw new com.sun.star.uno.RuntimeException();
-
+
XRequestCallback xRequest = (XRequestCallback)UnoRuntime.queryInterface(
XRequestCallback.class,
xFactory.createInstanceWithContext( "com.sun.star.awt.AsyncCallback", xContext ) );
@@ -114,7 +114,7 @@ public class MainThreadDialogExecutor implements XCallback
return aExecutor.GetResult();
}
-
+
private MainThreadDialogExecutor( WikiDialog aWikiDialog )
{
m_aWikiDialog = aWikiDialog;
@@ -141,7 +141,7 @@ public class MainThreadDialogExecutor implements XCallback
{
return m_bResult;
}
-
+
public void notify( Object aData )
{
if ( m_aWikiDialog != null )
@@ -155,7 +155,7 @@ public class MainThreadDialogExecutor implements XCallback
try
{
m_xDialog.endExecute();
- }
+ }
catch( Exception e )
{
e.printStackTrace();
@@ -166,10 +166,10 @@ public class MainThreadDialogExecutor implements XCallback
else if ( m_xMessageBox != null )
{
int nRes = m_xMessageBox.execute();
- m_bResult = ( nRes == com.sun.star.awt.MessageBoxCommand.OK
+ m_bResult = ( nRes == com.sun.star.awt.MessageBoxCommand.OK
|| nRes == com.sun.star.awt.MessageBoxCommand.YES );
}
-
+
m_bCalled = true;
}
};
diff --git a/swext/mediawiki/src/com/sun/star/wiki/Settings.java b/swext/mediawiki/src/com/sun/star/wiki/Settings.java
index d14c4eae4b52..b4ba8cd4fe44 100644
--- a/swext/mediawiki/src/com/sun/star/wiki/Settings.java
+++ b/swext/mediawiki/src/com/sun/star/wiki/Settings.java
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -42,25 +42,25 @@ import java.util.Vector;
public class Settings
{
-
+
private XComponentContext m_xContext;
private int lastUsedWikiServer = 0;
-
-
+
+
/* Singelton */
private static Settings m_instance;
-
-
+
+
private Vector m_WikiConnections = new Vector();
private Vector m_aWikiDocs = new Vector();
-
+
private Settings( XComponentContext ctx )
{
m_xContext=ctx;
loadConfiguration();
}
-
-
+
+
public static synchronized Settings getSettings( XComponentContext ctx )
{
if ( m_instance == null )
@@ -68,19 +68,19 @@ public class Settings
// m_instance.loadSettings();
return m_instance;
}
-
-
+
+
public void addWikiCon ( Hashtable wikiCon )
{
m_WikiConnections.add( wikiCon );
}
-
-
+
+
public Vector getWikiCons()
{
return m_WikiConnections;
}
-
+
public String getWikiConUrlByNumber( int num )
{
String url = "";
@@ -91,8 +91,8 @@ public class Settings
}
return url;
}
-
-
+
+
public void addWikiDoc ( Hashtable aWikiDoc )
{
String sURL = ( String ) aWikiDoc.get( "CompleteUrl" );
@@ -111,13 +111,13 @@ public class Settings
m_aWikiDocs.add( aWikiDoc );
}
-
-
+
+
public Vector getWikiDocs()
{
return m_aWikiDocs;
}
-
+
public Object[] getWikiDocList( int serverid, int num )
{
String wikiserverurl = getWikiConUrlByNumber( serverid );
@@ -134,17 +134,17 @@ public class Settings
}
return theDocs.toArray( docs );
}
-
+
public int getLastUsedWikiServer()
{
return lastUsedWikiServer;
}
-
+
public void setLastUsedWikiServer( int l )
{
lastUsedWikiServer = l;
}
-
+
public String[] getWikiURLs()
{
String [] WikiList = new String [m_WikiConnections.size()];
@@ -155,8 +155,8 @@ public class Settings
}
return WikiList;
}
-
-
+
+
public Hashtable getSettingByUrl( String sUrl )
{
Hashtable ht = null;
@@ -188,7 +188,7 @@ public class Settings
}
return ht;
}
-
+
public Hashtable getDocByCompleteUrl( String curl )
{
Hashtable ht = null;
@@ -203,8 +203,8 @@ public class Settings
}
return ht;
}
-
-
+
+
public void removeSettingByUrl( String sUrl )
{
Hashtable ht = null;
@@ -218,8 +218,8 @@ public class Settings
}
}
}
-
-
+
+
public void storeConfiguration()
{
try
@@ -228,10 +228,10 @@ public class Settings
XNameContainer xContainer = Helper.GetConfigNameContainer( m_xContext, "org.openoffice.Office.Custom.WikiExtension/ConnectionList" );
String[] pNames = xContainer.getElementNames();
for( int i=0; i<pNames.length; i++ )
- {
+ {
xContainer.removeByName( pNames[i] );
}
-
+
// store all connections
XSingleServiceFactory xConnectionFactory = ( XSingleServiceFactory ) UnoRuntime.queryInterface( XSingleServiceFactory.class, xContainer );
for ( int i=0; i< m_WikiConnections.size(); i++ )
@@ -239,21 +239,21 @@ public class Settings
Object oNewConnection = xConnectionFactory.createInstance();
Hashtable ht = ( Hashtable ) m_WikiConnections.get( i );
XNameReplace xNewConn = ( XNameReplace ) UnoRuntime.queryInterface( XNameReplace.class, oNewConnection );
-
+
if ( xNewConn != null )
xNewConn.replaceByName( "UserName", ht.get( "Username" ) );
-
+
xContainer.insertByName( (String)ht.get( "Url" ), xNewConn );
}
// commit changes
XChangesBatch xBatch = ( XChangesBatch ) UnoRuntime.queryInterface( XChangesBatch.class, xContainer );
xBatch.commitChanges();
-
+
// remove stored connection information
XNameContainer xContainer2 = Helper.GetConfigNameContainer( m_xContext, "org.openoffice.Office.Custom.WikiExtension/RecentDocs" );
String[] pNames2 = xContainer2.getElementNames();
for( int i=0; i<pNames2.length; i++ )
- {
+ {
xContainer2.removeByName( pNames2[i] );
}
// store all Docs
@@ -261,30 +261,30 @@ public class Settings
for ( int i=0; i< m_aWikiDocs.size(); i++ )
{
Hashtable ht = ( Hashtable ) m_aWikiDocs.get( i );
-
+
Object oNewDoc = xDocListFactory.createInstance();
XNameReplace xNewDoc = ( XNameReplace ) UnoRuntime.queryInterface( XNameReplace.class, oNewDoc );
-
+
Enumeration e = ht.keys();
while ( e.hasMoreElements() )
{
String key = ( String ) e.nextElement();
xNewDoc.replaceByName( key, ht.get( key ) );
}
-
+
xContainer2.insertByName( "d" + i, xNewDoc );
}
// commit changes
XChangesBatch xBatch2 = ( XChangesBatch ) UnoRuntime.queryInterface( XChangesBatch.class, xContainer2 );
xBatch2.commitChanges();
-
+
}
catch ( Exception ex )
{
ex.printStackTrace();
- }
+ }
}
-
+
public void loadConfiguration()
{
m_WikiConnections.clear();
@@ -293,7 +293,7 @@ public class Settings
// get configuration service
// connect to configmanager
XNameAccess xAccess = Helper.GetConfigNameAccess( m_xContext, "org.openoffice.Office.Custom.WikiExtension" );
-
+
if ( xAccess != null )
{
Object oList = xAccess.getByName( "ConnectionList" );
@@ -320,7 +320,7 @@ public class Settings
{
e.printStackTrace();
}
-
+
addWikiCon( ht );
}
@@ -342,6 +342,6 @@ public class Settings
catch ( Exception ex )
{
ex.printStackTrace();
- }
+ }
}
}
diff --git a/swext/mediawiki/src/com/sun/star/wiki/WikiArticle.java b/swext/mediawiki/src/com/sun/star/wiki/WikiArticle.java
index 89025ed84513..1859ca5fd21a 100644
--- a/swext/mediawiki/src/com/sun/star/wiki/WikiArticle.java
+++ b/swext/mediawiki/src/com/sun/star/wiki/WikiArticle.java
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -37,27 +37,27 @@ import org.apache.commons.httpclient.*;
import org.apache.commons.httpclient.methods.*;
-public class WikiArticle
+public class WikiArticle
{
private XComponentContext m_xContext;
-
+
private String m_sEditTime = "";
private String m_sEditToken = "";
-
+
protected String m_sHTMLCode;
private boolean m_bNoArticle = true;
-
+
protected String m_sWikiUser;
protected String m_sWikiPass;
-
+
protected String m_sTitle = "";
-
+
private URI m_aMainURI;
private HostConfiguration m_aHostConfig;
-
-
+
+
/** Creates a new instance of WikiArticle */
- public WikiArticle( XComponentContext xContext, String sTitle, Hashtable wikiSettings, boolean bLogin, WikiPropDialog aPropDialog )
+ public WikiArticle( XComponentContext xContext, String sTitle, Hashtable wikiSettings, boolean bLogin, WikiPropDialog aPropDialog )
throws java.net.MalformedURLException, com.sun.star.uno.Exception, java.io.IOException, WikiCancelException
{
m_xContext = xContext;
@@ -66,7 +66,7 @@ public class WikiArticle
m_sWikiUser = (String) wikiSettings.get("Username");
m_sWikiPass = (String) wikiSettings.get("Password");
m_sTitle = sTitle;
-
+
m_aMainURI = new URI( sMainUrl );
// viewURL = sMainUrl + "index.php?title=" + m_sTitle;
@@ -92,7 +92,7 @@ public class WikiArticle
}
else
throw new WikiCancelException();
-
+
if ( aPropDialog != null )
{
aPropDialog.SetThrobberActive( true );
@@ -110,29 +110,29 @@ public class WikiArticle
// in case of saving the contents should be checked whether they are empty
InitArticleHTML();
- // getArticleWiki();
+ // getArticleWiki();
}
public String GetMainURL()
{
return m_aMainURI.toString();
}
-
+
public String GetTitle()
{
return m_sTitle;
}
-
+
public String GetViewURL()
{
return m_aMainURI.toString() + "index.php?title=" + m_sTitle;
}
-
- private String getArticleWiki()
+
+ private String getArticleWiki()
throws com.sun.star.uno.Exception, java.io.IOException, WikiCancelException
{
String sWikiCode = null;
-
+
if ( m_aHostConfig != null )
{
URI aURI = new URI( m_aMainURI.toString() + "index.php?title=" + m_sTitle + "&action=edit" );
@@ -144,7 +144,7 @@ public class WikiArticle
String sWebPage = null;
if ( nResultCode == 200 )
sWebPage = aRequest.getResponseBodyAsString();
-
+
aRequest.releaseConnection();
if ( sWebPage != null )
@@ -152,14 +152,14 @@ public class WikiArticle
StringReader r = new StringReader(sWebPage);
HTMLEditorKit.Parser parse = Helper.GetHTMLParser();
EditPageParser callback = new EditPageParser();
-
+
parse.parse(r,callback,true);
m_sEditTime = callback.m_sEditTime;
m_sEditToken = callback.m_sEditToken;
-
+
int iPosStart = callback.m_nWikiArticleStart;
int iPosEnd = callback.m_nWikiArticleEnd;
-
+
if ( iPosStart >= 0 && iPosEnd > 0 )
{
String sArticle = sWebPage.substring(iPosStart, iPosEnd);
@@ -168,11 +168,11 @@ public class WikiArticle
}
}
}
-
+
return sWikiCode;
}
-
- private void InitArticleHTML()
+
+ private void InitArticleHTML()
throws com.sun.star.uno.Exception, java.io.IOException, WikiCancelException
{
if ( m_aHostConfig != null )
@@ -186,19 +186,19 @@ public class WikiArticle
String sWebPage = null;
if ( nResultCode == 200 )
sWebPage = aRequest.getResponseBodyAsString();
-
+
if ( sWebPage != null )
{
StringReader r = new StringReader(sWebPage);
HTMLEditorKit.Parser parse = Helper.GetHTMLParser();
EditPageParser callback = new EditPageParser();
-
+
parse.parse(r,callback,true);
-
+
int iPosStart = callback.m_nHTMLArticleStart;
int iPosEnd = callback.m_nHTMLArticleEnd;
int nPosNoArt = callback.m_nNoArticleInd;
-
+
if ( iPosStart >= 0 && iPosEnd > 0 )
{
m_sHTMLCode = sWebPage.substring(iPosStart, iPosEnd);
@@ -207,8 +207,8 @@ public class WikiArticle
}
}
}
-
- protected boolean setArticle( String sWikiCode, String sWikiComment, boolean bMinorEdit )
+
+ protected boolean setArticle( String sWikiCode, String sWikiComment, boolean bMinorEdit )
throws com.sun.star.uno.Exception, java.io.IOException, WikiCancelException
{
boolean bResult = false;
@@ -231,7 +231,7 @@ public class WikiArticle
aPost.addParameter( "wpSave", "Save page" );
aPost.addParameter( "wpEditToken", m_sEditToken );
- if ( bMinorEdit )
+ if ( bMinorEdit )
aPost.addParameter( "wpMinoredit", "1" );
Helper.ExecuteMethod( aPost, m_aHostConfig, aURI, m_xContext, false );
@@ -248,47 +248,47 @@ public class WikiArticle
return bResult;
}
-
- protected boolean Login()
+
+ protected boolean Login()
throws com.sun.star.uno.Exception, java.io.IOException, WikiCancelException
{
m_aHostConfig = Helper.Login( m_aMainURI, m_sWikiUser, m_sWikiPass, m_xContext );
return ( m_aHostConfig != null );
}
-
- protected void cleanHTML()
+
+ protected void cleanHTML()
{
if ( m_sHTMLCode != null )
{
//Welcome to regex hell ;)
-
+
//strip comments
m_sHTMLCode = m_sHTMLCode.replaceAll("\\<![ \\r\\n\\t]*(--([^\\-]|[\\r\\n]|-[^\\-])*--[ \\r\\n\\t]*)\\>","");
-
+
//strip edit section links
m_sHTMLCode = m_sHTMLCode.replaceAll("\\<div class=\"editsection\".*?\\</div\\>","");
-
+
//strip huge spaces
m_sHTMLCode = m_sHTMLCode.replaceAll("\\<p\\>\\<br /\\>[ \r\n\t]*?\\</p\\>","");
-
+
//strip toc
m_sHTMLCode = m_sHTMLCode.replaceAll("\\<table.*id=\"toc\"(.|[\r\n])*?\\</table\\>","");
//strip jump-to-nav
m_sHTMLCode = m_sHTMLCode.replaceAll("\\<div id=\"jump-to-nav\".*?\\</div\\>","");
-
+
//strip Javascript
m_sHTMLCode = m_sHTMLCode.replaceAll("\\<script(.|[\r\n])*?\\</script\\>","");
}
}
-
-
+
+
protected boolean NotExist()
{
boolean bResult = true;
if ( m_sHTMLCode != null )
bResult = m_bNoArticle;
-
+
return bResult;
}
diff --git a/swext/mediawiki/src/com/sun/star/wiki/WikiCancelException.java b/swext/mediawiki/src/com/sun/star/wiki/WikiCancelException.java
index 73369c997727..b76e004b65c8 100644
--- a/swext/mediawiki/src/com/sun/star/wiki/WikiCancelException.java
+++ b/swext/mediawiki/src/com/sun/star/wiki/WikiCancelException.java
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
diff --git a/swext/mediawiki/src/com/sun/star/wiki/WikiDialog.java b/swext/mediawiki/src/com/sun/star/wiki/WikiDialog.java
index e91f053169e7..cd01675bae45 100644
--- a/swext/mediawiki/src/com/sun/star/wiki/WikiDialog.java
+++ b/swext/mediawiki/src/com/sun/star/wiki/WikiDialog.java
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -46,14 +46,14 @@ import com.sun.star.lang.EventObject;
import com.sun.star.lang.XMultiServiceFactory;
public class WikiDialog implements XDialogEventHandler, XTopWindowListener
-{
+{
XComponentContext m_xContext;
XControlContainer m_xControlContainer;
XDialog m_xDialog;
String[] m_aMethods;
boolean m_bAction = false;
Settings m_aSettings;
-
+
protected Thread m_aThread;
protected boolean m_bThreadFinished = false;
@@ -69,7 +69,7 @@ public class WikiDialog implements XDialogEventHandler, XTopWindowListener
Object obj;
obj = xMCF.createInstanceWithContext("com.sun.star.awt.DialogProvider2", m_xContext );
XDialogProvider2 xDialogProvider = (XDialogProvider2) UnoRuntime.queryInterface( XDialogProvider2.class, obj );
-
+
m_xDialog = xDialogProvider.createDialogWithHandler( DialogURL, this );
m_xControlContainer = (XControlContainer)UnoRuntime.queryInterface( XControlContainer.class, m_xDialog );
XTopWindow xTopWindow = (XTopWindow)UnoRuntime.queryInterface( XTopWindow.class, m_xDialog );
@@ -81,7 +81,7 @@ public class WikiDialog implements XDialogEventHandler, XTopWindowListener
ex.printStackTrace();
}
}
-
+
public synchronized void ThreadStop( boolean bSelf )
{
if ( bSelf || m_aThread != null && !m_bThreadFinished )
@@ -100,38 +100,38 @@ public class WikiDialog implements XDialogEventHandler, XTopWindowListener
m_bThreadFinished = true;
}
- protected void setMethods (String [] Methods)
+ protected void setMethods (String [] Methods)
{
this.m_aMethods = Methods;
}
-
-
- public boolean show( )
+
+
+ public boolean show( )
{
m_bThreadFinished = false;
if( m_xDialog != null ) m_xDialog.execute();
return m_bAction;
}
-
-
- public String[] getSupportedMethodNames()
+
+
+ public String[] getSupportedMethodNames()
{
return m_aMethods;
}
-
-
+
+
public boolean callHandlerMethod( XDialog xDialog, Object EventObject, String MethodName )
{
return true;
}
-
+
public void SetTitle( String sTitle )
throws Exception
{
SetTitle( m_xDialog, sTitle );
}
-
+
public static void SetTitle( XDialog xDialog, String sTitle )
throws Exception
{
@@ -146,7 +146,7 @@ public class WikiDialog implements XDialogEventHandler, XTopWindowListener
}
}
}
-
+
protected XPropertySet GetPropSet(String sControl)
{
return GetPropSet( m_xControlContainer, sControl );
@@ -164,7 +164,7 @@ public class WikiDialog implements XDialogEventHandler, XTopWindowListener
if ( xPS == null )
throw new com.sun.star.uno.RuntimeException();
-
+
return xPS;
}
@@ -178,7 +178,7 @@ public class WikiDialog implements XDialogEventHandler, XTopWindowListener
{
Object oDialogProvider = xContext.getServiceManager().createInstanceWithContext("com.sun.star.awt.DialogProvider2", xContext );
XDialogProvider2 xDialogProvider = (XDialogProvider2) UnoRuntime.queryInterface( XDialogProvider2.class, oDialogProvider );
-
+
if ( xDialogProvider != null )
xResult = xDialogProvider.createDialog( sURL );
@@ -197,11 +197,11 @@ public class WikiDialog implements XDialogEventHandler, XTopWindowListener
{
ex.printStackTrace();
}
- }
+ }
return xResult;
}
-
+
protected void InsertThrobber( int X, int Y, int Width, int Height )
{
try
@@ -218,7 +218,7 @@ public class WikiDialog implements XDialogEventHandler, XTopWindowListener
XPropertySet xThrobberProps = (XPropertySet)UnoRuntime.queryInterface( XPropertySet.class, xThrobberModel );
if ( xThrobberProps != null )
{
- xThrobberProps.setPropertyValue( "Name", "WikiThrobber" );
+ xThrobberProps.setPropertyValue( "Name", "WikiThrobber" );
xThrobberProps.setPropertyValue( "PositionX", new Integer( X ) );
xThrobberProps.setPropertyValue( "PositionY", new Integer( Y ) );
xThrobberProps.setPropertyValue( "Height", new Integer( Width ) );
@@ -264,7 +264,7 @@ public class WikiDialog implements XDialogEventHandler, XTopWindowListener
if ( m_xControlContainer != null )
{
try
- {
+ {
XWindow xWindow = (XWindow)UnoRuntime.queryInterface( XWindow.class, m_xControlContainer.getControl( "WikiThrobber" ) );
if ( xWindow != null )
xWindow.setVisible( bVisible );
@@ -273,7 +273,7 @@ public class WikiDialog implements XDialogEventHandler, XTopWindowListener
{
e.printStackTrace();
}
- }
+ }
}
public void SetFocusTo( String aControl )
@@ -281,7 +281,7 @@ public class WikiDialog implements XDialogEventHandler, XTopWindowListener
if ( m_xControlContainer != null )
{
try
- {
+ {
XWindow xWindow = (XWindow)UnoRuntime.queryInterface( XWindow.class, m_xControlContainer.getControl( aControl ) );
if ( xWindow != null )
xWindow.setFocus();
@@ -290,14 +290,14 @@ public class WikiDialog implements XDialogEventHandler, XTopWindowListener
{
e.printStackTrace();
}
- }
+ }
}
public void DisposeDialog()
{
Helper.Dispose( m_xDialog );
}
-
+
public void windowOpened( EventObject e )
{}
@@ -318,7 +318,7 @@ public class WikiDialog implements XDialogEventHandler, XTopWindowListener
public void windowDeactivated( EventObject e )
{}
-
+
public void disposing( EventObject e )
{}
}
diff --git a/swext/mediawiki/src/com/sun/star/wiki/WikiEditSettingDialog.java b/swext/mediawiki/src/com/sun/star/wiki/WikiEditSettingDialog.java
index 721b432779a1..44a75dc5ee13 100644
--- a/swext/mediawiki/src/com/sun/star/wiki/WikiEditSettingDialog.java
+++ b/swext/mediawiki/src/com/sun/star/wiki/WikiEditSettingDialog.java
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -40,18 +40,18 @@ import javax.net.ssl.SSLException;
import org.apache.commons.httpclient.*;
import org.apache.commons.httpclient.methods.*;
-public class WikiEditSettingDialog extends WikiDialog
+public class WikiEditSettingDialog extends WikiDialog
{
-
+
private final String sOKMethod = "OK";
- String[] Methods =
+ String[] Methods =
{sOKMethod };
private Hashtable setting;
private boolean addMode;
private boolean m_bAllowURLChange = true;
- public WikiEditSettingDialog( XComponentContext xContext, String DialogURL )
+ public WikiEditSettingDialog( XComponentContext xContext, String DialogURL )
{
super( xContext, DialogURL );
super.setMethods( Methods );
@@ -60,21 +60,21 @@ public class WikiEditSettingDialog extends WikiDialog
InsertThrobber( 184, 20, 10, 10 );
InitStrings( xContext );
- InitSaveCheckbox( xContext, false );
+ InitSaveCheckbox( xContext, false );
}
-
- public WikiEditSettingDialog( XComponentContext xContext, String DialogURL, Hashtable ht, boolean bAllowURLChange )
+
+ public WikiEditSettingDialog( XComponentContext xContext, String DialogURL, Hashtable ht, boolean bAllowURLChange )
{
super( xContext, DialogURL );
super.setMethods( Methods );
setting = ht;
-
+
boolean bInitSaveCheckBox = false;
-
- try
+
+ try
{
XPropertySet xUrlField = GetPropSet( "UrlField" );
-
+
xUrlField.setPropertyValue( "Text", ht.get( "Url" ) );
GetPropSet( "UsernameField" ).setPropertyValue( "Text", ht.get( "Username" ) );
@@ -88,20 +88,20 @@ public class WikiEditSettingDialog extends WikiDialog
// the password should be entered by the user or the Cancel should be pressed
// GetPropSet( "PasswordField" ).setPropertyValue( "Text", ht.get( "Password" ));
}
- catch ( Exception ex )
+ catch ( Exception ex )
{
ex.printStackTrace();
- }
+ }
- addMode = false;
+ addMode = false;
m_bAllowURLChange = bAllowURLChange;
-
+
InsertThrobber( 184, 20, 10, 10 );
InitStrings( xContext );
InitSaveCheckbox( xContext, bInitSaveCheckBox );
}
- public boolean show( )
+ public boolean show( )
{
SetThrobberVisible( false );
EnableControls( true );
@@ -127,7 +127,7 @@ public class WikiEditSettingDialog extends WikiDialog
{
e.printStackTrace();
}
-
+
return bResult;
}
@@ -136,7 +136,7 @@ public class WikiEditSettingDialog extends WikiDialog
if ( !bEnable )
SetFocusTo( "CancelButton" );
- try
+ try
{
GetPropSet( "UsernameField" ).setPropertyValue( "Enabled", new Boolean( bEnable ) );
GetPropSet( "PasswordField" ).setPropertyValue( "Enabled", new Boolean( bEnable ) );
@@ -158,10 +158,10 @@ public class WikiEditSettingDialog extends WikiDialog
GetPropSet( "SaveBox" ).setPropertyValue( "Enabled", Boolean.FALSE );
}
}
- catch ( Exception ex )
+ catch ( Exception ex )
{
ex.printStackTrace();
- }
+ }
}
private void InitStrings( XComponentContext xContext )
@@ -194,9 +194,9 @@ public class WikiEditSettingDialog extends WikiDialog
catch( Exception e )
{
e.printStackTrace();
- }
+ }
}
-
+
public void DoLogin( XDialog xDialog )
{
String sRedirectURL = "";
@@ -235,12 +235,12 @@ public class WikiEditSettingDialog extends WikiDialog
sRedirectURL = aRequest.getResponseHeader( "Location" ).getValue();
aRequest.releaseConnection();
-
+
if ( sWebPage != null && sWebPage.length() > 0 )
{
//the URL is valid
String sMainURL = Helper.GetMainURL( sWebPage, sURL );
-
+
if ( sMainURL.equals( "" ) )
{
// TODO:
@@ -285,7 +285,7 @@ public class WikiEditSettingDialog extends WikiDialog
Settings.getSettings( m_xContext ).addWikiCon( setting );
Settings.getSettings( m_xContext ).storeConfiguration();
}
-
+
m_bAction = true;
}
}
@@ -341,7 +341,7 @@ public class WikiEditSettingDialog extends WikiDialog
}
essl.printStackTrace();
}
- catch ( Exception ex )
+ catch ( Exception ex )
{
if ( Helper.IsConnectionAllowed() )
{
@@ -353,9 +353,9 @@ public class WikiEditSettingDialog extends WikiDialog
false );
}
ex.printStackTrace();
- }
+ }
}
-
+
public boolean callHandlerMethod( XDialog xDialog, Object EventObject, String MethodName )
{
if ( MethodName.equals( sOKMethod ) )
@@ -369,7 +369,7 @@ public class WikiEditSettingDialog extends WikiDialog
final XDialog xDialogForThread = xDialog;
final XComponentContext xContext = m_xContext;
final WikiEditSettingDialog aThis = this;
-
+
// the thread name is used to allow the error dialogs
m_bThreadFinished = false;
m_aThread = new Thread( "com.sun.star.thread.WikiEditorSendingThread" )
@@ -387,7 +387,7 @@ public class WikiEditSettingDialog extends WikiDialog
aThis.SetThrobberVisible( false );
ThreadStop( true );
-
+
if ( m_bAction )
MainThreadDialogExecutor.Close( xContext, xDialogForThread );
}
@@ -420,7 +420,7 @@ public class WikiEditSettingDialog extends WikiDialog
return false;
}
-
+
public void windowClosed( EventObject e )
{
ThreadStop( false );
diff --git a/swext/mediawiki/src/com/sun/star/wiki/WikiEditorImpl.java b/swext/mediawiki/src/com/sun/star/wiki/WikiEditorImpl.java
index 0350e07fe8b6..e670e3ff4722 100644
--- a/swext/mediawiki/src/com/sun/star/wiki/WikiEditorImpl.java
+++ b/swext/mediawiki/src/com/sun/star/wiki/WikiEditorImpl.java
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -65,23 +65,23 @@ import javax.net.ssl.SSLException;
public final class WikiEditorImpl extends WeakBase
implements com.sun.star.lang.XServiceInfo, XDispatchProvider, XDispatch, XInitialization
{
-
+
private final XComponentContext m_xContext;
private static final String m_implementationName = WikiEditorImpl.class.getName();
private static final String[] m_serviceNames = {"com.sun.star.wiki.WikiEditor" };
-
- // information needed for component registration
+
+ // information needed for component registration
public static final String[] supportedServiceNames = {"com.sun.star.frame.ProtocolHandler"};
- public static final Class implementationClass = WikiEditorImpl.class;
+ public static final Class implementationClass = WikiEditorImpl.class;
// protocol name that this protocol handler handles
public static final String protocolName = "vnd.com.sun.star.wiki:";
private Map m_statusListeners = new HashMap();
-
+
private XComponent xComp;
private String sTempUrl;
-
+
private XFrame m_xFrame;
private XModel m_xModel;
private Settings m_aSettings;
@@ -95,7 +95,7 @@ public final class WikiEditorImpl extends WeakBase
m_aSettings = Settings.getSettings( m_xContext );
};
- public static XSingleComponentFactory __getComponentFactory( String sImplementationName )
+ public static XSingleComponentFactory __getComponentFactory( String sImplementationName )
{
XSingleComponentFactory xFactory = null;
@@ -104,11 +104,11 @@ public final class WikiEditorImpl extends WeakBase
else if ( sImplementationName.equals( WikiOptionsEventHandlerImpl.m_sImplementationName ) )
xFactory = Factory.createComponentFactory( WikiOptionsEventHandlerImpl.class,
WikiOptionsEventHandlerImpl.m_pServiceNames );
-
+
return xFactory;
}
- public static boolean __writeRegistryServiceInfo( XRegistryKey xRegistryKey )
+ public static boolean __writeRegistryServiceInfo( XRegistryKey xRegistryKey )
{
boolean bResult = Factory.writeRegistryServiceInfo( m_implementationName,
m_serviceNames,
@@ -119,16 +119,16 @@ public final class WikiEditorImpl extends WeakBase
}
// com.sun.star.lang.XServiceInfo:
- public String getImplementationName()
+ public String getImplementationName()
{
return m_implementationName;
}
- public boolean supportsService( String sService )
+ public boolean supportsService( String sService )
{
int len = m_serviceNames.length;
- for( int i=0; i < len; i++ )
+ for( int i=0; i < len; i++ )
{
if ( sService.equals( m_serviceNames[i] ))
return true;
@@ -136,22 +136,22 @@ public final class WikiEditorImpl extends WeakBase
return false;
}
- public String[] getSupportedServiceNames()
+ public String[] getSupportedServiceNames()
{
return m_serviceNames;
}
-
+
private XSelectionSupplier m_sel;
private XController m_ctrl;
private boolean m_bInitialized;
- public synchronized void initialize( Object[] args ) throws com.sun.star.uno.Exception
- {
- if ( m_bInitialized )
+ public synchronized void initialize( Object[] args ) throws com.sun.star.uno.Exception
+ {
+ if ( m_bInitialized )
{
//logger.log( Level.SEVERE, "Extension instance was initialized again" );
}
- if ( args.length > 0 )
+ if ( args.length > 0 )
{
m_bInitialized = true;
m_xFrame = ( XFrame )UnoRuntime.queryInterface( XFrame.class, args[0] );
@@ -161,49 +161,49 @@ public final class WikiEditorImpl extends WeakBase
}
}
-
-
+
+
public void dispatch(
- final com.sun.star.util.URL aURL,
- com.sun.star.beans.PropertyValue[] propertyValue )
+ final com.sun.star.util.URL aURL,
+ com.sun.star.beans.PropertyValue[] propertyValue )
{
final com.sun.star.util.URL myURL = aURL;
//logger.log( Level.INFO, "received dispatch request for: "+aURL.Complete );
- if ( aURL.Protocol.compareTo( protocolName ) == 0 )
+ if ( aURL.Protocol.compareTo( protocolName ) == 0 )
{
/*
- synchronized( this )
+ synchronized( this )
{
if( m_bClosing ) return;
else m_bActive = true;
}
**/
-
- try
+
+ try
{
- if ( myURL.Path.compareTo( "send" ) == 0 )
+ if ( myURL.Path.compareTo( "send" ) == 0 )
{
sendArticle();
}
- } catch( java.lang.Throwable t )
+ } catch( java.lang.Throwable t )
{
//logger.log( Level.WARNING, "exception while handeling dispatch", t );
}
/*
- synchronized( this )
+ synchronized( this )
{
m_bActive = false;
// if we became owner while we were active
// we are responsible for closing the m_xFrame now
if ( m_bOwner && m_xFrame != null )
{
- try
+ try
{
XCloseable xclose = ( XCloseable )UnoRuntime.queryInterface(
XCloseable.class, m_xFrame );
xclose.close( true );
- } catch ( CloseVetoException cve )
+ } catch ( CloseVetoException cve )
{
logger.log( Level.SEVERE, "cannot close owned frame" );
}
@@ -212,50 +212,50 @@ public final class WikiEditorImpl extends WeakBase
}
}
*/
- }
+ }
}
-
+
public com.sun.star.frame.XDispatch queryDispatch(
- com.sun.star.util.URL aURL,
- String str,
- int param )
+ com.sun.star.util.URL aURL,
+ String str,
+ int param )
{
- if ( aURL.Protocol.equals( protocolName ))
+ if ( aURL.Protocol.equals( protocolName ))
{
// by default, we are responsible
return this;
- } else
+ } else
{
return null;
}
}
-
- public XDispatch[] queryDispatches( DispatchDescriptor[] seqDescripts )
+
+ public XDispatch[] queryDispatches( DispatchDescriptor[] seqDescripts )
{
int nCount = seqDescripts.length;
XDispatch[] lDispatcher = new XDispatch[nCount];
for( int i=0; i<nCount; ++i )
- lDispatcher[i] = queryDispatch(
+ lDispatcher[i] = queryDispatch(
seqDescripts[i].FeatureURL,
seqDescripts[i].FrameName,
seqDescripts[i].SearchFlags );
return lDispatcher;
- }
+ }
public void removeStatusListener(
- com.sun.star.frame.XStatusListener xStatusListener,
- com.sun.star.util.URL aURL )
+ com.sun.star.frame.XStatusListener xStatusListener,
+ com.sun.star.util.URL aURL )
{
}
-
+
public void addStatusListener(
- com.sun.star.frame.XStatusListener listener,
- com.sun.star.util.URL url )
+ com.sun.star.frame.XStatusListener listener,
+ com.sun.star.util.URL url )
{
String urlstring = url.Complete;
m_statusListeners.put( urlstring, listener );
@@ -263,41 +263,41 @@ public final class WikiEditorImpl extends WeakBase
callStatusListener( urlstring, listener );
}
- public void callStatusListeners()
+ public void callStatusListeners()
{
Set entries = m_statusListeners.entrySet();
Iterator iter = entries.iterator();
- while ( iter.hasNext() )
+ while ( iter.hasNext() )
{
Map.Entry entry = ( Map.Entry ) iter.next();
String uristring = ( String ) entry.getKey();
- XStatusListener listener = ( XStatusListener ) entry.getValue();
- callStatusListener( uristring, listener );
- }
+ XStatusListener listener = ( XStatusListener ) entry.getValue();
+ callStatusListener( uristring, listener );
+ }
}
-
- public void callStatusListener( String uristring, XStatusListener listener )
+
+ public void callStatusListener( String uristring, XStatusListener listener )
{
- try
+ try
{
-
+
URI uri = new URI( uristring );
// check whether any blogs are live...
setListenerState( listener, "command", false );
- } catch ( URISyntaxException ex )
+ } catch ( URISyntaxException ex )
{
ex.printStackTrace();
}
}
-
- private void setListenerState( XStatusListener listener, String urlstring, boolean state )
+
+ private void setListenerState( XStatusListener listener, String urlstring, boolean state )
{
com.sun.star.util.URL url = new com.sun.star.util.URL();
url.Complete = urlstring;
- //listener.statusChanged( new FeatureStateEvent( this, url, "", state, false, null ));
-
+ //listener.statusChanged( new FeatureStateEvent( this, url, "", state, false, null ));
+
}
public void sendArticle()
@@ -305,7 +305,7 @@ public final class WikiEditorImpl extends WeakBase
if ( m_xFrame != null )
{
WikiPropDialog aSendDialog = null;
- try
+ try
{
if ( m_xModel == null )
{
@@ -318,8 +318,8 @@ public final class WikiEditorImpl extends WeakBase
{
// The related Wiki filter must be detected from the typename
String aServiceName = Helper.GetDocServiceName( m_xContext, m_xModel );
- m_aFilterName = Helper.GetFilterName( m_xContext, "MediaWiki", aServiceName );
-
+ m_aFilterName = Helper.GetFilterName( m_xContext, "MediaWiki", aServiceName );
+
if ( m_aFilterName == null || m_aFilterName.length() == 0 )
{
Helper.ShowError( m_xContext,
@@ -351,7 +351,7 @@ public final class WikiEditorImpl extends WeakBase
}
}
}
-
+
public boolean SendArticleImpl( WikiPropDialog aSendDialog, Hashtable aWikiSetting )
{
boolean bResult = false;
@@ -364,7 +364,7 @@ public final class WikiEditorImpl extends WeakBase
{
// TODO: stop progress spinning
WikiArticle aArticle = new WikiArticle( m_xContext, aSendDialog.GetWikiTitle(), aWikiSetting, true, aSendDialog );
-
+
boolean bAllowSending = true;
if ( !aArticle.NotExist() )
{
@@ -410,7 +410,7 @@ public final class WikiEditorImpl extends WeakBase
aDocInfo.put( "Url", aArticle.GetMainURL() );
aDocInfo.put( "CompleteUrl", aArticle.GetMainURL() + aArticle.GetTitle() );
m_aSettings.addWikiDoc( aDocInfo );
- m_aSettings.storeConfiguration();
+ m_aSettings.storeConfiguration();
}
else
{
@@ -469,8 +469,8 @@ public final class WikiEditorImpl extends WeakBase
}
}
}
-
+
return bResult;
}
-
+
}
diff --git a/swext/mediawiki/src/com/sun/star/wiki/WikiOptionsEventHandlerImpl.java b/swext/mediawiki/src/com/sun/star/wiki/WikiOptionsEventHandlerImpl.java
index 8b635d85c316..98fcb0ceb8d9 100644
--- a/swext/mediawiki/src/com/sun/star/wiki/WikiOptionsEventHandlerImpl.java
+++ b/swext/mediawiki/src/com/sun/star/wiki/WikiOptionsEventHandlerImpl.java
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -63,7 +63,7 @@ public final class WikiOptionsEventHandlerImpl extends WeakBase
private XControlContainer m_xControlContainer;
Settings m_aSettings;
-
+
public WikiOptionsEventHandlerImpl( XComponentContext xContext )
{
m_xContext = xContext;
@@ -96,7 +96,7 @@ public final class WikiOptionsEventHandlerImpl extends WeakBase
catch ( Exception ex )
{
ex.printStackTrace();
- }
+ }
}
}
}
@@ -166,7 +166,7 @@ public final class WikiOptionsEventHandlerImpl extends WeakBase
XPropertySet xListProps = GetPropSet("WikiList");
if ( xListProps != null )
{
- try
+ try
{
short[] pSel = (short []) xListProps.getPropertyValue("SelectedItems");
String[] pItems = (String []) GetPropSet("WikiList").getPropertyValue("StringItemList");
@@ -200,16 +200,16 @@ public final class WikiOptionsEventHandlerImpl extends WeakBase
}
// com.sun.star.lang.XServiceInfo:
- public String getImplementationName()
+ public String getImplementationName()
{
return m_sImplementationName;
}
- public boolean supportsService( String sService )
+ public boolean supportsService( String sService )
{
int len = m_pServiceNames.length;
- for( int i=0; i < len; i++ )
+ for( int i=0; i < len; i++ )
{
if ( sService.equals( m_pServiceNames[i] ))
return true;
@@ -217,7 +217,7 @@ public final class WikiOptionsEventHandlerImpl extends WeakBase
return false;
}
- public String[] getSupportedServiceNames()
+ public String[] getSupportedServiceNames()
{
return m_pServiceNames;
}
@@ -246,12 +246,12 @@ public final class WikiOptionsEventHandlerImpl extends WeakBase
m_xControlContainer = (XControlContainer)UnoRuntime.queryInterface(
XControlContainer.class, m_xDialog );
m_aSettings = Settings.getSettings( m_xContext );
- m_aSettings.loadConfiguration(); // throw away all the noncommited changes
+ m_aSettings.loadConfiguration(); // throw away all the noncommited changes
InitStrings();
}
else if ( m_aSettings != null )
m_aSettings.loadConfiguration(); // throw away all the noncommited changes
-
+
RefreshView();
CheckButtonState();
}
@@ -283,7 +283,7 @@ public final class WikiOptionsEventHandlerImpl extends WeakBase
{
CheckButtonState();
}
-
+
return true;
}
diff --git a/swext/mediawiki/src/com/sun/star/wiki/WikiPropDialog.java b/swext/mediawiki/src/com/sun/star/wiki/WikiPropDialog.java
index 317f35a3170b..0afad6af2c2c 100644
--- a/swext/mediawiki/src/com/sun/star/wiki/WikiPropDialog.java
+++ b/swext/mediawiki/src/com/sun/star/wiki/WikiPropDialog.java
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -44,21 +44,21 @@ import com.sun.star.uno.XComponentContext;
import java.util.Hashtable;
public class WikiPropDialog extends WikiDialog{
-
+
WikiEditorImpl m_aWikiEditor;
private final String sSendMethod = "Send";
private final String sWikiListMethod = "WikiListChange";
private final String sArticleTextMethod = "ArticleTextChange";
private final String sAddWikiMethod = "AddWiki";
-
+
String[] m_pMethods = {sSendMethod, sWikiListMethod, sArticleTextMethod, sAddWikiMethod};
-
+
private String m_sWikiTitle = "";
protected String m_sWikiEngineURL = "";
protected String m_sWikiComment = "";
protected boolean m_bWikiMinorEdit = false;
-
+
/** Creates a new instance of WikiPropDialog */
public WikiPropDialog(XComponentContext xContext, String DialogURL, WikiEditorImpl aWikiEditorForThrobber )
{
@@ -87,7 +87,7 @@ public class WikiPropDialog extends WikiDialog{
e.printStackTrace();
}
}
-
+
private void InitStrings( XComponentContext xContext )
{
try
@@ -107,7 +107,7 @@ public class WikiPropDialog extends WikiDialog{
e.printStackTrace();
}
}
-
+
private void InitShowBrowser( XComponentContext xContext )
{
try
@@ -126,7 +126,7 @@ public class WikiPropDialog extends WikiDialog{
boolean bResult = super.show();
if ( bResult && Helper.GetShowInBrowserByDefault( m_xContext ) )
- Helper.ShowURLInBrowser( m_xContext, m_sWikiEngineURL + "index.php?title=" + m_sWikiTitle );
+ Helper.ShowURLInBrowser( m_xContext, m_sWikiEngineURL + "index.php?title=" + m_sWikiTitle );
return bResult;
}
@@ -149,7 +149,7 @@ public class WikiPropDialog extends WikiDialog{
public void fillWikiList()
{
String [] WikiList = m_aSettings.getWikiURLs();
-
+
try
{
XPropertySet xPS = GetPropSet("WikiList");
@@ -161,9 +161,9 @@ public class WikiPropDialog extends WikiDialog{
catch (Exception ex)
{
ex.printStackTrace();
- }
+ }
}
-
+
public void fillDocList()
{
XPropertySet xPS = GetPropSet("ArticleText");
@@ -177,8 +177,8 @@ public class WikiPropDialog extends WikiDialog{
ex.printStackTrace();
}
}
-
-
+
+
public String GetWikiTitle()
{
return m_sWikiTitle;
@@ -195,9 +195,9 @@ public class WikiPropDialog extends WikiDialog{
catch (Exception ex)
{
ex.printStackTrace();
- }
+ }
}
-
+
public void switchSendButtonIfNecessary()
{
@@ -256,7 +256,7 @@ public class WikiPropDialog extends WikiDialog{
ex.printStackTrace();
}
}
-
+
public boolean callHandlerMethod( XDialog xDialog, Object EventObject, String MethodName )
{
if ( MethodName.equals( sSendMethod ) )
@@ -279,9 +279,9 @@ public class WikiPropDialog extends WikiDialog{
short minorState = ((Short) aMinorCheckProps.getPropertyValue("State")).shortValue();
if (minorState != 0)
m_bWikiMinorEdit = true;
- else
+ else
m_bWikiMinorEdit = false;
-
+
short nBrowserState = ((Short) aBrowserCheckProps.getPropertyValue("State")).shortValue();
Helper.SetShowInBrowserByDefault( m_xContext, nBrowserState != 0 );
@@ -300,7 +300,7 @@ public class WikiPropDialog extends WikiDialog{
// start spinning
SetThrobberVisible( true );
SetThrobberActive( true );
-
+
// the following method might show a dialog, should be used in main thread
final Hashtable aWikiSettings = m_aSettings.getSettingByUrl( m_sWikiEngineURL );
if ( Helper.AllowThreadUsage( m_xContext ) )
@@ -352,7 +352,7 @@ public class WikiPropDialog extends WikiDialog{
xDialogToClose.endExecute();
}
}
-
+
return true;
}
else if ( MethodName.equals( sWikiListMethod ) )
diff --git a/swext/mediawiki/src/com/sun/star/wiki/WikiProtocolSocketFactory.java b/swext/mediawiki/src/com/sun/star/wiki/WikiProtocolSocketFactory.java
index 653eaca8466a..bba7d08cc08e 100644
--- a/swext/mediawiki/src/com/sun/star/wiki/WikiProtocolSocketFactory.java
+++ b/swext/mediawiki/src/com/sun/star/wiki/WikiProtocolSocketFactory.java
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -61,7 +61,7 @@ class WikiProtocolSocketFactory implements SecureProtocolSocketFactory
{
new X509TrustManager() {
private X509TrustManager m_aOrgTrustManager;
-
+
private X509TrustManager GetOrgTrustManager()
{
if ( m_aOrgTrustManager == null )
@@ -79,20 +79,20 @@ class WikiProtocolSocketFactory implements SecureProtocolSocketFactory
throw new RuntimeException( "No access to the default trust manager!" );
}
}
-
+
return m_aOrgTrustManager;
}
-
+
public X509Certificate[] getAcceptedIssuers()
{
return GetOrgTrustManager().getAcceptedIssuers();
}
-
+
public void checkClientTrusted(X509Certificate[] certs, String authType) throws CertificateException
{
GetOrgTrustManager().checkClientTrusted( certs, authType );
}
-
+
public void checkServerTrusted(X509Certificate[] certs, String authType) throws CertificateException
{
if ( certs == null || certs.length == 0 )
diff --git a/swext/mediawiki/src/registry/data/org/openoffice/Office/Addons.xcu b/swext/mediawiki/src/registry/data/org/openoffice/Office/Addons.xcu
index b8e96e1f1139..49f57cd1fa60 100644
--- a/swext/mediawiki/src/registry/data/org/openoffice/Office/Addons.xcu
+++ b/swext/mediawiki/src/registry/data/org/openoffice/Office/Addons.xcu
@@ -2,7 +2,7 @@
<!--***********************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
diff --git a/swext/mediawiki/src/registry/data/org/openoffice/Office/Custom/WikiExtension.xcu b/swext/mediawiki/src/registry/data/org/openoffice/Office/Custom/WikiExtension.xcu
index 8dbde907af37..bf89395cd064 100644
--- a/swext/mediawiki/src/registry/data/org/openoffice/Office/Custom/WikiExtension.xcu
+++ b/swext/mediawiki/src/registry/data/org/openoffice/Office/Custom/WikiExtension.xcu
@@ -2,7 +2,7 @@
<!--***********************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -38,14 +38,14 @@
</prop>
</node>
</node>
- </node>
- </node>
+ </node>
+ </node>
<node oor:name="ConnectionList">
- </node>
+ </node>
<node oor:name="RecentDocs">
- </node>
+ </node>
<node oor:name="Settings">
<prop oor:name="PreselectShowBrowser">
diff --git a/swext/mediawiki/src/registry/data/org/openoffice/Office/OptionsDialog.xcu b/swext/mediawiki/src/registry/data/org/openoffice/Office/OptionsDialog.xcu
index f6498c5faef3..a270c40655f1 100644
--- a/swext/mediawiki/src/registry/data/org/openoffice/Office/OptionsDialog.xcu
+++ b/swext/mediawiki/src/registry/data/org/openoffice/Office/OptionsDialog.xcu
@@ -2,7 +2,7 @@
<!--***********************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
diff --git a/swext/mediawiki/src/registry/data/org/openoffice/Office/Paths.xcu b/swext/mediawiki/src/registry/data/org/openoffice/Office/Paths.xcu
index e39bbc75471c..09c72ec9868b 100644
--- a/swext/mediawiki/src/registry/data/org/openoffice/Office/Paths.xcu
+++ b/swext/mediawiki/src/registry/data/org/openoffice/Office/Paths.xcu
@@ -2,7 +2,7 @@
<!--***********************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
diff --git a/swext/mediawiki/src/registry/data/org/openoffice/Office/ProtocolHandler.xcu b/swext/mediawiki/src/registry/data/org/openoffice/Office/ProtocolHandler.xcu
index 501c0a42548c..bf523ce2d929 100644
--- a/swext/mediawiki/src/registry/data/org/openoffice/Office/ProtocolHandler.xcu
+++ b/swext/mediawiki/src/registry/data/org/openoffice/Office/ProtocolHandler.xcu
@@ -2,7 +2,7 @@
<!--***********************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
diff --git a/swext/mediawiki/src/registry/data/org/openoffice/TypeDetection/Filter.xcu b/swext/mediawiki/src/registry/data/org/openoffice/TypeDetection/Filter.xcu
index d0ddad5b2a7c..75524ae28ceb 100644
--- a/swext/mediawiki/src/registry/data/org/openoffice/TypeDetection/Filter.xcu
+++ b/swext/mediawiki/src/registry/data/org/openoffice/TypeDetection/Filter.xcu
@@ -2,7 +2,7 @@
<!--***********************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
diff --git a/swext/mediawiki/src/registry/data/org/openoffice/TypeDetection/Types.xcu b/swext/mediawiki/src/registry/data/org/openoffice/TypeDetection/Types.xcu
index 64031b844aaf..eca6e68d8862 100644
--- a/swext/mediawiki/src/registry/data/org/openoffice/TypeDetection/Types.xcu
+++ b/swext/mediawiki/src/registry/data/org/openoffice/TypeDetection/Types.xcu
@@ -2,7 +2,7 @@
<!--***********************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
diff --git a/swext/mediawiki/src/uno-extension-manifest.xml b/swext/mediawiki/src/uno-extension-manifest.xml
index f3d9a0e2399b..b884b2ee433c 100644
--- a/swext/mediawiki/src/uno-extension-manifest.xml
+++ b/swext/mediawiki/src/uno-extension-manifest.xml
@@ -1,24 +1,24 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--***********************************************************************
-
+
DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-
+
Copyright 2000, 2010 Oracle and/or its affiliates.
-
+
OpenOffice.org - a multi-platform office productivity suite
-
+
This file is part of OpenOffice.org.
-
+
OpenOffice.org is free software: you can redistribute it and/or modify
it under the terms of the GNU Lesser General Public License version 3
only, as published by the Free Software Foundation.
-
+
OpenOffice.org is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU Lesser General Public License version 3 for more details
(a copy is included in the LICENSE file that accompanied this code).
-
+
You should have received a copy of the GNU Lesser General Public License
version 3 along with OpenOffice.org. If not, see
<http://www.openoffice.org/license.html>
@@ -28,26 +28,26 @@
<manifest:manifest xmlns:manifest="http://openoffice.org/2001/manifest">
<manifest:file-entry manifest:media-type="application/vnd.sun.star.uno-component;type=Java"
manifest:full-path="mediawiki.jar"/>
- <manifest:file-entry manifest:media-type="application/vnd.sun.star.configuration-data"
- manifest:full-path="Addons.xcu"/>
- <manifest:file-entry manifest:media-type="application/vnd.sun.star.configuration-data"
+ <manifest:file-entry manifest:media-type="application/vnd.sun.star.configuration-data"
+ manifest:full-path="Addons.xcu"/>
+ <manifest:file-entry manifest:media-type="application/vnd.sun.star.configuration-data"
manifest:full-path="ProtocolHandler.xcu"/>
- <manifest:file-entry manifest:full-path="WikiEditor/"
+ <manifest:file-entry manifest:full-path="WikiEditor/"
manifest:media-type="application/vnd.sun.star.basic-library"/>
- <manifest:file-entry manifest:media-type="application/vnd.sun.star.configuration-schema"
+ <manifest:file-entry manifest:media-type="application/vnd.sun.star.configuration-schema"
manifest:full-path="WikiExtension.xcs"/>
- <manifest:file-entry manifest:media-type="application/vnd.sun.star.configuration-data"
- manifest:full-path="WikiExtension.xcu"/>
- <manifest:file-entry manifest:media-type="application/vnd.sun.star.configuration-data"
- manifest:full-path="OptionsDialog.xcu"/>
- <manifest:file-entry manifest:media-type="application/vnd.sun.star.configuration-data"
- manifest:full-path="Filter.xcu"/>
- <manifest:file-entry manifest:media-type="application/vnd.sun.star.configuration-data"
- manifest:full-path="Types.xcu"/>
- <manifest:file-entry manifest:media-type="application/vnd.sun.star.configuration-data"
- manifest:full-path="Paths.xcu"/>
- <manifest:file-entry manifest:media-type="application/vnd.sun.star.help"
- manifest:full-path="help"/>
+ <manifest:file-entry manifest:media-type="application/vnd.sun.star.configuration-data"
+ manifest:full-path="WikiExtension.xcu"/>
+ <manifest:file-entry manifest:media-type="application/vnd.sun.star.configuration-data"
+ manifest:full-path="OptionsDialog.xcu"/>
+ <manifest:file-entry manifest:media-type="application/vnd.sun.star.configuration-data"
+ manifest:full-path="Filter.xcu"/>
+ <manifest:file-entry manifest:media-type="application/vnd.sun.star.configuration-data"
+ manifest:full-path="Types.xcu"/>
+ <manifest:file-entry manifest:media-type="application/vnd.sun.star.configuration-data"
+ manifest:full-path="Paths.xcu"/>
+ <manifest:file-entry manifest:media-type="application/vnd.sun.star.help"
+ manifest:full-path="help"/>
<manifest:file-entry manifest:media-type="application/vnd.sun.star.package-bundle-description"
manifest:full-path="help/component.txt"/>
</manifest:manifest>