java: avoid unnecessary comparisons in boolean expressions
i.e. stuff like "x == true" Change-Id: Ib82a4a30e736df392405332fa197b588482cffcf
This commit is contained in:
@@ -184,7 +184,7 @@ public class ParcelBrowseNode extends PropertySet
|
||||
String newName;
|
||||
|
||||
if (aParams == null || aParams.length < 1 ||
|
||||
AnyConverter.isString(aParams[0]) == false)
|
||||
!AnyConverter.isString(aParams[0]))
|
||||
{
|
||||
String prompt = "Enter name for new Script";
|
||||
String title = "Create Script";
|
||||
@@ -269,7 +269,7 @@ public class ParcelBrowseNode extends PropertySet
|
||||
{
|
||||
|
||||
if (aParams == null || aParams.length < 1 ||
|
||||
AnyConverter.isString(aParams[0]) == false)
|
||||
!AnyConverter.isString(aParams[0]))
|
||||
{
|
||||
String prompt = "Enter new name for Library";
|
||||
String title = "Rename Library";
|
||||
|
@@ -183,7 +183,7 @@ public class ProviderBrowseNode extends PropertySet
|
||||
String name;
|
||||
|
||||
if (aParams == null || aParams.length < 1 ||
|
||||
AnyConverter.isString(aParams[0]) == false)
|
||||
!AnyConverter.isString(aParams[0]))
|
||||
{
|
||||
String prompt = "Enter name for new Parcel";
|
||||
String title = "Create Parcel";
|
||||
|
@@ -83,7 +83,7 @@ public class ScriptBrowseNode extends PropertySet
|
||||
LogUtils.DEBUG("** caught exception getting script data for " + name + " ->" + e.toString() );
|
||||
}
|
||||
|
||||
if (provider.hasScriptEditor() == true)
|
||||
if (provider.hasScriptEditor())
|
||||
{
|
||||
|
||||
this.editable = true;
|
||||
|
@@ -193,7 +193,7 @@ public abstract class ScriptProvider
|
||||
contextUrl = getDocUrlFromModel( m_xModel );
|
||||
m_container = new ParcelContainer( m_xContext, contextUrl, language );
|
||||
}
|
||||
else if (AnyConverter.isString(aArguments[0]) == true)
|
||||
else if (AnyConverter.isString(aArguments[0]))
|
||||
{
|
||||
String originalContextURL = AnyConverter.toString(aArguments[0]);
|
||||
LogUtils.DEBUG("creating Application, path: " + originalContextURL );
|
||||
|
@@ -55,7 +55,7 @@ public class PlainSourceView extends JScrollPane
|
||||
so we don't get a storm of DocumentEvents during loading */
|
||||
ta.getDocument().removeDocumentListener(this);
|
||||
|
||||
if (isModified == false)
|
||||
if (!isModified)
|
||||
{
|
||||
int pos = ta.getCaretPosition();
|
||||
ta.setText(model.getText());
|
||||
|
@@ -314,7 +314,7 @@ public class ScriptEditorForBeanShell
|
||||
else if (result == JOptionPane.YES_OPTION)
|
||||
{
|
||||
boolean saveSuccess = saveTextArea();
|
||||
if (saveSuccess == false)
|
||||
if (!saveSuccess)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
@@ -224,7 +224,7 @@ class ScriptImpl implements XScript
|
||||
|
||||
}
|
||||
|
||||
if (editor != null && editor.isModified() == true)
|
||||
if (editor != null && editor.isModified())
|
||||
{
|
||||
LogUtils.DEBUG("GOT A MODIFIED SOURCE");
|
||||
source = editor.getText();
|
||||
|
Reference in New Issue
Block a user