mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-04-29 19:45:01 +02:00
externalize strings from Tanya Wolff
This commit is contained in:
parent
51bb196aa0
commit
a7c0f2524f
12 changed files with 30 additions and 23 deletions
|
@ -4,6 +4,9 @@
|
||||||
2004-03-16 Hoda Amer
|
2004-03-16 Hoda Amer
|
||||||
Fix for bug#54324 Refactor: Invoke rename refactoring from editor
|
Fix for bug#54324 Refactor: Invoke rename refactoring from editor
|
||||||
|
|
||||||
|
2004-03-16 Tanya Wolff
|
||||||
|
Externalized strings and marked non-translatable ones.
|
||||||
|
|
||||||
2004-03-15 Hoda Amer
|
2004-03-15 Hoda Amer
|
||||||
Fix for [Bug 54323] Refactor: Menu item from outline view
|
Fix for [Bug 54323] Refactor: Menu item from outline view
|
||||||
|
|
||||||
|
|
|
@ -202,30 +202,30 @@ public class AllTypesCache {
|
||||||
for (int i= 0; i < types.length; ++i) {
|
for (int i= 0; i < types.length; ++i) {
|
||||||
switch (types[i]) {
|
switch (types[i]) {
|
||||||
case ICElement.C_NAMESPACE:
|
case ICElement.C_NAMESPACE:
|
||||||
pattern.addPattern(SearchEngine.createSearchPattern("*", ICSearchConstants.NAMESPACE, ICSearchConstants.DECLARATIONS, false));
|
pattern.addPattern(SearchEngine.createSearchPattern("*", ICSearchConstants.NAMESPACE, ICSearchConstants.DECLARATIONS, false)); //$NON-NLS-1$
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case ICElement.C_CLASS: // fall through
|
case ICElement.C_CLASS: // fall through
|
||||||
case ICElement.C_TEMPLATE_CLASS:
|
case ICElement.C_TEMPLATE_CLASS:
|
||||||
pattern.addPattern(SearchEngine.createSearchPattern("*", ICSearchConstants.CLASS, ICSearchConstants.DECLARATIONS, false));
|
pattern.addPattern(SearchEngine.createSearchPattern("*", ICSearchConstants.CLASS, ICSearchConstants.DECLARATIONS, false)); //$NON-NLS-1$
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case ICElement.C_STRUCT: // fall through
|
case ICElement.C_STRUCT: // fall through
|
||||||
case ICElement.C_TEMPLATE_STRUCT:
|
case ICElement.C_TEMPLATE_STRUCT:
|
||||||
pattern.addPattern(SearchEngine.createSearchPattern("*", ICSearchConstants.STRUCT, ICSearchConstants.DECLARATIONS, false));
|
pattern.addPattern(SearchEngine.createSearchPattern("*", ICSearchConstants.STRUCT, ICSearchConstants.DECLARATIONS, false)); //$NON-NLS-1$
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case ICElement.C_UNION: // fall through
|
case ICElement.C_UNION: // fall through
|
||||||
case ICElement.C_TEMPLATE_UNION:
|
case ICElement.C_TEMPLATE_UNION:
|
||||||
pattern.addPattern(SearchEngine.createSearchPattern("*", ICSearchConstants.UNION, ICSearchConstants.DECLARATIONS, false));
|
pattern.addPattern(SearchEngine.createSearchPattern("*", ICSearchConstants.UNION, ICSearchConstants.DECLARATIONS, false)); //$NON-NLS-1$
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case ICElement.C_ENUMERATION:
|
case ICElement.C_ENUMERATION:
|
||||||
pattern.addPattern(SearchEngine.createSearchPattern("*", ICSearchConstants.ENUM, ICSearchConstants.DECLARATIONS, false));
|
pattern.addPattern(SearchEngine.createSearchPattern("*", ICSearchConstants.ENUM, ICSearchConstants.DECLARATIONS, false)); //$NON-NLS-1$
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case ICElement.C_TYPEDEF:
|
case ICElement.C_TYPEDEF:
|
||||||
pattern.addPattern(SearchEngine.createSearchPattern("*", ICSearchConstants.TYPEDEF, ICSearchConstants.DECLARATIONS, false));
|
pattern.addPattern(SearchEngine.createSearchPattern("*", ICSearchConstants.TYPEDEF, ICSearchConstants.DECLARATIONS, false)); //$NON-NLS-1$
|
||||||
break;
|
break;
|
||||||
|
|
||||||
default:
|
default:
|
||||||
|
|
|
@ -31,7 +31,7 @@ public class TypeSelectionDialog extends TwoPaneElementSelector {
|
||||||
|
|
||||||
private static final char END_SYMBOL= '<';
|
private static final char END_SYMBOL= '<';
|
||||||
private static final char ANY_STRING= '*';
|
private static final char ANY_STRING= '*';
|
||||||
private final static String scopeResolutionOperator= "::";
|
private final static String scopeResolutionOperator= "::"; //$NON-NLS-1$
|
||||||
|
|
||||||
private StringMatcher fMatcher;
|
private StringMatcher fMatcher;
|
||||||
private StringMatcher fQualifierMatcher;
|
private StringMatcher fQualifierMatcher;
|
||||||
|
|
|
@ -151,6 +151,6 @@ public class RenameRefactoring extends Refactoring implements IProcessorBasedRef
|
||||||
if (isAvailable())
|
if (isAvailable())
|
||||||
return getName();
|
return getName();
|
||||||
else
|
else
|
||||||
return "No refactoring available to process: " + fElement;
|
return "No refactoring available to process: " + fElement; //$NON-NLS-1$
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -58,7 +58,7 @@ public class RenameElementProcessor extends RenameProcessor implements IReferenc
|
||||||
private ICElement fCElement = null;
|
private ICElement fCElement = null;
|
||||||
private SearchResultGroup[] fReferences;
|
private SearchResultGroup[] fReferences;
|
||||||
private TextChangeManager fChangeManager;
|
private TextChangeManager fChangeManager;
|
||||||
private final String QUALIFIER = "::";
|
private final String QUALIFIER = "::"; //$NON-NLS-1$
|
||||||
|
|
||||||
private boolean fUpdateReferences;
|
private boolean fUpdateReferences;
|
||||||
|
|
||||||
|
@ -117,7 +117,7 @@ public class RenameElementProcessor extends RenameProcessor implements IReferenc
|
||||||
*/
|
*/
|
||||||
public String getCurrentElementName() {
|
public String getCurrentElementName() {
|
||||||
if(fCElement == null)
|
if(fCElement == null)
|
||||||
return "";
|
return ""; //$NON-NLS-1$
|
||||||
String name = fCElement.getElementName();
|
String name = fCElement.getElementName();
|
||||||
if (name.indexOf(QUALIFIER) != -1){
|
if (name.indexOf(QUALIFIER) != -1){
|
||||||
return (name.substring(name.lastIndexOf(QUALIFIER) + 2, name.length()));
|
return (name.substring(name.lastIndexOf(QUALIFIER) + 2, name.length()));
|
||||||
|
@ -148,7 +148,7 @@ public class RenameElementProcessor extends RenameProcessor implements IReferenc
|
||||||
|
|
||||||
public RefactoringStatus checkNewElementName(String newName){
|
public RefactoringStatus checkNewElementName(String newName){
|
||||||
if ((fCElement == null) || (!(fCElement instanceof ISourceReference)) || (fCElement instanceof ITranslationUnit)) {
|
if ((fCElement == null) || (!(fCElement instanceof ISourceReference)) || (fCElement instanceof ITranslationUnit)) {
|
||||||
return RefactoringStatus.createFatalErrorStatus(RefactoringCoreMessages.getString("RenameTypeRefactoring.wrong_element"));
|
return RefactoringStatus.createFatalErrorStatus(RefactoringCoreMessages.getString("RenameTypeRefactoring.wrong_element")); //$NON-NLS-1$
|
||||||
}
|
}
|
||||||
|
|
||||||
Assert.isNotNull(newName, "new name"); //$NON-NLS-1$
|
Assert.isNotNull(newName, "new name"); //$NON-NLS-1$
|
||||||
|
@ -209,7 +209,7 @@ public class RenameElementProcessor extends RenameProcessor implements IReferenc
|
||||||
public RefactoringStatus checkActivation() throws CoreException {
|
public RefactoringStatus checkActivation() throws CoreException {
|
||||||
RefactoringStatus result= null;
|
RefactoringStatus result= null;
|
||||||
if ((fCElement == null) || (!(fCElement instanceof ISourceReference)) || (fCElement instanceof ITranslationUnit)) {
|
if ((fCElement == null) || (!(fCElement instanceof ISourceReference)) || (fCElement instanceof ITranslationUnit)) {
|
||||||
return RefactoringStatus.createFatalErrorStatus(RefactoringCoreMessages.getString("RenameTypeRefactoring.wrong_element"));
|
return RefactoringStatus.createFatalErrorStatus(RefactoringCoreMessages.getString("RenameTypeRefactoring.wrong_element")); //$NON-NLS-1$
|
||||||
}
|
}
|
||||||
return Checks.checkIfTuBroken(fCElement);
|
return Checks.checkIfTuBroken(fCElement);
|
||||||
|
|
||||||
|
@ -346,7 +346,7 @@ public class RenameElementProcessor extends RenameProcessor implements IReferenc
|
||||||
if(structure.getElementType() == ICElement.C_CLASS){
|
if(structure.getElementType() == ICElement.C_CLASS){
|
||||||
orPattern.addPattern(SearchEngine.createSearchPattern( searchPrefix,
|
orPattern.addPattern(SearchEngine.createSearchPattern( searchPrefix,
|
||||||
ICSearchConstants.METHOD, ICSearchConstants.ALL_OCCURRENCES, false ));
|
ICSearchConstants.METHOD, ICSearchConstants.ALL_OCCURRENCES, false ));
|
||||||
orPattern.addPattern(SearchEngine.createSearchPattern( "~"+ searchPrefix,
|
orPattern.addPattern(SearchEngine.createSearchPattern( "~"+ searchPrefix, //$NON-NLS-1$
|
||||||
ICSearchConstants.METHOD, ICSearchConstants.ALL_OCCURRENCES, false ));
|
ICSearchConstants.METHOD, ICSearchConstants.ALL_OCCURRENCES, false ));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -70,7 +70,7 @@ public class UserInterfaceStarter {
|
||||||
{
|
{
|
||||||
MessageDialog.openInformation(parent,
|
MessageDialog.openInformation(parent,
|
||||||
refactoring.getName(),
|
refactoring.getName(),
|
||||||
"No user interface found");
|
RefactoringMessages.getString("UserInterfaceStarter.No_ui_found")); //$NON-NLS-1$
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -581,3 +581,5 @@ ChangeTypeWizard.computationInterrupted=Computation of valid types was interrupt
|
||||||
ChangeTypeWizard.grayed_types= Type ''{0}'' cannot be used as a replacement for type ''{1}''
|
ChangeTypeWizard.grayed_types= Type ''{0}'' cannot be used as a replacement for type ''{1}''
|
||||||
ChangeTypeWizard.with_itself= Cannot replace type ''{0}'' with itself
|
ChangeTypeWizard.with_itself= Cannot replace type ''{0}'' with itself
|
||||||
ChangeTypeInputPage.Select_Type=Press "Compute" to determine allowable supertypes
|
ChangeTypeInputPage.Select_Type=Press "Compute" to determine allowable supertypes
|
||||||
|
|
||||||
|
UserInterfaceStarter.No_ui_found=No user interface found
|
|
@ -137,7 +137,7 @@ IPropertyChangeListener{
|
||||||
try {
|
try {
|
||||||
text.redrawRange(offset, length, true);
|
text.redrawRange(offset, length, true);
|
||||||
} catch (IllegalArgumentException x) {
|
} catch (IllegalArgumentException x) {
|
||||||
org.eclipse.cdt.internal.core.model.Util.log(x, "Error in CEditor.MouseClickListener.repairRepresentation", ICLogConstants.CDT);
|
org.eclipse.cdt.internal.core.model.Util.log(x, "Error in CEditor.MouseClickListener.repairRepresentation", ICLogConstants.CDT); //$NON-NLS-1$
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -408,9 +408,9 @@ IPropertyChangeListener{
|
||||||
else{
|
else{
|
||||||
String selWord = null;
|
String selWord = null;
|
||||||
String slas = document.get(start,1);
|
String slas = document.get(start,1);
|
||||||
if (slas.equals("\n") ||
|
if (slas.equals("\n") || //$NON-NLS-1$
|
||||||
slas.equals("\t") ||
|
slas.equals("\t") || //$NON-NLS-1$
|
||||||
slas.equals(" "))
|
slas.equals(" ")) //$NON-NLS-1$
|
||||||
{
|
{
|
||||||
|
|
||||||
selWord =document.get(start+1, end - start - 1);
|
selWord =document.get(start+1, end - start - 1);
|
||||||
|
@ -429,7 +429,7 @@ IPropertyChangeListener{
|
||||||
charX == '>')
|
charX == '>')
|
||||||
return null;
|
return null;
|
||||||
|
|
||||||
if (selWord.equals("#include"))
|
if (selWord.equals("#include")) //$NON-NLS-1$
|
||||||
{
|
{
|
||||||
//get start of next identifier
|
//get start of next identifier
|
||||||
|
|
||||||
|
|
|
@ -925,7 +925,7 @@ public class CEditorPreferencePage extends PreferencePage implements IWorkbenchP
|
||||||
item.setControl(createContentAssistPage(folder));
|
item.setControl(createContentAssistPage(folder));
|
||||||
|
|
||||||
item = new TabItem(folder, SWT.NONE);
|
item = new TabItem(folder, SWT.NONE);
|
||||||
item.setText("Navigation");
|
item.setText(PreferencesMessages.getString("CEditorPreferencePage.Navigation")); //$NON-NLS-1$
|
||||||
item.setImage(CPluginImages.get(CPluginImages.IMG_OBJS_TUNIT));
|
item.setImage(CPluginImages.get(CPluginImages.IMG_OBJS_TUNIT));
|
||||||
item.setControl(createNavPage(folder));
|
item.setControl(createNavPage(folder));
|
||||||
|
|
||||||
|
@ -945,7 +945,7 @@ public class CEditorPreferencePage extends PreferencePage implements IWorkbenchP
|
||||||
navComposite.setLayout(layout);
|
navComposite.setLayout(layout);
|
||||||
|
|
||||||
Button navCheck = new Button(navComposite,SWT.CHECK);
|
Button navCheck = new Button(navComposite,SWT.CHECK);
|
||||||
navCheck.setText("Enable Hyperlink Navigation");
|
navCheck.setText(PreferencesMessages.getString("CEditorPreferencePage.Enable_Hyperlink_Navigation")); //$NON-NLS-1$
|
||||||
GridData gd = new GridData(GridData.FILL_HORIZONTAL);
|
GridData gd = new GridData(GridData.FILL_HORIZONTAL);
|
||||||
gd.horizontalSpan = 2;
|
gd.horizontalSpan = 2;
|
||||||
navCheck.setLayoutData(gd);
|
navCheck.setLayoutData(gd);
|
||||||
|
|
|
@ -112,3 +112,5 @@ CEditorPreferencePage.behaviorPage.printMargin=Show print &margin
|
||||||
CEditorPreferencePage.textFont.changeButton=C&hange...
|
CEditorPreferencePage.textFont.changeButton=C&hange...
|
||||||
TemplatePreferencePage.Viewer.preview=Preview:
|
TemplatePreferencePage.Viewer.preview=Preview:
|
||||||
BuildConsolePreferencePage.fieldEditors.buildConsoleLines=&Build console lines:
|
BuildConsolePreferencePage.fieldEditors.buildConsoleLines=&Build console lines:
|
||||||
|
CEditorPreferencePage.Navigation=Navigation
|
||||||
|
CEditorPreferencePage.Enable_Hyperlink_Navigation=Enable Hyperlink Navigation
|
||||||
|
|
|
@ -279,7 +279,7 @@ public class OpenDeclarationsAction extends Action implements IUpdate {
|
||||||
progressMonitor.run(true, true, runnable);
|
progressMonitor.run(true, true, runnable);
|
||||||
|
|
||||||
if (elementsFound.isEmpty() == true) {
|
if (elementsFound.isEmpty() == true) {
|
||||||
MessageDialog.openInformation(getShell(),CSearchMessages.getString("CSearchOperation.operationUnavailable.title"), CSearchMessages.getString("CSearchOperation.operationUnavailable.message")); //$NON-NLS-1$
|
MessageDialog.openInformation(getShell(),CSearchMessages.getString("CSearchOperation.operationUnavailable.title"), CSearchMessages.getString("CSearchOperation.operationUnavailable.message")); //$NON-NLS-1$ //$NON-NLS-2$
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -152,7 +152,7 @@ public class ContentAssistPreference {
|
||||||
boolean useDotAsTrigger = store.getBoolean(AUTOACTIVATION_TRIGGERS_DOT);
|
boolean useDotAsTrigger = store.getBoolean(AUTOACTIVATION_TRIGGERS_DOT);
|
||||||
boolean useArrowAsTrigger = store.getBoolean(AUTOACTIVATION_TRIGGERS_ARROW);
|
boolean useArrowAsTrigger = store.getBoolean(AUTOACTIVATION_TRIGGERS_ARROW);
|
||||||
boolean useDoubleColonAsTrigger = store.getBoolean(AUTOACTIVATION_TRIGGERS_DOUBLECOLON);
|
boolean useDoubleColonAsTrigger = store.getBoolean(AUTOACTIVATION_TRIGGERS_DOUBLECOLON);
|
||||||
String triggers = "";
|
String triggers = ""; //$NON-NLS-1$
|
||||||
if (useDotAsTrigger){
|
if (useDotAsTrigger){
|
||||||
triggers += "."; //$NON-NLS-1$
|
triggers += "."; //$NON-NLS-1$
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue