mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-08-20 22:55:51 +02:00
[cleanup] Fix compiler warnings
This commit is contained in:
parent
320bb1e594
commit
54e3040567
2 changed files with 33 additions and 35 deletions
|
@ -2497,12 +2497,12 @@ public final class DataStore
|
||||||
{
|
{
|
||||||
for (int i = 0; i < descriptor.getNestedSize(); i++)
|
for (int i = 0; i < descriptor.getNestedSize(); i++)
|
||||||
{
|
{
|
||||||
DataElement subDescriptor = (DataElement) descriptor.get(i).dereference();
|
DataElement subDescriptor = descriptor.get(i).dereference();
|
||||||
String type = subDescriptor.getType();
|
String type = subDescriptor.getType();
|
||||||
if (type == null)
|
if (type == null)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
if (type.equals(DE.T_COMMAND_DESCRIPTOR))
|
else if (type.equals(DE.T_COMMAND_DESCRIPTOR))
|
||||||
{
|
{
|
||||||
if (keyName.equals(subDescriptor.getValue()))
|
if (keyName.equals(subDescriptor.getValue()))
|
||||||
return subDescriptor;
|
return subDescriptor;
|
||||||
|
@ -2646,7 +2646,7 @@ public final class DataStore
|
||||||
return results;
|
return results;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (root != null && root.isDeleted())
|
if (root.isDeleted())
|
||||||
{
|
{
|
||||||
results.add(root);
|
results.add(root);
|
||||||
}
|
}
|
||||||
|
@ -2663,7 +2663,7 @@ public final class DataStore
|
||||||
{
|
{
|
||||||
synchronized (child)
|
synchronized (child)
|
||||||
{
|
{
|
||||||
if (child != null && child.isDeleted() && !results.contains(child))
|
if (child.isDeleted() && !results.contains(child))
|
||||||
{
|
{
|
||||||
|
|
||||||
results.add(child);
|
results.add(child);
|
||||||
|
@ -2704,7 +2704,7 @@ public final class DataStore
|
||||||
// contained relationships
|
// contained relationships
|
||||||
for (int i = 0; i < descriptor.getNestedSize(); i++)
|
for (int i = 0; i < descriptor.getNestedSize(); i++)
|
||||||
{
|
{
|
||||||
DataElement object = ((DataElement) descriptor.get(i)).dereference();
|
DataElement object = descriptor.get(i).dereference();
|
||||||
|
|
||||||
String objType = (String) object.getElementProperty(DE.P_TYPE);
|
String objType = (String) object.getElementProperty(DE.P_TYPE);
|
||||||
if (objType.equals(DE.T_RELATION_DESCRIPTOR) || objType.equals(DE.T_ABSTRACT_RELATION_DESCRIPTOR))
|
if (objType.equals(DE.T_RELATION_DESCRIPTOR) || objType.equals(DE.T_ABSTRACT_RELATION_DESCRIPTOR))
|
||||||
|
@ -2838,7 +2838,7 @@ public final class DataStore
|
||||||
{
|
{
|
||||||
for (int i = 0; i < root.getNestedSize(); i++)
|
for (int i = 0; i < root.getNestedSize(); i++)
|
||||||
{
|
{
|
||||||
DataElement child = (DataElement) root.get(i);
|
DataElement child = root.get(i);
|
||||||
child = child.dereference();
|
child = child.dereference();
|
||||||
if ((child != null) && !searched.contains(child))
|
if ((child != null) && !searched.contains(child))
|
||||||
{
|
{
|
||||||
|
@ -3235,9 +3235,6 @@ public final class DataStore
|
||||||
if (inFile != null)
|
if (inFile != null)
|
||||||
{
|
{
|
||||||
BufferedInputStream document = new BufferedInputStream(inFile);
|
BufferedInputStream document = new BufferedInputStream(inFile);
|
||||||
|
|
||||||
if (document != null)
|
|
||||||
{
|
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
XMLparser parser = new XMLparser(this);
|
XMLparser parser = new XMLparser(this);
|
||||||
|
@ -3257,7 +3254,6 @@ public final class DataStore
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -3320,7 +3316,7 @@ public final class DataStore
|
||||||
{
|
{
|
||||||
for (int i = 0; i < descriptor.getNestedSize(); i++)
|
for (int i = 0; i < descriptor.getNestedSize(); i++)
|
||||||
{
|
{
|
||||||
if (filter((DataElement) descriptor.get(i), dataElement, depth))
|
if (filter(descriptor.get(i), dataElement, depth))
|
||||||
{
|
{
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
@ -3361,7 +3357,7 @@ public final class DataStore
|
||||||
public boolean isTransient(DataElement commandObject)
|
public boolean isTransient(DataElement commandObject)
|
||||||
{
|
{
|
||||||
boolean isTransient = false;
|
boolean isTransient = false;
|
||||||
DataElement subject = (DataElement) commandObject.get(0);
|
DataElement subject = commandObject.get(0);
|
||||||
|
|
||||||
DataElement subjectDescriptor = subject.getDescriptor();
|
DataElement subjectDescriptor = subject.getDescriptor();
|
||||||
if (subjectDescriptor != null)
|
if (subjectDescriptor != null)
|
||||||
|
|
|
@ -806,12 +806,13 @@ public class SystemTableView
|
||||||
int ops = DND.DROP_COPY | DND.DROP_MOVE;
|
int ops = DND.DROP_COPY | DND.DROP_MOVE;
|
||||||
Transfer[] transfers = new Transfer[] { PluginTransfer.getInstance(), TextTransfer.getInstance(), EditorInputTransfer.getInstance(), FileTransfer.getInstance()};
|
Transfer[] transfers = new Transfer[] { PluginTransfer.getInstance(), TextTransfer.getInstance(), EditorInputTransfer.getInstance(), FileTransfer.getInstance()};
|
||||||
|
|
||||||
addDragSupport(ops, transfers, new SystemViewDataDragAdapter((ISelectionProvider) this));
|
addDragSupport(ops, transfers, new SystemViewDataDragAdapter(this));
|
||||||
addDropSupport(ops | DND.DROP_DEFAULT, transfers, new SystemViewDataDropAdapter(this));
|
addDropSupport(ops | DND.DROP_DEFAULT, transfers, new SystemViewDataDropAdapter(this));
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Used to asynchronously update the view whenever properties change.
|
* Used to asynchronously update the view whenever properties change.
|
||||||
|
* @see org.eclipse.rse.model.ISystemResourceChangeListener#systemResourceChanged(org.eclipse.rse.model.ISystemResourceChangeEvent)
|
||||||
*/
|
*/
|
||||||
public void systemResourceChanged(ISystemResourceChangeEvent event)
|
public void systemResourceChanged(ISystemResourceChangeEvent event)
|
||||||
{
|
{
|
||||||
|
@ -920,6 +921,7 @@ public class SystemTableView
|
||||||
child = _objectInput;
|
child = _objectInput;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
break;
|
||||||
default :
|
default :
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
@ -953,7 +955,7 @@ public class SystemTableView
|
||||||
/**
|
/**
|
||||||
* This is the method in your class that will be called when a remote resource
|
* This is the method in your class that will be called when a remote resource
|
||||||
* changes. You will be called after the resource is changed.
|
* changes. You will be called after the resource is changed.
|
||||||
* @see org.eclipse.rse.model.ISystemRemoteChangeEvent
|
* @see org.eclipse.rse.model.ISystemRemoteChangeListener#systemRemoteResourceChanged(org.eclipse.rse.model.ISystemRemoteChangeEvent)
|
||||||
*/
|
*/
|
||||||
public void systemRemoteResourceChanged(ISystemRemoteChangeEvent event)
|
public void systemRemoteResourceChanged(ISystemRemoteChangeEvent event)
|
||||||
{
|
{
|
||||||
|
|
Loading…
Add table
Reference in a new issue