mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-07-04 07:35:24 +02:00
[225506] fix: [api][breaking] RSE UI leaks non-API types
This commit is contained in:
parent
beda642b75
commit
38da1396a3
3 changed files with 38 additions and 15 deletions
|
@ -0,0 +1,31 @@
|
|||
/*********************************************************************************
|
||||
* Copyright (c) 2008 IBM Corporation. All rights reserved.
|
||||
* This program and the accompanying materials are made available under the terms
|
||||
* of the Eclipse Public License v1.0 which accompanies this distribution, and is
|
||||
* available at http://www.eclipse.org/legal/epl-v10.html
|
||||
*
|
||||
* Contributors:
|
||||
* Xuan Chen (IBM) - [225506] initial contribution
|
||||
*********************************************************************************/
|
||||
package org.eclipse.rse.files.ui.dialogs;
|
||||
|
||||
import org.eclipse.rse.internal.files.ui.dialogs.SaveAsDialog;
|
||||
import org.eclipse.swt.widgets.Shell;
|
||||
|
||||
/**
|
||||
* @author xuanchen
|
||||
*
|
||||
*/
|
||||
public class SaveAsDialogFactory {
|
||||
|
||||
public static ISaveAsDialog getSaveAsDialog(Shell shell, String title)
|
||||
{
|
||||
return new SaveAsDialog(shell, title);
|
||||
}
|
||||
|
||||
public static ISaveAsDialog getSaveAsDialog(Shell shell)
|
||||
{
|
||||
return new SaveAsDialog(shell);
|
||||
}
|
||||
|
||||
}
|
|
@ -19,6 +19,7 @@
|
|||
* David McKnight (IBM) - [216252] [api][nls] Resource Strings specific to subsystems should be moved from rse.ui into files.ui / shells.ui / processes.ui where possible
|
||||
* David McKnight (IBM) - [220547] [api][breaking] SimpleSystemMessage needs to specify a message id and some messages should be shared
|
||||
* David McKnight (IBM) - [224377] "open with" menu does not have "other" option
|
||||
* Xuan Chen (IBM) - [225506] [api][breaking] RSE UI leaks non-API types
|
||||
*******************************************************************************/
|
||||
|
||||
package org.eclipse.rse.internal.files.ui.actions;
|
||||
|
@ -36,7 +37,7 @@ import org.eclipse.rse.core.events.SystemResourceChangeEvent;
|
|||
import org.eclipse.rse.core.subsystems.SubSystem;
|
||||
import org.eclipse.rse.core.subsystems.SubSystem.SystemMessageDialogRunnable;
|
||||
import org.eclipse.rse.files.ui.dialogs.ISaveAsDialog;
|
||||
import org.eclipse.rse.files.ui.dialogs.SaveAsDialog;
|
||||
import org.eclipse.rse.files.ui.dialogs.SaveAsDialogFactory;
|
||||
import org.eclipse.rse.files.ui.resources.SystemEditableRemoteFile;
|
||||
import org.eclipse.rse.internal.files.ui.Activator;
|
||||
import org.eclipse.rse.internal.files.ui.FileResources;
|
||||
|
@ -405,7 +406,7 @@ public class SystemUploadConflictAction extends SystemBaseAction implements Runn
|
|||
if (e.getSource() == _browseButton)
|
||||
{
|
||||
|
||||
ISaveAsDialog dlg = SaveAsDialog.getSaveAsDialog(getShell());
|
||||
ISaveAsDialog dlg = SaveAsDialogFactory.getSaveAsDialog(getShell());
|
||||
dlg.setMultipleSelectionMode(false);
|
||||
|
||||
if (_remoteFile != null)
|
||||
|
|
|
@ -17,12 +17,12 @@
|
|||
* Move SystemSelectRemoteFileOrFolderDialog to internal package first.
|
||||
*******************************************************************************/
|
||||
|
||||
package org.eclipse.rse.files.ui.dialogs;
|
||||
package org.eclipse.rse.internal.files.ui.dialogs;
|
||||
|
||||
import org.eclipse.core.runtime.NullProgressMonitor;
|
||||
import org.eclipse.rse.files.ui.dialogs.ISaveAsDialog;
|
||||
import org.eclipse.rse.files.ui.widgets.SaveAsForm;
|
||||
import org.eclipse.rse.files.ui.widgets.SystemSelectRemoteFileOrFolderForm;
|
||||
import org.eclipse.rse.internal.files.ui.dialogs.SystemSelectRemoteFileOrFolderDialog;
|
||||
import org.eclipse.rse.subsystems.files.core.subsystems.IRemoteFile;
|
||||
import org.eclipse.swt.widgets.Shell;
|
||||
|
||||
|
@ -38,7 +38,7 @@ public class SaveAsDialog extends SystemSelectRemoteFileOrFolderDialog implement
|
|||
* @param shell The shell to hang the dialog off of
|
||||
*
|
||||
*/
|
||||
protected SaveAsDialog(Shell shell)
|
||||
public SaveAsDialog(Shell shell)
|
||||
{
|
||||
super(shell, false);
|
||||
}
|
||||
|
@ -48,20 +48,11 @@ public class SaveAsDialog extends SystemSelectRemoteFileOrFolderDialog implement
|
|||
* @param shell The shell to hang the dialog off of
|
||||
* @param title The title to give the dialog
|
||||
*/
|
||||
protected SaveAsDialog(Shell shell, String title)
|
||||
public SaveAsDialog(Shell shell, String title)
|
||||
{
|
||||
super(shell, title, true);
|
||||
}
|
||||
|
||||
public static ISaveAsDialog getSaveAsDialog(Shell shell, String title)
|
||||
{
|
||||
return new SaveAsDialog(shell, title);
|
||||
}
|
||||
|
||||
public static ISaveAsDialog getSaveAsDialog(Shell shell)
|
||||
{
|
||||
return new SaveAsDialog(shell);
|
||||
}
|
||||
|
||||
protected SystemSelectRemoteFileOrFolderForm getForm(boolean fileMode)
|
||||
{
|
Loading…
Add table
Reference in a new issue