Kaydet (Commit) 3f210b0e authored tarafından Noel Grandin's avatar Noel Grandin

java: remove unnecessary return statements

found by PMD

Change-Id: I3d150421948d17eaed34fac2b1a212da34288d1a
üst a753a458
...@@ -956,7 +956,6 @@ public class DocumentLoader ...@@ -956,7 +956,6 @@ public class DocumentLoader
Animation.RELATIVE_TO_SELF, 0, Animation.RELATIVE_TO_SELF, 0); Animation.RELATIVE_TO_SELF, 0, Animation.RELATIVE_TO_SELF, 0);
outToLeft.setDuration(500); outToLeft.setDuration(500);
viewFlipper.setOutAnimation(outToLeft); viewFlipper.setOutAnimation(outToLeft);
return;
} }
private void setAnimationInFromLeft(){ private void setAnimationInFromLeft(){
...@@ -969,7 +968,6 @@ public class DocumentLoader ...@@ -969,7 +968,6 @@ public class DocumentLoader
Animation.RELATIVE_TO_SELF, 0, Animation.RELATIVE_TO_SELF, 0); Animation.RELATIVE_TO_SELF, 0, Animation.RELATIVE_TO_SELF, 0);
outToRight.setDuration(500); outToRight.setDuration(500);
viewFlipper.setOutAnimation(outToRight); viewFlipper.setOutAnimation(outToRight);
return;
} }
private PageViewer fetch( int page ){ private PageViewer fetch( int page ){
......
...@@ -387,7 +387,6 @@ public class LibreOfficeUIActivity extends SherlockActivity implements ActionBar ...@@ -387,7 +387,6 @@ public class LibreOfficeUIActivity extends SherlockActivity implements ActionBar
break; break;
} }
this.onResume(); this.onResume();
return;
} }
public void readPreferences(){ public void readPreferences(){
......
...@@ -132,7 +132,7 @@ public class SequenceOutputStreamUnitTest /* extends ComplexTestCase*/ { ...@@ -132,7 +132,7 @@ public class SequenceOutputStreamUnitTest /* extends ComplexTestCase*/ {
m_aTestHelper.Error ( "Exception: " + e ); m_aTestHelper.Error ( "Exception: " + e );
return /* false */; return /* false */;
} }
return /* true */; // return /* true */;
} }
private static XMultiServiceFactory getMSF() private static XMultiServiceFactory getMSF()
......
...@@ -362,7 +362,6 @@ public final class OwnEmbeddedObject extends WeakBase ...@@ -362,7 +362,6 @@ public final class OwnEmbeddedObject extends WeakBase
public void reload(com.sun.star.beans.PropertyValue[] aMediaArgs, com.sun.star.beans.PropertyValue[] aObjectArgs) throws com.sun.star.lang.IllegalArgumentException, com.sun.star.embed.WrongStateException, com.sun.star.io.IOException, com.sun.star.uno.Exception public void reload(com.sun.star.beans.PropertyValue[] aMediaArgs, com.sun.star.beans.PropertyValue[] aObjectArgs) throws com.sun.star.lang.IllegalArgumentException, com.sun.star.embed.WrongStateException, com.sun.star.io.IOException, com.sun.star.uno.Exception
{ {
// not implemented currently // not implemented currently
return;
} }
// com.sun.star.embed.XEmbedPersist: // com.sun.star.embed.XEmbedPersist:
......
...@@ -211,7 +211,6 @@ public class utils { ...@@ -211,7 +211,6 @@ public class utils {
//create the directory //create the directory
new_dir.mkdirs(); new_dir.mkdirs();
} }
return;
} }
......
...@@ -150,7 +150,6 @@ public class _XFastPropertySet extends MultiMethodTest { ...@@ -150,7 +150,6 @@ public class _XFastPropertySet extends MultiMethodTest {
e.printStackTrace(log); e.printStackTrace(log);
tRes.tested("getFastPropertyValue()",false); tRes.tested("getFastPropertyValue()",false);
} }
return;
} }
......
...@@ -334,8 +334,6 @@ public class _XMultiPropertySet extends MultiMethodTest { ...@@ -334,8 +334,6 @@ public class _XMultiPropertySet extends MultiMethodTest {
testPropsNames = new String[nr]; testPropsNames = new String[nr];
for (int i=0; i<nr; i++) testPropsNames[i] = ST.nextToken(); for (int i=0; i<nr; i++) testPropsNames[i] = ST.nextToken();
testPropsAmount = nr; testPropsAmount = nr;
return;
} }
/** /**
......
...@@ -89,7 +89,6 @@ public class _XPropertyAccess extends MultiMethodTest { ...@@ -89,7 +89,6 @@ public class _XPropertyAccess extends MultiMethodTest {
} }
tRes.tested("getPropertyValues()", ok ); tRes.tested("getPropertyValues()", ok );
return;
} }
/** /**
...@@ -219,8 +218,6 @@ public class _XPropertyAccess extends MultiMethodTest { ...@@ -219,8 +218,6 @@ public class _XPropertyAccess extends MultiMethodTest {
} }
tRes.tested("setPropertyValues()", ok); tRes.tested("setPropertyValues()", ok);
return;
} }
} /// finish class XPropertyAccess } /// finish class XPropertyAccess
......
...@@ -211,7 +211,6 @@ public class _XPropertyContainer extends MultiMethodTest { ...@@ -211,7 +211,6 @@ public class _XPropertyContainer extends MultiMethodTest {
ok &= test; ok &= test;
tRes.tested("addProperty()", ok ); tRes.tested("addProperty()", ok );
return;
} }
/** /**
...@@ -294,7 +293,6 @@ public class _XPropertyContainer extends MultiMethodTest { ...@@ -294,7 +293,6 @@ public class _XPropertyContainer extends MultiMethodTest {
} }
tRes.tested("removeProperty()", ok ); tRes.tested("removeProperty()", ok );
return;
} }
......
...@@ -133,9 +133,6 @@ public class _XPropertySet extends MultiMethodTest { ...@@ -133,9 +133,6 @@ public class _XPropertySet extends MultiMethodTest {
tRes.tested("getPropertySetInfo()", true ); tRes.tested("getPropertySetInfo()", true );
getPropsToTest(propertySetInfo); getPropsToTest(propertySetInfo);
} }
return;
} // end of getPropertySetInfo() } // end of getPropertySetInfo()
/** /**
...@@ -194,9 +191,6 @@ public class _XPropertySet extends MultiMethodTest { ...@@ -194,9 +191,6 @@ public class _XPropertySet extends MultiMethodTest {
} }
tRes.tested("addPropertyChangeListener()", !error); tRes.tested("addPropertyChangeListener()", !error);
} }
return;
} // end of addPropertyChangeListener() } // end of addPropertyChangeListener()
/** /**
...@@ -254,9 +248,6 @@ public class _XPropertySet extends MultiMethodTest { ...@@ -254,9 +248,6 @@ public class _XPropertySet extends MultiMethodTest {
} }
tRes.tested("addVetoableChangeListener()",!error); tRes.tested("addVetoableChangeListener()",!error);
} }
return;
} // end of addVetoableChangeListener() } // end of addVetoableChangeListener()
...@@ -322,9 +313,6 @@ public class _XPropertySet extends MultiMethodTest { ...@@ -322,9 +313,6 @@ public class _XPropertySet extends MultiMethodTest {
} }
tRes.tested("setPropertyValue()",!error); tRes.tested("setPropertyValue()",!error);
} //endif } //endif
return;
} // end of setPropertyValue() } // end of setPropertyValue()
/** /**
...@@ -390,8 +378,6 @@ public class _XPropertySet extends MultiMethodTest { ...@@ -390,8 +378,6 @@ public class _XPropertySet extends MultiMethodTest {
} }
tRes.tested("getPropertyValue()", !error) ; tRes.tested("getPropertyValue()", !error) ;
} }
return;
} }
/** /**
...@@ -464,9 +450,6 @@ public class _XPropertySet extends MultiMethodTest { ...@@ -464,9 +450,6 @@ public class _XPropertySet extends MultiMethodTest {
} }
tRes.tested("removePropertyChangeListener()",!error); tRes.tested("removePropertyChangeListener()",!error);
} }
return;
} // end of removePropertyChangeListener() } // end of removePropertyChangeListener()
...@@ -539,9 +522,6 @@ public class _XPropertySet extends MultiMethodTest { ...@@ -539,9 +522,6 @@ public class _XPropertySet extends MultiMethodTest {
} }
tRes.tested("removeVetoableChangeListener()",!error); tRes.tested("removeVetoableChangeListener()",!error);
} }
return;
} // end of removeVetoableChangeListener() } // end of removeVetoableChangeListener()
/** /**
......
...@@ -49,7 +49,6 @@ public class _XPropertySetInfo extends MultiMethodTest { ...@@ -49,7 +49,6 @@ public class _XPropertySetInfo extends MultiMethodTest {
Property[] properties = oObj.getProperties(); Property[] properties = oObj.getProperties();
IsThere = properties[0]; IsThere = properties[0];
tRes.tested("getProperties()", ( properties != null )); tRes.tested("getProperties()", ( properties != null ));
return;
} }
/** /**
...@@ -88,7 +87,6 @@ public class _XPropertySetInfo extends MultiMethodTest { ...@@ -88,7 +87,6 @@ public class _XPropertySetInfo extends MultiMethodTest {
result = true; result = true;
} }
tRes.tested("getPropertyByName()", result); tRes.tested("getPropertyByName()", result);
return;
} }
/** /**
......
...@@ -89,7 +89,6 @@ public class _XEnumeration extends MultiMethodTest { ...@@ -89,7 +89,6 @@ public class _XEnumeration extends MultiMethodTest {
result &= locResult; result &= locResult;
} }
tRes.tested("hasMoreElements()", result); tRes.tested("hasMoreElements()", result);
return;
} // end hasMoreElements } // end hasMoreElements
/** /**
...@@ -119,9 +118,6 @@ public class _XEnumeration extends MultiMethodTest { ...@@ -119,9 +118,6 @@ public class _XEnumeration extends MultiMethodTest {
} }
tRes.tested("nextElement()", result); tRes.tested("nextElement()", result);
return;
} // end NextElement } // end NextElement
} //end XEnumeration } //end XEnumeration
......
...@@ -40,7 +40,6 @@ public class _XEnumerationAccess extends MultiMethodTest{ ...@@ -40,7 +40,6 @@ public class _XEnumerationAccess extends MultiMethodTest{
log.println( "createing Enumeration" ); log.println( "createing Enumeration" );
XEnumeration oEnum = oObj.createEnumeration(); XEnumeration oEnum = oObj.createEnumeration();
tRes.tested( "createEnumeration()", oEnum != null ); tRes.tested( "createEnumeration()", oEnum != null );
return;
} // end createEnumeration() } // end createEnumeration()
} // finish class _XEnumerationAccess } // finish class _XEnumerationAccess
......
...@@ -44,7 +44,6 @@ public class _XNameAccess extends MultiMethodTest { ...@@ -44,7 +44,6 @@ public class _XNameAccess extends MultiMethodTest {
result = (Names != null); result = (Names != null);
tRes.tested("getElementNames()", result); tRes.tested("getElementNames()", result);
return;
} // end getElementNames() } // end getElementNames()
/** /**
...@@ -86,8 +85,6 @@ public class _XNameAccess extends MultiMethodTest { ...@@ -86,8 +85,6 @@ public class _XNameAccess extends MultiMethodTest {
result &= loc_result; result &= loc_result;
tRes.tested("hasByName()", result); tRes.tested("hasByName()", result);
return;
} // end hasByName() } // end hasByName()
...@@ -145,9 +142,6 @@ public class _XNameAccess extends MultiMethodTest { ...@@ -145,9 +142,6 @@ public class _XNameAccess extends MultiMethodTest {
result &= loc_result; result &= loc_result;
tRes.tested("getByName()", result); tRes.tested("getByName()", result);
return;
} // end getByName() } // end getByName()
} /// finished class _XNameAccess } /// finished class _XNameAccess
......
...@@ -241,8 +241,6 @@ public class _XNameContainer extends MultiMethodTest { ...@@ -241,8 +241,6 @@ public class _XNameContainer extends MultiMethodTest {
} }
tRes.tested("removeByName()", result); tRes.tested("removeByName()", result);
return;
} // end removeByName() } // end removeByName()
} //XNameContainer } //XNameContainer
......
...@@ -162,9 +162,6 @@ public class _XReset extends MultiMethodTest { ...@@ -162,9 +162,6 @@ public class _XReset extends MultiMethodTest {
shortWait(); shortWait();
tRes.tested("removeResetListener()", !approveReset[0] && !resetted[0]); tRes.tested("removeResetListener()", !approveReset[0] && !resetted[0]);
//removing the second listener here may avoid crashing the office //removing the second listener here may avoid crashing the office
return;
} // finished _removeResetListener() } // finished _removeResetListener()
/** /**
......
...@@ -207,8 +207,6 @@ public class _XValidatableFormComponent extends MultiMethodTest ...@@ -207,8 +207,6 @@ public class _XValidatableFormComponent extends MultiMethodTest
testPropsNames[i] = ST.nextToken(); testPropsNames[i] = ST.nextToken();
testPropsAmount = nr; testPropsAmount = nr;
return;
} }
protected class MyListener implements XFormComponentValidityListener protected class MyListener implements XFormComponentValidityListener
......
...@@ -141,7 +141,6 @@ public class _XComponentLoader extends MultiMethodTest { ...@@ -141,7 +141,6 @@ public class _XComponentLoader extends MultiMethodTest {
} }
tRes.tested("loadComponentFromURL()", result); tRes.tested("loadComponentFromURL()", result);
return;
} }
} }
......
...@@ -149,7 +149,6 @@ public class _XDispatchProvider extends MultiMethodTest { ...@@ -149,7 +149,6 @@ public class _XDispatchProvider extends MultiMethodTest {
} }
tRes.tested("queryDispatches()", true); tRes.tested("queryDispatches()", true);
return;
} }
} }
......
...@@ -94,8 +94,6 @@ public class _XComponent extends MultiMethodTest { ...@@ -94,8 +94,6 @@ public class _XComponent extends MultiMethodTest {
oObj.addEventListener( listener1 ); oObj.addEventListener( listener1 );
oObj.addEventListener( listener2 ); oObj.addEventListener( listener2 );
return;
} // finished _addEventListener() } // finished _addEventListener()
/** /**
......
...@@ -58,7 +58,6 @@ public class _XReplaceDescriptor extends MultiMethodTest { ...@@ -58,7 +58,6 @@ public class _XReplaceDescriptor extends MultiMethodTest {
oObj.setReplaceString("XReplaceDescriptor"); oObj.setReplaceString("XReplaceDescriptor");
String cmpReplaceStr = oObj.getReplaceString(); String cmpReplaceStr = oObj.getReplaceString();
tRes.tested("setReplaceString()", !(cmpReplaceStr.equals(oldReplaceStr))); tRes.tested("setReplaceString()", !(cmpReplaceStr.equals(oldReplaceStr)));
return;
} }
} // finish class _XReplaceDescriptor } // finish class _XReplaceDescriptor
......
...@@ -118,8 +118,6 @@ public class HighlightText implements com.sun.star.awt.XActionListener { ...@@ -118,8 +118,6 @@ public class HighlightText implements com.sun.star.awt.XActionListener {
exitButton.addActionListener(this); exitButton.addActionListener(this);
findDialog.execute(); findDialog.execute();
return;
} }
public void actionPerformed(ActionEvent e) { public void actionPerformed(ActionEvent e) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment