mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-07-03 23:25:26 +02:00
[195399] Improve String display for default port 0
This commit is contained in:
parent
6a92276db8
commit
ec70471613
4 changed files with 14 additions and 10 deletions
|
@ -1,5 +1,5 @@
|
|||
###############################################################################
|
||||
# Copyright (c) 2006, 2007 IBM Corporation and others.
|
||||
# Copyright (c) 2006, 2008 IBM Corporation and others.
|
||||
# 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
|
||||
|
@ -12,7 +12,7 @@
|
|||
# Emily Bruner, Mazen Faraj, Adrian Storisteanu, Li Ding, and Kent Hawley.
|
||||
#
|
||||
# Contributors:
|
||||
# {Name} (company) - description of contribution.
|
||||
# Martin Oberhuber (Wind River) - [195399] Improve String display for default port 0
|
||||
###############################################################################
|
||||
|
||||
##############################################################
|
||||
|
@ -31,7 +31,7 @@ RESID_PROPERTY_DESCRIPTION_TOOLTIP=Description of resource
|
|||
|
||||
RESID_TERM_NOTAPPLICABLE=Not applicable
|
||||
RESID_TERM_NOTAVAILABLE=Not available
|
||||
RESID_PORT_DYNAMICSELECT=(First-available)
|
||||
RESID_PORT_DYNAMICSELECT={0} (Default or first available)
|
||||
RESID_PROPERTY_INHERITED=(Inherited)
|
||||
|
||||
RESID_PROPERTY_FILTERTYPE_VALUE=Remote system filter
|
||||
|
|
|
@ -18,6 +18,7 @@
|
|||
* Martin Oberhuber (Wind River) - [186773] split ISystemRegistryUI from ISystemRegistry
|
||||
* Xuan Chen (IBM) - [160775] [api] rename (at least within a zip) blocks UI thread
|
||||
* David Dykstal (IBM) - [217556] remove service subsystem types
|
||||
* Martin Oberhuber (Wind River) - [195399] Improve String display for default port 0
|
||||
********************************************************************************/
|
||||
|
||||
package org.eclipse.rse.internal.ui.view;
|
||||
|
@ -41,6 +42,7 @@ import org.eclipse.rse.ui.validators.ISystemValidator;
|
|||
import org.eclipse.rse.ui.validators.ValidatorPortInput;
|
||||
import org.eclipse.rse.ui.view.AbstractSystemViewAdapter;
|
||||
import org.eclipse.rse.ui.view.ISystemPropertyConstants;
|
||||
import org.eclipse.rse.ui.view.SystemAdapterHelpers;
|
||||
import org.eclipse.swt.widgets.Shell;
|
||||
import org.eclipse.ui.views.properties.IPropertyDescriptor;
|
||||
import org.eclipse.ui.views.properties.PropertyDescriptor;
|
||||
|
@ -326,7 +328,7 @@ public class SystemViewSubSystemAdapter extends AbstractSystemViewAdapter
|
|||
if (!notApplicable)
|
||||
{
|
||||
data.setInheritedValue("0");
|
||||
data.setInheritedDisplayString(SystemResources.RESID_PORT_DYNAMICSELECT));
|
||||
data.setInheritedDisplayString(NLS.bind(SystemPropertyResources.RESID_PORT_DYNAMICSELECT, "0")); //$NON-NLS-1$
|
||||
data.setIsLocal(iPort != 0);
|
||||
}
|
||||
data.setNotApplicable(notApplicable);
|
||||
|
@ -737,7 +739,7 @@ public class SystemViewSubSystemAdapter extends AbstractSystemViewAdapter
|
|||
public String getInputMementoHandle(Object element)
|
||||
{
|
||||
Object parent = getParent(element);
|
||||
return getSystemViewElementAdapter(parent).getInputMementoHandle(parent) + MEMENTO_DELIM + getMementoHandle(element);
|
||||
return SystemAdapterHelpers.getViewAdapter(parent, getViewer()).getInputMementoHandle(parent) + MEMENTO_DELIM + getMementoHandle(element);
|
||||
}
|
||||
/**
|
||||
* Return a short string to uniquely identify the type of resource. Eg "conn" for connection.
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
/********************************************************************************
|
||||
* Copyright (c) 2002, 2007 IBM Corporation and others. All rights reserved.
|
||||
* Copyright (c) 2002, 2008 IBM Corporation and others. 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
|
||||
|
@ -12,6 +12,7 @@
|
|||
*
|
||||
* Contributors:
|
||||
* Martin Oberhuber (Wind River) - [186748] Move ISubSystemConfigurationAdapter from UI/rse.core.subsystems.util
|
||||
* Martin Oberhuber (Wind River) - [195399] Improve String display for default port 0
|
||||
********************************************************************************/
|
||||
|
||||
package org.eclipse.rse.ui.propertypages;
|
||||
|
@ -176,7 +177,7 @@ public class SystemSubSystemPropertyPageCoreForm extends AbstractSystemSubSystem
|
|||
else
|
||||
{
|
||||
textPort.setLocalText(localPort);
|
||||
textPort.setInheritedText("0 "+SystemResources.RESID_PORT_DYNAMICSELECT));
|
||||
textPort.setInheritedText(NLS.bind(SystemPropertyResources.RESID_PORT_DYNAMICSELECT, new Integer(0)));
|
||||
textPort.setLocal(iPort != 0);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
/*******************************************************************************
|
||||
* Copyright (c) 2002, 2007 IBM Corporation and others.
|
||||
* Copyright (c) 2002, 2008 IBM Corporation and others.
|
||||
* 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
|
||||
|
@ -12,10 +12,11 @@
|
|||
* Emily Bruner, Mazen Faraj, Adrian Storisteanu, Li Ding, and Kent Hawley.
|
||||
*
|
||||
* Contributors:
|
||||
* {Name} (company) - description of contribution.
|
||||
* Martin Oberhuber (Wind River) - [195399] Improve String display for default port 0
|
||||
*******************************************************************************/
|
||||
|
||||
package org.eclipse.rse.ui.widgets;
|
||||
import org.eclipse.osgi.util.NLS;
|
||||
import org.eclipse.rse.internal.ui.SystemPropertyResources;
|
||||
import org.eclipse.rse.internal.ui.SystemResources;
|
||||
import org.eclipse.rse.services.clientserver.messages.SystemMessage;
|
||||
|
@ -189,7 +190,7 @@ public class SystemPortPrompt
|
|||
else // editable
|
||||
{
|
||||
textPort.setLocalText(localPort);
|
||||
textPort.setInheritedText("0 "+SystemPropertyResources.RESID_PORT_DYNAMICSELECT); //$NON-NLS-1$
|
||||
textPort.setInheritedText(NLS.bind(SystemPropertyResources.RESID_PORT_DYNAMICSELECT, new Integer(0)));
|
||||
textPort.setLocal(iPort != 0);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue