java: remove various unused variables
Change-Id: Id9f30938f594cb6fe73bf40adfffa65ec1b42cd1
This commit is contained in:
@@ -270,7 +270,6 @@ public class LocalOfficeWindow
|
||||
void cancel()
|
||||
throws java.lang.InterruptedException
|
||||
{
|
||||
Thread aThread = aWatchedThread;
|
||||
aWatchedThread = null;
|
||||
stop();
|
||||
|
||||
|
||||
@@ -1453,11 +1453,10 @@ xLayoutManager.showElement("private:resource/menubar/menubar");
|
||||
dbgPrint( "EventListener(" + aTag + ").running() #" + ++n );
|
||||
|
||||
// still alive?
|
||||
com.sun.star.lang.XMultiComponentFactory xServiceManager = null;
|
||||
try
|
||||
{
|
||||
// an arbitrary (but cheap) call into OOo
|
||||
xServiceManager = iConnection.getComponentContext().getServiceManager();
|
||||
iConnection.getComponentContext().getServiceManager();
|
||||
|
||||
// call successfully performed, restart watch for next loop
|
||||
try
|
||||
|
||||
@@ -481,7 +481,6 @@ public class OOoBeanTest
|
||||
|
||||
for (; i < 1; i++)
|
||||
{
|
||||
EventQueue q = Toolkit.getDefaultToolkit().getSystemEventQueue();
|
||||
EventQueue.invokeAndWait( new Runnable() {
|
||||
public void run() {
|
||||
try {
|
||||
|
||||
@@ -73,7 +73,6 @@ public class OOoViewer extends Applet {
|
||||
// Class arPropValClass = m_loader.loadClass("[Lcom.sun.star.beans.PropertyValue;");
|
||||
Object arProp = Array.newInstance(
|
||||
m_loader.loadClass("com.sun.star.beans.PropertyValue"), 1);
|
||||
Class<? extends Object> clazz = arProp.getClass();
|
||||
|
||||
Method methLoad = beanClass.getMethod(
|
||||
"loadFromURL", new Class[] {
|
||||
@@ -175,7 +174,6 @@ final class CustomURLClassLoader extends URLClassLoader {
|
||||
return result;
|
||||
}
|
||||
|
||||
URI uri = null;
|
||||
for (URL u : resourcePaths) {
|
||||
if (u.getProtocol().startsWith("file")){
|
||||
try {
|
||||
|
||||
@@ -115,7 +115,6 @@ public class testclient
|
||||
if( null != xConnection )
|
||||
{
|
||||
System.out.println( "after connect" );
|
||||
String rootOid = "OfficeDaemon.Factory";
|
||||
com.sun.star.uno.IBridge bridge = UnoRuntime.getBridgeByName(
|
||||
"java",
|
||||
null,
|
||||
|
||||
@@ -523,7 +523,6 @@ public class TypeDetection extends ComplexTestCase {
|
||||
|
||||
PropertyValue[] out = inOut[0];
|
||||
|
||||
boolean bStream = false;
|
||||
log.println("out-Parameter");
|
||||
boolean bReadOnly = false;
|
||||
for (int i=0; i < out.length; i++){
|
||||
|
||||
@@ -48,7 +48,6 @@ public class _XUIConfiguration {
|
||||
public void before() {
|
||||
xListener = (XUIConfigurationListenerImpl)tEnv.get(
|
||||
"XUIConfiguration.XUIConfigurationListenerImpl");
|
||||
XUIConfigurationListener l;
|
||||
}
|
||||
|
||||
public boolean _addConfigurationListener() {
|
||||
|
||||
@@ -73,7 +73,6 @@ public class InputStreamToXInputStreamAdapter implements XInputStream {
|
||||
public int readBytes(byte[][] b, int len) throws
|
||||
com.sun.star.io.IOException
|
||||
{
|
||||
int count = 0;
|
||||
try {
|
||||
long bytesRead;
|
||||
if (len >iIn.available()) {
|
||||
@@ -100,7 +99,6 @@ public class InputStreamToXInputStreamAdapter implements XInputStream {
|
||||
public int readSomeBytes(byte[][] b, int len) throws
|
||||
com.sun.star.io.IOException
|
||||
{
|
||||
int count = 0;
|
||||
try {
|
||||
long bytesRead;
|
||||
if (len >iIn.available()) {
|
||||
|
||||
@@ -108,7 +108,6 @@ public class XInputStreamToInputStreamAdapter extends InputStream {
|
||||
}
|
||||
|
||||
public int read(byte[] b, int off, int len) throws IOException {
|
||||
int count = 0;
|
||||
byte [][] tmp = new byte [1][b.length];
|
||||
try {
|
||||
long bytesRead;
|
||||
|
||||
@@ -106,7 +106,6 @@ public class SharedLibraryLoader_Test {
|
||||
static public boolean test_loadNativeSimpleRegistry()
|
||||
throws java.lang.Exception
|
||||
{
|
||||
boolean result = false;
|
||||
System.out.println("*******************************************************************");
|
||||
System.out.println("Test: <<< load native SimpleRegistry >>>");
|
||||
if ( sharedLibraryLoader == null )
|
||||
|
||||
@@ -271,7 +271,6 @@ public class MultiTypeInterfaceContainer_Test
|
||||
boolean r[]= new boolean[50];
|
||||
int i= 0;
|
||||
|
||||
int count= 0;
|
||||
cont.clear();
|
||||
Type[] types= cont.getContainedTypes();
|
||||
r[i++]= types.length == 0;
|
||||
|
||||
@@ -61,7 +61,7 @@ public class UnoUrlTest {
|
||||
|
||||
public void testStart2() {
|
||||
try {
|
||||
UnoUrl url = UnoUrl.parseUnoUrl("uno1:x;y;z");
|
||||
UnoUrl.parseUnoUrl("uno1:x;y;z");
|
||||
fail("Should throw an exception");
|
||||
} catch (com.sun.star.lang.IllegalArgumentException e) {
|
||||
}
|
||||
@@ -69,7 +69,7 @@ public class UnoUrlTest {
|
||||
|
||||
public void testStart3() {
|
||||
try {
|
||||
UnoUrl url = UnoUrl.parseUnoUrl("un:x;y;z");
|
||||
UnoUrl.parseUnoUrl("un:x;y;z");
|
||||
fail("Should throw an exception");
|
||||
} catch (com.sun.star.lang.IllegalArgumentException e) {
|
||||
}
|
||||
@@ -87,7 +87,7 @@ public class UnoUrlTest {
|
||||
|
||||
public void testParam1() {
|
||||
try {
|
||||
UnoUrl url = UnoUrl.parseUnoUrl("uno:");
|
||||
UnoUrl.parseUnoUrl("uno:");
|
||||
fail("Should throw an exception");
|
||||
} catch (com.sun.star.lang.IllegalArgumentException e) {
|
||||
}
|
||||
@@ -95,7 +95,7 @@ public class UnoUrlTest {
|
||||
|
||||
public void testParam2() {
|
||||
try {
|
||||
UnoUrl url = UnoUrl.parseUnoUrl("uno:a;");
|
||||
UnoUrl.parseUnoUrl("uno:a;");
|
||||
fail("Should throw an exception");
|
||||
} catch (com.sun.star.lang.IllegalArgumentException e) {
|
||||
}
|
||||
@@ -103,7 +103,7 @@ public class UnoUrlTest {
|
||||
|
||||
public void testPartName1() {
|
||||
try {
|
||||
UnoUrl url = UnoUrl.parseUnoUrl("uno:abc!abc;b;c");
|
||||
UnoUrl.parseUnoUrl("uno:abc!abc;b;c");
|
||||
fail("Should throw an exception");
|
||||
} catch (com.sun.star.lang.IllegalArgumentException e) {
|
||||
}
|
||||
@@ -111,7 +111,7 @@ public class UnoUrlTest {
|
||||
|
||||
public void testOID1() {
|
||||
try {
|
||||
UnoUrl url = UnoUrl.parseUnoUrl("uno:x;y;ABC<ABC");
|
||||
UnoUrl.parseUnoUrl("uno:x;y;ABC<ABC");
|
||||
fail("Should throw an exception");
|
||||
} catch (com.sun.star.lang.IllegalArgumentException e) {
|
||||
}
|
||||
@@ -143,7 +143,7 @@ public class UnoUrlTest {
|
||||
|
||||
public void testParams1() {
|
||||
try {
|
||||
UnoUrl url = UnoUrl.parseUnoUrl("uno:x,abc!abc=val;y;ABC");
|
||||
UnoUrl.parseUnoUrl("uno:x,abc!abc=val;y;ABC");
|
||||
fail("Should throw an exception");
|
||||
} catch (com.sun.star.lang.IllegalArgumentException e) {
|
||||
}
|
||||
@@ -151,7 +151,7 @@ public class UnoUrlTest {
|
||||
|
||||
public void testParams2() {
|
||||
try {
|
||||
UnoUrl url = UnoUrl.parseUnoUrl("uno:x,abc=val<val;y;ABC");
|
||||
UnoUrl.parseUnoUrl("uno:x,abc=val<val;y;ABC");
|
||||
fail("Should throw an exception");
|
||||
} catch (com.sun.star.lang.IllegalArgumentException e) {
|
||||
}
|
||||
@@ -199,7 +199,7 @@ public class UnoUrlTest {
|
||||
|
||||
public void testUTF1() {
|
||||
try {
|
||||
UnoUrl url = UnoUrl.parseUnoUrl("uno:x,abc=val%4t;y;ABC");
|
||||
UnoUrl.parseUnoUrl("uno:x,abc=val%4t;y;ABC");
|
||||
fail("Should throw an exception");
|
||||
} catch (com.sun.star.lang.IllegalArgumentException e) {
|
||||
}
|
||||
|
||||
@@ -231,8 +231,6 @@ public final class Marshaling_Test {
|
||||
if((op1.getClass().getComponentType() == op2.getClass().getComponentType())
|
||||
&& (Array.getLength(op1) == Array.getLength(op2)))
|
||||
{
|
||||
Class zClass = op1.getClass().getComponentType();
|
||||
|
||||
for(int i = 0; i < Array.getLength(op1); ++ i)
|
||||
result = result & compareObjects(Array.get(op1, i), Array.get(op2, i));
|
||||
}
|
||||
|
||||
@@ -176,7 +176,7 @@ public class MessageBox {
|
||||
XMessageBox xMessageBox = xMessageBoxFactory.createMessageBox(_xParentWindowPeer, MessageBoxType.ERRORBOX, com.sun.star.awt.MessageBoxButtons.BUTTONS_OK, _sTitle, _sMessage);
|
||||
xComponent = UnoRuntime.queryInterface(XComponent.class, xMessageBox);
|
||||
if (xMessageBox != null){
|
||||
short nResult = xMessageBox.execute();
|
||||
xMessageBox.execute();
|
||||
}
|
||||
} catch (com.sun.star.uno.Exception ex) {
|
||||
ex.printStackTrace(System.err);
|
||||
@@ -216,23 +216,17 @@ public class MessageBox {
|
||||
public static int getRedColorShare(int _nColor) {
|
||||
int nRed = _nColor/65536;
|
||||
int nRedModulo = _nColor % 65536;
|
||||
int nGreen = nRedModulo / 256;
|
||||
int nGreenModulo = (nRedModulo % 256);
|
||||
int nBlue = nGreenModulo;
|
||||
return nRed;
|
||||
}
|
||||
|
||||
public static int getGreenColorShare(int _nColor) {
|
||||
int nRed = _nColor/65536;
|
||||
int nRedModulo = _nColor % 65536;
|
||||
int nGreen = nRedModulo / 256;
|
||||
return nGreen;
|
||||
}
|
||||
|
||||
public static int getBlueColorShare(int _nColor) {
|
||||
int nRed = _nColor/65536;
|
||||
int nRedModulo = _nColor % 65536;
|
||||
int nGreen = nRedModulo / 256;
|
||||
int nGreenModulo = (nRedModulo % 256);
|
||||
int nBlue = nGreenModulo;
|
||||
return nBlue;
|
||||
|
||||
@@ -859,7 +859,6 @@ public class UnoDialogSample implements XTextListener, XSpinListener, XActionLis
|
||||
public static String createUniqueName(XNameAccess _xElementContainer, String _sElementName) {
|
||||
boolean bElementexists = true;
|
||||
int i = 1;
|
||||
String sIncSuffix = "";
|
||||
String BaseName = _sElementName;
|
||||
while (bElementexists) {
|
||||
bElementexists = _xElementContainer.hasByName(_sElementName);
|
||||
@@ -1473,9 +1472,6 @@ public class UnoDialogSample implements XTextListener, XSpinListener, XActionLis
|
||||
|
||||
|
||||
public void keyReleased(KeyEvent keyEvent) {
|
||||
int i = keyEvent.KeyChar;
|
||||
int n = keyEvent.KeyCode;
|
||||
int m = keyEvent.KeyFunc;
|
||||
}
|
||||
|
||||
public void keyPressed(KeyEvent keyEvent) {
|
||||
|
||||
@@ -175,14 +175,12 @@ public UnoMenu(XComponentContext _xContext, XMultiComponentFactory _xMCF) {
|
||||
}
|
||||
|
||||
public void itemHighlighted(MenuEvent menuEvent) {
|
||||
int i = 0;
|
||||
}
|
||||
|
||||
public void itemDeactivated(MenuEvent menuEvent) {
|
||||
int i = 0; }
|
||||
}
|
||||
|
||||
public void itemActivated(MenuEvent menuEvent) {
|
||||
int i = 0;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -516,7 +516,7 @@ public class TestHelper {
|
||||
pWrongPass[0] += pPass[0];
|
||||
try
|
||||
{
|
||||
Object oSubStream = xParentStorage.openEncryptedStreamElement( sName, ElementModes.READ, new String(pWrongPass) );
|
||||
xParentStorage.openEncryptedStreamElement( sName, ElementModes.READ, new String(pWrongPass) );
|
||||
Error( "Encrypted stream '" + sName + "' was opened with wrong password!" );
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -1055,7 +1055,6 @@ public class ViewForwarder {
|
||||
|
||||
XWindow xWindow = AccessibilityTools.getCurrentWindow(mXMSF, aModel);
|
||||
XAccessible xRoot = AccessibilityTools.getAccessibleObject(xWindow);
|
||||
XAccessible parent = null;
|
||||
|
||||
try {
|
||||
XAccessibleContext con = AccessibilityTools.getAccessibleObjectForRole
|
||||
|
||||
@@ -83,7 +83,6 @@ public class _XNamed {
|
||||
boolean result = true;
|
||||
boolean loc_result = true;
|
||||
String name = null;
|
||||
String NewName = null;
|
||||
|
||||
loc_result = ((name = oObj.getName()) != null);
|
||||
System.out.println("getting the name \"" + name + "\"");
|
||||
|
||||
@@ -365,7 +365,6 @@ public class CalcRTL /* extends ComplexTestCase */
|
||||
newValue = getRealValue(newValue);
|
||||
resValue = getRealValue(resValue);
|
||||
|
||||
short attr = prop.Attributes;
|
||||
boolean readOnly = (prop.Attributes & PropertyAttribute.READONLY) != 0;
|
||||
boolean maybeVoid = (prop.Attributes & PropertyAttribute.MAYBEVOID) != 0;
|
||||
|
||||
|
||||
@@ -73,7 +73,6 @@ public class DeployedUnoPackagesDB {
|
||||
ArrayList<String> packageUrls = new ArrayList<String>(4);
|
||||
Element main = document.getDocumentElement();
|
||||
Element root = null;
|
||||
Element item;
|
||||
int len = 0;
|
||||
NodeList langNodes = null;
|
||||
|
||||
|
||||
@@ -341,10 +341,8 @@ public class ScriptMetaData extends ScriptEntry implements Cloneable {
|
||||
}
|
||||
protected boolean writeSourceFile()
|
||||
{
|
||||
String parcelLocation = parent.getPathToParcel();
|
||||
String sourceFilePath = parent.getPathToParcel() + "/" + getLanguageName();
|
||||
boolean result = false;
|
||||
OutputStream os = null;
|
||||
try
|
||||
{
|
||||
XSimpleFileAccess2 xSFA2 = UnoRuntime.queryInterface( XSimpleFileAccess2.class,
|
||||
|
||||
@@ -183,7 +183,6 @@ public class UnoPkgContainer extends ParcelContainer
|
||||
{
|
||||
ScriptMetaData scriptData = null;
|
||||
|
||||
String language = psu.language;
|
||||
String functionName = psu.function;
|
||||
String parcelName = psu.parcel;
|
||||
String location = psu.location;
|
||||
|
||||
@@ -192,7 +192,6 @@ public class UCBStreamHandler extends URLStreamHandler {
|
||||
{
|
||||
ZipInputStream zis = null;
|
||||
ZipEntry entry = null;
|
||||
boolean found = false;
|
||||
|
||||
zis = new ZipInputStream(is);
|
||||
|
||||
|
||||
@@ -184,8 +184,7 @@ public class XStorageHelper implements XEventListener
|
||||
if ( model != null )
|
||||
{
|
||||
LogUtils.DEBUG(" Disposing doc " + model.getURL() );
|
||||
Object result = modelMap.remove( model );
|
||||
result = null;
|
||||
modelMap.remove( model );
|
||||
}
|
||||
}
|
||||
public XStorage getStorage()
|
||||
|
||||
@@ -549,7 +549,6 @@ public abstract class ScriptProvider
|
||||
public String[] getElementNames()
|
||||
{
|
||||
// TODO needs implementing?
|
||||
String[] result = new String[0];
|
||||
throw new com.sun.star.uno.RuntimeException(
|
||||
"getElementNames not implemented" );
|
||||
|
||||
|
||||
@@ -25,7 +25,6 @@ public class FileUpdater {
|
||||
|
||||
public static boolean updateProtocolHandler( String installPath, JLabel statusLabel ) {
|
||||
File in_file = null;
|
||||
FileInputStream in = null;
|
||||
File out_file = null;
|
||||
FileWriter out = null;
|
||||
int count = 0;
|
||||
@@ -95,7 +94,6 @@ public class FileUpdater {
|
||||
public static boolean updateScriptXLC( String installPath, JLabel statusLabel ) {
|
||||
|
||||
File in_file = null;
|
||||
FileInputStream in = null;
|
||||
File out_file = null;
|
||||
FileWriter out = null;
|
||||
int count = 0;
|
||||
@@ -167,7 +165,6 @@ public class FileUpdater {
|
||||
|
||||
public static boolean updateDialogXLC( String installPath, JLabel statusLabel ) {
|
||||
File in_file = null;
|
||||
FileInputStream in = null;
|
||||
File out_file = null;
|
||||
FileWriter out = null;
|
||||
int count = 0;
|
||||
@@ -175,7 +172,6 @@ public class FileUpdater {
|
||||
//System.out.println( "updateDialogXLC" );
|
||||
try {
|
||||
in_file = new File( installPath+File.separator+"user"+File.separator+"basic"+File.separator+"dialog.xlc" );
|
||||
String xmlLine = "";
|
||||
|
||||
String[] xmlArray = new String[50];
|
||||
try {
|
||||
|
||||
@@ -76,9 +76,7 @@ public class IdeFinal extends javax.swing.JPanel implements ActionListener, Inst
|
||||
ArrayList<?> locations = InstallWizard.getLocations();
|
||||
//System.out.println("here "+locations.size());
|
||||
// Returned 1
|
||||
String progpath=null;
|
||||
String path=null;
|
||||
String classespath=null;
|
||||
for (int i =0;i<locations.size();i++){
|
||||
path= (String)locations.get(i);
|
||||
|
||||
|
||||
@@ -181,7 +181,6 @@ public class InstUtil {
|
||||
return null;
|
||||
}*/
|
||||
|
||||
File theFile = null;
|
||||
Properties results = new Properties();
|
||||
|
||||
StringBuffer str = new StringBuffer();
|
||||
@@ -197,7 +196,6 @@ public class InstUtil {
|
||||
if( jeditLogFile.exists() ) {
|
||||
String[] jeditDetails = getJeditInstallation( jeditLogFile );
|
||||
System.out.println( "getJeditLocation ) " + jeditDetails[0] );
|
||||
File f = new File(jeditDetails[0]);
|
||||
results.put("jEdit "+jeditDetails[1], jeditDetails[0]);
|
||||
System.out.println( "jeditDetails[0] is " + jeditDetails[0]);
|
||||
}
|
||||
@@ -439,7 +437,7 @@ public class InstUtil {
|
||||
System.err.println("Problem with sversion.ini");
|
||||
}
|
||||
try {
|
||||
Properties vers = InstUtil.getOfficeVersions(f);
|
||||
InstUtil.getOfficeVersions(f);
|
||||
} catch (IOException e) {
|
||||
e.printStackTrace();
|
||||
System.err.println(e);
|
||||
|
||||
@@ -73,7 +73,6 @@ public class Register{
|
||||
String[] packages = {"ooscriptframe.zip", "bshruntime.zip", "jsruntime.zip"};
|
||||
|
||||
try {
|
||||
String s=null;
|
||||
boolean goodResult = false;
|
||||
String env[] = new String[1];
|
||||
ExecCmd command = new ExecCmd();
|
||||
|
||||
@@ -251,7 +251,6 @@ class MyTableModel extends AbstractTableModel {
|
||||
data = new ArrayList<ArrayList<Object>>();
|
||||
boolean isWindows =
|
||||
(System.getProperty("os.name").indexOf("Windows") != -1);
|
||||
int len = validVersions.length;
|
||||
for (Enumeration e = properties.propertyNames(); e.hasMoreElements() ;) {
|
||||
String key = (String)e.nextElement();
|
||||
String path = null;
|
||||
|
||||
@@ -20,13 +20,11 @@ package installer;
|
||||
|
||||
import java.io.*;
|
||||
import java.util.*;
|
||||
import java.net.URL;
|
||||
import javax.swing.*;
|
||||
|
||||
public class XmlUpdater extends Thread {
|
||||
|
||||
private String classesPath = null;
|
||||
private String jarfilename;
|
||||
private String installPath;
|
||||
private boolean netInstall;
|
||||
private boolean bindingsInstall;
|
||||
@@ -154,19 +152,14 @@ public class XmlUpdater extends Thread {
|
||||
|
||||
public void run() {
|
||||
|
||||
InputStream istream;
|
||||
//InputSource isource;
|
||||
//DocumentBuilderFactory builderFactory;
|
||||
//DocumentBuilder builder = null;
|
||||
URL url;
|
||||
String fileName = null;
|
||||
|
||||
internalThread = Thread.currentThread();
|
||||
|
||||
//System.out.println("\n\n\n\nFileName: "+installPath);
|
||||
classesPath= installPath.concat(File.separator+"program"+File.separator+"classes"+File.separator);
|
||||
String opSys =System.getProperty("os.name");
|
||||
//System.out.println("\n System "+opSys);
|
||||
|
||||
String progpath=installPath;
|
||||
progpath= progpath.concat(File.separator+"program"+File.separator);
|
||||
|
||||
@@ -40,7 +40,6 @@ public class TestApplet extends java.applet.Applet {
|
||||
|
||||
// Security tests.
|
||||
File f= new File("d:\\temp\\javasecurity.txt");
|
||||
SecurityManager mgr= System.getSecurityManager();
|
||||
try {
|
||||
f.createNewFile();
|
||||
|
||||
|
||||
@@ -64,7 +64,6 @@ public class TestComponent implements XServiceInfo, XTypeProvider
|
||||
public String getImplementationName( )
|
||||
{
|
||||
String a= "the functions are for debugging";
|
||||
int abc= 34;
|
||||
String prop= System.getProperty("ftp.proxyHost");
|
||||
prop= System.getProperty("ftp.proxyPort");
|
||||
prop= System.getProperty("http.proxyHost");
|
||||
|
||||
@@ -653,7 +653,7 @@ public class _XAccessibleText {
|
||||
|
||||
try {
|
||||
System.out.println("getTextRange(-1, chCount - 1): ");
|
||||
String txtRange = oObj.getTextRange(-1, chCount - 1);
|
||||
oObj.getTextRange(-1, chCount - 1);
|
||||
System.out.println("Exception was expected");
|
||||
res &= false;
|
||||
} catch(com.sun.star.lang.IndexOutOfBoundsException e) {
|
||||
@@ -663,7 +663,7 @@ public class _XAccessibleText {
|
||||
|
||||
try {
|
||||
System.out.println("getTextRange(0, chCount + 1): ");
|
||||
String txtRange = oObj.getTextRange(0, chCount + 1);
|
||||
oObj.getTextRange(0, chCount + 1);
|
||||
System.out.println("Exception was expected");
|
||||
res &= false;
|
||||
} catch(com.sun.star.lang.IndexOutOfBoundsException e) {
|
||||
@@ -673,7 +673,7 @@ public class _XAccessibleText {
|
||||
|
||||
try {
|
||||
System.out.println("getTextRange(chCount+1, -1): ");
|
||||
String txtRange = oObj.getTextRange(chCount+1, -1);
|
||||
oObj.getTextRange(chCount+1, -1);
|
||||
System.out.println("Exception was expected");
|
||||
res &= false;
|
||||
} catch(com.sun.star.lang.IndexOutOfBoundsException e) {
|
||||
@@ -701,8 +701,7 @@ public class _XAccessibleText {
|
||||
|
||||
try {
|
||||
System.out.println("getTextAtIndex(-1, AccessibleTextType.PARAGRAPH):");
|
||||
TextSegment txt =
|
||||
oObj.getTextAtIndex(-1, AccessibleTextType.PARAGRAPH);
|
||||
oObj.getTextAtIndex(-1, AccessibleTextType.PARAGRAPH);
|
||||
System.out.println("Exception was expected");
|
||||
res &= false;
|
||||
} catch(com.sun.star.lang.IndexOutOfBoundsException e) {
|
||||
@@ -716,8 +715,7 @@ public class _XAccessibleText {
|
||||
try {
|
||||
System.out.println("getTextAtIndex(chCount+1," +
|
||||
" AccessibleTextType.PARAGRAPH):");
|
||||
TextSegment txt = oObj.getTextAtIndex(chCount + 1,
|
||||
AccessibleTextType.PARAGRAPH);
|
||||
oObj.getTextAtIndex(chCount + 1, AccessibleTextType.PARAGRAPH);
|
||||
System.out.println("Exception was expected");
|
||||
res &= false;
|
||||
} catch(com.sun.star.lang.IndexOutOfBoundsException e) {
|
||||
@@ -775,8 +773,7 @@ public class _XAccessibleText {
|
||||
|
||||
try {
|
||||
System.out.println("getTextBeforeIndex(-1, AccessibleTextType.PARAGRAPH):");
|
||||
TextSegment txt = oObj.getTextBeforeIndex(-1,
|
||||
AccessibleTextType.PARAGRAPH);
|
||||
oObj.getTextBeforeIndex(-1, AccessibleTextType.PARAGRAPH);
|
||||
System.out.println("Exception was expected");
|
||||
res &= false;
|
||||
} catch(com.sun.star.lang.IndexOutOfBoundsException e) {
|
||||
@@ -791,8 +788,7 @@ public class _XAccessibleText {
|
||||
try {
|
||||
System.out.println("getTextBeforeIndex(chCount+1, " +
|
||||
"AccessibleTextType.PARAGRAPH):");
|
||||
TextSegment txt = oObj.getTextBeforeIndex(chCount + 1,
|
||||
AccessibleTextType.PARAGRAPH);
|
||||
oObj.getTextBeforeIndex(chCount + 1, AccessibleTextType.PARAGRAPH);
|
||||
System.out.println("Exception was expected");
|
||||
res &= false;
|
||||
} catch(com.sun.star.lang.IndexOutOfBoundsException e) {
|
||||
@@ -865,8 +861,7 @@ public class _XAccessibleText {
|
||||
|
||||
try {
|
||||
System.out.println("getTextBehindIndex(-1, AccessibleTextType.PARAGRAPH):");
|
||||
TextSegment txt = oObj.getTextBehindIndex(-1,
|
||||
AccessibleTextType.PARAGRAPH);
|
||||
oObj.getTextBehindIndex(-1, AccessibleTextType.PARAGRAPH);
|
||||
System.out.println("Exception was expected");
|
||||
res &= false;
|
||||
} catch(com.sun.star.lang.IndexOutOfBoundsException e) {
|
||||
@@ -881,8 +876,7 @@ public class _XAccessibleText {
|
||||
try {
|
||||
System.out.println("getTextBehindIndex(chCount+1, " +
|
||||
"AccessibleTextType.PARAGRAPH):");
|
||||
TextSegment txt = oObj.getTextBehindIndex(chCount + 1,
|
||||
AccessibleTextType.PARAGRAPH);
|
||||
oObj.getTextBehindIndex(chCount + 1, AccessibleTextType.PARAGRAPH);
|
||||
System.out.println("Exception was expected");
|
||||
res &= false;
|
||||
} catch(com.sun.star.lang.IndexOutOfBoundsException e) {
|
||||
|
||||
@@ -208,8 +208,6 @@ public class AccessibilityTreeModel
|
||||
AccessibleTreeNode aChildNode = null;
|
||||
try
|
||||
{
|
||||
boolean bRet = false;
|
||||
|
||||
// First make sure that the accessible object does not already have
|
||||
// a representation.
|
||||
aChildNode = maNodeMap.GetNode(xNewChild);
|
||||
|
||||
@@ -120,9 +120,6 @@ public class AccessibilityWorkBench
|
||||
{
|
||||
setSize (new Dimension (8000,600));
|
||||
|
||||
JScrollPane aScrollPane;
|
||||
GridBagConstraints constraints;
|
||||
|
||||
// Create new layout.
|
||||
GridBagLayout aLayout = new GridBagLayout ();
|
||||
getContentPane().setLayout (aLayout);
|
||||
@@ -186,7 +183,6 @@ public class AccessibilityWorkBench
|
||||
|
||||
// Button bar.
|
||||
maButtonBar = new JPanel();
|
||||
GridBagLayout aButtonLayout = new GridBagLayout ();
|
||||
maButtonBar.setLayout (new FlowLayout());
|
||||
addGridElement (maButtonBar, 0,3, 2,1, 1,0,
|
||||
GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL);
|
||||
|
||||
@@ -392,7 +392,6 @@ class Canvas
|
||||
|
||||
protected CanvasShape FindCanvasShapeUnderMouse (MouseEvent e)
|
||||
{
|
||||
int nObjects = maObjects.size();
|
||||
CanvasShape aObjectUnderMouse = null;
|
||||
int nCount = maObjectList.size();
|
||||
for (int i=nCount-1; i>=0; --i)
|
||||
|
||||
@@ -118,7 +118,6 @@ class CanvasShape
|
||||
try{
|
||||
// Transform the object's position and size according to the
|
||||
// specified offset and scale.
|
||||
Point aLocation = new Point();
|
||||
maShape = new Rectangle2D.Double (
|
||||
maPosition.x * nScaleFactor + nXOffset,
|
||||
maPosition.y * nScaleFactor + nYOffset,
|
||||
|
||||
@@ -258,7 +258,6 @@ public class InformationWriter
|
||||
+ xContext.getAccessibleDescription());
|
||||
MessageArea.println (sIndent + "Role : "
|
||||
+ xContext.getAccessibleRole());
|
||||
String sHasParent;
|
||||
if (xContext.getAccessibleParent() != null)
|
||||
{
|
||||
MessageArea.println (sIndent + "Has parent : yes");
|
||||
|
||||
@@ -42,7 +42,6 @@ public class Test02 implements TempFileTest {
|
||||
XTempFile xTempFile = null;
|
||||
XTruncate xTruncate = null;
|
||||
String sFileURL = null;
|
||||
String sFileName = null;
|
||||
//create a temporary file.
|
||||
try {
|
||||
oTempFile = m_xMSF.createInstance( "com.sun.star.io.TempFile" );
|
||||
|
||||
@@ -2560,7 +2560,7 @@ public class DOMTest
|
||||
}
|
||||
|
||||
try {
|
||||
XNode xResult = xXPathAPI.selectSingleNode(xDoc, "//pre:foo");
|
||||
xXPathAPI.selectSingleNode(xDoc, "//pre:foo");
|
||||
fail("XXPathAPI.selectSingleNode");
|
||||
} catch (XPathException e) { /* expected */ }
|
||||
xXPathAPI.registerNS("pre", ns);
|
||||
@@ -2572,7 +2572,7 @@ public class DOMTest
|
||||
|
||||
xXPathAPI.unregisterNS("pre", ns);
|
||||
try {
|
||||
XNode xResult = xXPathAPI.selectSingleNode(xDoc, "//pre:foo");
|
||||
xXPathAPI.selectSingleNode(xDoc, "//pre:foo");
|
||||
fail("XXPathAPI.unregisterNS");
|
||||
} catch (XPathException e) { /* expected */ }
|
||||
|
||||
|
||||
@@ -391,7 +391,6 @@ public abstract class Configuration
|
||||
|
||||
public static XNameAccess getChildNodebyDisplayName(XNameAccess _xNameAccessNode, String _displayname)
|
||||
{
|
||||
String[] snames = null;
|
||||
return getChildNodebyDisplayName(_xNameAccessNode, _displayname, PropertyNames.PROPERTY_NAME);
|
||||
}
|
||||
|
||||
@@ -401,7 +400,6 @@ public abstract class Configuration
|
||||
try
|
||||
{
|
||||
snames = _xNameAccessNode.getElementNames();
|
||||
String[] sdisplaynames = new String[snames.length];
|
||||
for (int i = 0; i < snames.length; i++)
|
||||
{
|
||||
String curdisplayname = (String) Helper.getUnoPropertyValue(_xNameAccessNode.getByName(snames[i]), _nodename);
|
||||
@@ -424,7 +422,6 @@ public abstract class Configuration
|
||||
try
|
||||
{
|
||||
snames = _xNameAccessNode.getElementNames();
|
||||
String[] sdisplaynames = new String[snames.length];
|
||||
for (int i = 0; i < snames.length; i++)
|
||||
{
|
||||
String curdisplayname = (String) Helper.getUnoPropertyValue(_xNameAccessNode.getByName(snames[i]), _nodename);
|
||||
|
||||
@@ -335,7 +335,6 @@ public class JavaTools
|
||||
if (!MainString.equals(PropertyNames.EMPTY_STRING))
|
||||
{
|
||||
ArrayList<String> StringVector = new ArrayList<String>();
|
||||
String LocString = null;
|
||||
int iIndex;
|
||||
do
|
||||
{
|
||||
|
||||
@@ -147,7 +147,6 @@ public class NumericalHelper
|
||||
{
|
||||
|
||||
char retValue = 0;
|
||||
boolean hasConversionWarning = false;
|
||||
TypeObject aTypeObject = getTypeObject(aValue);
|
||||
switch (aTypeObject.iType)
|
||||
{
|
||||
|
||||
@@ -131,7 +131,6 @@ public class QueryMetaData extends CommandMetaData
|
||||
public void removeSeveralFieldColumnsByDisplayFieldName(String[] _DisplayFieldNames)
|
||||
{
|
||||
ArrayList<FieldColumn> oRemainingFieldColumns = new ArrayList<FieldColumn>();
|
||||
int a = 0;
|
||||
for (int n = 0; n < FieldColumns.length; n++)
|
||||
{
|
||||
String sDisplayFieldName = FieldColumns[n].getDisplayFieldName();
|
||||
|
||||
@@ -127,7 +127,6 @@ public class RecordParser extends QueryMetaData
|
||||
|
||||
public Object getColumnValue(int ColIndex, int iType)
|
||||
{
|
||||
boolean bResult;
|
||||
Object oAny = Any.VOID;
|
||||
switch (iType)
|
||||
{
|
||||
|
||||
@@ -129,7 +129,6 @@ public class OfficeDocument
|
||||
|
||||
Object oDocument = null;
|
||||
com.sun.star.frame.XComponentLoader xComponentLoader = null;
|
||||
XInterface xInterface = null;
|
||||
String sURL = "private:factory/" + sDocumentType;
|
||||
|
||||
try
|
||||
|
||||
@@ -62,7 +62,6 @@ public class FieldLinker extends DBLimitedFieldSelection
|
||||
int SOSECLINKLST = 1;
|
||||
int SOTHIRDLINKLST = 2;
|
||||
int SOFOURTHLINKLST = 3;
|
||||
Integer IListBoxPosX = new Integer(iCompPosX + 6);
|
||||
sSlaveListHeader = CurUnoDialog.m_oResource.getResArray(UIConsts.RID_FORM + 20, 4); //new String[rowcount];PropertyNames.EMPTY_STRING; //CurUnoDialog.m_oResource.getResText(UIConsts.RID_FORM + 40);
|
||||
sMasterListHeader = CurUnoDialog.m_oResource.getResArray(UIConsts.RID_FORM + 24, 4);// new String[rowcount];PropertyNames.EMPTY_STRING; //CurUnoDialog.m_oResource.getResText(UIConsts.RID_FORM + 40);
|
||||
SOLINKLST = new int[]
|
||||
|
||||
@@ -403,7 +403,6 @@ public class FormWizard extends DatabaseObjectWizard
|
||||
{
|
||||
String sID = JavaTools.ArrayoutofString(sIncSuffix, "_")[1];
|
||||
ID = Integer.parseInt(sID);
|
||||
int a = 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -222,7 +222,6 @@ public class ScenarioSelector extends FieldSelection implements XItemListener, X
|
||||
|
||||
public void addColumnsToDescriptor()
|
||||
{
|
||||
XNameAccess xNameAccessFieldNode;
|
||||
String[] fieldnames = getSelectedFieldNames();
|
||||
for (int i = 0; i < fieldnames.length; i++)
|
||||
{
|
||||
@@ -331,7 +330,6 @@ public class ScenarioSelector extends FieldSelection implements XItemListener, X
|
||||
iduplicate = JavaTools.getDuplicateFieldIndex(NewItems, NewItems[i]);
|
||||
if (iduplicate != -1)
|
||||
{
|
||||
XNameAccess xNameAccessFieldNode;
|
||||
String sdisplayname = Desktop.getUniqueName(NewItems, NewItems[iduplicate], PropertyNames.EMPTY_STRING);
|
||||
FieldDescription curfielddescription = new FieldDescription(xMSF, aLocale, this, sdisplayname, NewItems[iduplicate], imaxcolumnchars);
|
||||
CurTableWizardUnoDialog.fielditems.put(sdisplayname, curfielddescription);
|
||||
|
||||
@@ -316,7 +316,7 @@ public class TextDocument
|
||||
xComponent = UnoRuntime.queryInterface(XComponent.class, xTextDocument);
|
||||
XWindow xWindow = xFrame.getComponentWindow();
|
||||
|
||||
xWindowPeer = UnoRuntime.queryInterface(XWindowPeer.class, xFrame.getComponentWindow());
|
||||
xWindowPeer = UnoRuntime.queryInterface(XWindowPeer.class, xWindow);
|
||||
xMSFDoc = UnoRuntime.queryInterface(XMultiServiceFactory.class, xTextDocument);
|
||||
xNumberFormatsSupplier = UnoRuntime.queryInterface(XNumberFormatsSupplier.class, xTextDocument);
|
||||
|
||||
|
||||
@@ -370,7 +370,6 @@ public class AggregateComponent extends ControlScroller
|
||||
ArrayList<String[]> aggregatevector = new ArrayList<String[]>();
|
||||
PropertyValue[][] aggregatelist = this.getScrollFieldValues();
|
||||
PropertyValue[] currowproperties;
|
||||
PropertyValue curaggregateproperty;
|
||||
if (CurDBMetaData.AggregateFieldNames != null)
|
||||
{
|
||||
for (int i = 0; i < aggregatelist.length; i++)
|
||||
|
||||
@@ -132,7 +132,6 @@ public abstract class ControlScroller
|
||||
{
|
||||
try
|
||||
{
|
||||
boolean bisVisible;
|
||||
ntotfieldcount = _ntotfieldcount;
|
||||
setCurFieldCount();
|
||||
nscrollvalue = 0;
|
||||
@@ -167,9 +166,7 @@ public abstract class ControlScroller
|
||||
|
||||
protected void fillupControls(boolean binitialize)
|
||||
{
|
||||
int newindex;
|
||||
PropertyValue[] oldproperties;
|
||||
PropertyValue[] newproperties;
|
||||
for (int a = 0; a < this.nblockincrement; a++)
|
||||
{
|
||||
if (a < ncurfieldcount)
|
||||
|
||||
@@ -72,7 +72,6 @@ public class SortingComponent
|
||||
xMSF = CurUnoDialog.xMSF;
|
||||
Integer IStep = new Integer(iStep);
|
||||
Integer ICompPosX = new Integer(iCompPosX);
|
||||
Integer ICompPosY = new Integer(iCompPosY);
|
||||
Integer ICompWidth = new Integer(iCompWidth);
|
||||
|
||||
Integer IListBoxPosX = new Integer(iCompPosX + 6);
|
||||
@@ -81,7 +80,6 @@ public class SortingComponent
|
||||
Integer IListBoxWidth = new Integer(iCompWidth - iOptButtonWidth - 12);
|
||||
Integer IOptButtonPosX = new Integer(IListBoxPosX.intValue() + IListBoxWidth.intValue() + 6);
|
||||
getResources();
|
||||
com.sun.star.awt.XWindow[] xListBoxWindow = new com.sun.star.awt.XWindow[4];
|
||||
boolean bDoEnable;
|
||||
String HIDString;
|
||||
int iCurPosY = iCompPosY;
|
||||
|
||||
@@ -553,7 +553,6 @@ public class UnoDialog implements EventNames
|
||||
{
|
||||
int iCurControlStep = AnyConverter.toInt(getControlProperty(controlname, PropertyNames.PROPERTY_STEP));
|
||||
int iCurDialogStep = AnyConverter.toInt(Helper.getUnoPropertyValue(this.xDialogModel, PropertyNames.PROPERTY_STEP));
|
||||
int iNewStep;
|
||||
if (bIsVisible)
|
||||
{
|
||||
setControlProperty(controlname, PropertyNames.PROPERTY_STEP, new Integer(iCurDialogStep));
|
||||
@@ -757,7 +756,7 @@ public class UnoDialog implements EventNames
|
||||
Object oControl = xDlgContainer.getControl(ControlName);
|
||||
xControl = UnoRuntime.queryInterface(XControl.class, oControl);
|
||||
XWindowPeer xWindowPeer = xControl.getPeer();
|
||||
XVclWindowPeer xVclWindowPeer = UnoRuntime.queryInterface(XVclWindowPeer.class, xControl.getPeer());
|
||||
XVclWindowPeer xVclWindowPeer = UnoRuntime.queryInterface(XVclWindowPeer.class, xWindowPeer);
|
||||
xVclWindowPeer.setProperty("AutoMnemonics", Boolean.valueOf(bValue));
|
||||
}
|
||||
|
||||
@@ -1041,16 +1040,11 @@ public class UnoDialog implements EventNames
|
||||
public static int getRedColorShare(int _nColor)
|
||||
{
|
||||
int nRed = _nColor / 65536;
|
||||
int nRedModulo = _nColor % 65536;
|
||||
int nGreen = nRedModulo / 256;
|
||||
int nGreenModulo = (nRedModulo % 256);
|
||||
int nBlue = nGreenModulo;
|
||||
return nRed;
|
||||
}
|
||||
|
||||
public static int getGreenColorShare(int _nColor)
|
||||
{
|
||||
int nRed = _nColor / 65536;
|
||||
int nRedModulo = _nColor % 65536;
|
||||
int nGreen = nRedModulo / 256;
|
||||
return nGreen;
|
||||
@@ -1058,9 +1052,7 @@ public class UnoDialog implements EventNames
|
||||
|
||||
public static int getBlueColorShare(int _nColor)
|
||||
{
|
||||
int nRed = _nColor / 65536;
|
||||
int nRedModulo = _nColor % 65536;
|
||||
int nGreen = nRedModulo / 256;
|
||||
int nGreenModulo = (nRedModulo % 256);
|
||||
int nBlue = nGreenModulo;
|
||||
return nBlue;
|
||||
|
||||
@@ -126,7 +126,6 @@ class MyHandler implements HttpHandler {
|
||||
public void handle(HttpExchange xchange) throws IOException {
|
||||
try {
|
||||
//First get the path to the file
|
||||
File fileCurrent = new File(".");
|
||||
String sRequestPath = xchange.getRequestURI().getPath();
|
||||
System.out.println("requested: " + sRequestPath);
|
||||
File fileRequest = new File(new File(".").getCanonicalPath(), sRequestPath);
|
||||
|
||||
Reference in New Issue
Block a user