1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-07-16 13:35:22 +02:00

[cleanup] fix 'local variable/field is never read' compiler warnings

This commit is contained in:
Martin Oberhuber 2006-08-29 09:43:23 +00:00
parent 700df9b49d
commit a4349288d1
5 changed files with 21 additions and 28 deletions

View file

@ -19,20 +19,15 @@ package org.eclipse.rse.files.ui.actions;
import org.eclipse.jface.resource.ImageDescriptor; import org.eclipse.jface.resource.ImageDescriptor;
import org.eclipse.jface.viewers.IStructuredSelection; import org.eclipse.jface.viewers.IStructuredSelection;
import org.eclipse.rse.core.SystemBasePlugin; import org.eclipse.rse.core.SystemBasePlugin;
import org.eclipse.rse.files.ui.resources.ISystemRemoteEditConstants;
import org.eclipse.rse.files.ui.resources.SystemEditableRemoteFile; import org.eclipse.rse.files.ui.resources.SystemEditableRemoteFile;
import org.eclipse.rse.subsystems.files.core.subsystems.IRemoteFile; import org.eclipse.rse.subsystems.files.core.subsystems.IRemoteFile;
import org.eclipse.rse.ui.RSEUIPlugin;
import org.eclipse.rse.ui.actions.SystemBaseAction; import org.eclipse.rse.ui.actions.SystemBaseAction;
import org.eclipse.swt.widgets.Shell; import org.eclipse.swt.widgets.Shell;
public class SystemEditFileInPlaceAction extends SystemBaseAction implements ISystemRemoteEditConstants { public class SystemEditFileInPlaceAction extends SystemBaseAction
{
//private RSEUIPlugin plugin;
private RSEUIPlugin plugin;
/** /**
* Constructor for SystemEditFileAction * Constructor for SystemEditFileAction
@ -53,7 +48,7 @@ public class SystemEditFileInPlaceAction extends SystemBaseAction implements ISy
// had to add it in the group in the adapter // had to add it in the group in the adapter
// setContextMenuGroup(ISystemContextMenuConstants.GROUP_OPENWITH); // setContextMenuGroup(ISystemContextMenuConstants.GROUP_OPENWITH);
plugin = RSEUIPlugin.getDefault(); //plugin = RSEUIPlugin.getDefault();
} }

View file

@ -19,20 +19,15 @@ package org.eclipse.rse.files.ui.actions;
import org.eclipse.jface.resource.ImageDescriptor; import org.eclipse.jface.resource.ImageDescriptor;
import org.eclipse.jface.viewers.IStructuredSelection; import org.eclipse.jface.viewers.IStructuredSelection;
import org.eclipse.rse.core.SystemBasePlugin; import org.eclipse.rse.core.SystemBasePlugin;
import org.eclipse.rse.files.ui.resources.ISystemRemoteEditConstants;
import org.eclipse.rse.files.ui.resources.SystemEditableRemoteFile; import org.eclipse.rse.files.ui.resources.SystemEditableRemoteFile;
import org.eclipse.rse.subsystems.files.core.subsystems.IRemoteFile; import org.eclipse.rse.subsystems.files.core.subsystems.IRemoteFile;
import org.eclipse.rse.ui.RSEUIPlugin;
import org.eclipse.rse.ui.actions.SystemBaseAction; import org.eclipse.rse.ui.actions.SystemBaseAction;
import org.eclipse.swt.widgets.Shell; import org.eclipse.swt.widgets.Shell;
public class SystemEditFilePlatformAction extends SystemBaseAction implements ISystemRemoteEditConstants { public class SystemEditFilePlatformAction extends SystemBaseAction
{
//private RSEUIPlugin plugin;
private RSEUIPlugin plugin;
/** /**
* Constructor for SystemEditFileAction * Constructor for SystemEditFileAction
@ -53,7 +48,7 @@ public class SystemEditFilePlatformAction extends SystemBaseAction implements IS
// had to add it in the group in the adapter // had to add it in the group in the adapter
// setContextMenuGroup(ISystemContextMenuConstants.GROUP_OPENWITH); // setContextMenuGroup(ISystemContextMenuConstants.GROUP_OPENWITH);
plugin = RSEUIPlugin.getDefault(); //plugin = RSEUIPlugin.getDefault();
} }

View file

@ -159,8 +159,9 @@ public class SystemCommandEditor extends SourceViewer
doOperation(ISourceViewer.CONTENTASSIST_PROPOSALS); doOperation(ISourceViewer.CONTENTASSIST_PROPOSALS);
//e.doit = false; //e.doit = false;
break; break;
case 'z' - 'a' + 1 :
// CTRL-Z // CTRL-Z
case (int) 'z' - (int) 'a' + 1 :
doOperation(ITextOperationTarget.UNDO); doOperation(ITextOperationTarget.UNDO);
//e.doit = false; //e.doit = false;
break; break;

View file

@ -60,7 +60,7 @@ public class SystemDeleteDialog extends SystemPromptDialog
private String warningMessage, warningTip; private String warningMessage, warningTip;
private String promptLabel; private String promptLabel;
private SystemDeleteTableProvider sdtp; private SystemDeleteTableProvider sdtp;
private Label prompt; //private Label prompt;
private Table table; private Table table;
private TableViewer tableViewer; private TableViewer tableViewer;
private GridData tableData; private GridData tableData;
@ -103,7 +103,7 @@ public class SystemDeleteDialog extends SystemPromptDialog
*/ */
protected ISystemMessageLine createMessageLine(Composite c) protected ISystemMessageLine createMessageLine(Composite c)
{ {
ISystemMessageLine msgLine = super.createMessageLine(c); /*ISystemMessageLine msgLine =*/ super.createMessageLine(c);
return fMessageLine; return fMessageLine;
} }
@ -150,19 +150,19 @@ public class SystemDeleteDialog extends SystemPromptDialog
int size = ((IStructuredSelection)input).size(); int size = ((IStructuredSelection)input).size();
if (size > 1) { if (size > 1) {
prompt = SystemWidgetHelpers.createLabel(composite, SystemResources.RESID_DELETE_PROMPT, nbrColumns); /*prompt =*/ SystemWidgetHelpers.createLabel(composite, SystemResources.RESID_DELETE_PROMPT, nbrColumns);
} }
else { else {
prompt = SystemWidgetHelpers.createLabel(composite, SystemResources.RESID_DELETE_PROMPT_SINGLE, nbrColumns); /*prompt =*/ SystemWidgetHelpers.createLabel(composite, SystemResources.RESID_DELETE_PROMPT_SINGLE, nbrColumns);
} }
} }
// should never get here // should never get here
else { else {
prompt = SystemWidgetHelpers.createLabel(composite, SystemResources.RESID_DELETE_PROMPT, nbrColumns); /*prompt =*/ SystemWidgetHelpers.createLabel(composite, SystemResources.RESID_DELETE_PROMPT, nbrColumns);
} }
} }
else { else {
prompt = SystemWidgetHelpers.createVerbiage(composite, promptLabel, nbrColumns, false, 200); /*prompt =*/ SystemWidgetHelpers.createVerbiage(composite, promptLabel, nbrColumns, false, 200);
} }
// WARNING // WARNING
@ -186,7 +186,9 @@ public class SystemDeleteDialog extends SystemPromptDialog
if (warningTip != null) if (warningTip != null)
{ {
warningLabel.setToolTipText(warningTip); warningLabel.setToolTipText(warningTip);
imageLabel.setToolTipText(warningTip); if (imageLabel!=null) {
imageLabel.setToolTipText(warningTip);
}
} }
// filler line // filler line
SystemWidgetHelpers.createLabel(composite, "", nbrColumns); SystemWidgetHelpers.createLabel(composite, "", nbrColumns);

View file

@ -35,7 +35,7 @@ import org.eclipse.rse.ui.SystemResources;
public class RSENewConnectionWizard extends AbstractSystemWizard implements IRSENewConnectionWizard { public class RSENewConnectionWizard extends AbstractSystemWizard implements IRSENewConnectionWizard {
private HashMap map; private HashMap map;
private IRSESystemType systemType; //private IRSESystemType systemType;
private IRSENewConnectionWizardDelegate delegate; private IRSENewConnectionWizardDelegate delegate;
private RSENewConnectionWizardMainPage mainPage; private RSENewConnectionWizardMainPage mainPage;
private IRSESystemType[] restrictedSystemTypes; private IRSESystemType[] restrictedSystemTypes;
@ -80,7 +80,7 @@ public class RSENewConnectionWizard extends AbstractSystemWizard implements IRSE
* @see org.eclipse.rse.ui.wizards.IRSENewConnectionWizard#setSelectedSystemType(org.eclipse.rse.core.IRSESystemType) * @see org.eclipse.rse.ui.wizards.IRSENewConnectionWizard#setSelectedSystemType(org.eclipse.rse.core.IRSESystemType)
*/ */
public void setSelectedSystemType(IRSESystemType systemType) { public void setSelectedSystemType(IRSESystemType systemType) {
this.systemType = systemType; //this.systemType = systemType;
setDelegate(systemType); setDelegate(systemType);
} }