1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-07-31 12:55:40 +02:00

Follow up for 182312, use different dialog settings for 'Open Type in Hierarchy...' and 'Open Type...'

This commit is contained in:
Markus Schorn 2007-04-18 08:31:06 +00:00
parent b699c719b8
commit 324ff07796
6 changed files with 9 additions and 4 deletions

View file

@ -73,6 +73,7 @@ public class OpenTypeAction implements IWorkbenchWindowActionDelegate {
} }
private void configureDialog(OpenTypeDialog dialog) { private void configureDialog(OpenTypeDialog dialog) {
dialog.setDialogSettings(getClass().getName());
if (fWorkbenchWindow != null) { if (fWorkbenchWindow != null) {
IWorkbenchPage page= fWorkbenchWindow.getActivePage(); IWorkbenchPage page= fWorkbenchWindow.getActivePage();
if (page != null) { if (page != null) {

View file

@ -1,5 +1,5 @@
/******************************************************************************* /*******************************************************************************
* Copyright (c) 2004, 2006 IBM Corporation and others. * Copyright (c) 2004, 2007 IBM Corporation and others.
* All rights reserved. This program and the accompanying materials * All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Public License v1.0 * are made available under the terms of the Eclipse Public License v1.0
* which accompanies this distribution, and is available at * which accompanies this distribution, and is available at
@ -8,6 +8,7 @@
* Contributors: * Contributors:
* IBM Corporation - initial API and implementation * IBM Corporation - initial API and implementation
* QNX Software Systems - adapted for use in CDT * QNX Software Systems - adapted for use in CDT
* Markus Schorn (Wind River Systems)
*******************************************************************************/ *******************************************************************************/
package org.eclipse.cdt.ui.browser.typeinfo; package org.eclipse.cdt.ui.browser.typeinfo;
@ -206,13 +207,14 @@ public class TypeSelectionDialog extends TwoPaneElementSelector {
private static final TypeInfoLabelProvider fElementRenderer = new TypeInfoLabelProvider(TypeInfoLabelProvider.SHOW_TYPE_ONLY); private static final TypeInfoLabelProvider fElementRenderer = new TypeInfoLabelProvider(TypeInfoLabelProvider.SHOW_TYPE_ONLY);
private static final TypeInfoLabelProvider fQualifierRenderer = new TypeInfoLabelProvider(TypeInfoLabelProvider.SHOW_ENCLOSING_TYPE_ONLY + TypeInfoLabelProvider.SHOW_PATH); private static final TypeInfoLabelProvider fQualifierRenderer = new TypeInfoLabelProvider(TypeInfoLabelProvider.SHOW_ENCLOSING_TYPE_ONLY + TypeInfoLabelProvider.SHOW_PATH);
static final TypeFilterMatcher fFilterMatcher = new TypeFilterMatcher();
private static final StringComparator fStringComparator = new StringComparator(); private static final StringComparator fStringComparator = new StringComparator();
private static final int[] fAllTypes = { ICElement.C_NAMESPACE, ICElement.C_CLASS, private static final int[] fAllTypes = { ICElement.C_NAMESPACE, ICElement.C_CLASS,
ICElement.C_STRUCT, ICElement.C_TYPEDEF, ICElement.C_ENUMERATION, ICElement.C_STRUCT, ICElement.C_TYPEDEF, ICElement.C_ENUMERATION,
ICElement.C_UNION }; ICElement.C_UNION };
// the filter matcher contains state information, must not be static
private final TypeFilterMatcher fFilterMatcher = new TypeFilterMatcher();
private Set fKnownTypes = new HashSet(fAllTypes.length); private Set fKnownTypes = new HashSet(fAllTypes.length);
private Text fTextWidget; private Text fTextWidget;
private boolean fSelectFilterText = false; private boolean fSelectFilterText = false;

View file

@ -48,4 +48,4 @@ OpenElementInCallHierarchyAction_errorDlgTitle=Open Element in Call Hierarchy
OpenElementInCallHierarchyAction_title=Open Element in Call Hierarchy OpenElementInCallHierarchyAction_title=Open Element in Call Hierarchy
OpenElementInCallHierarchyAction_upperListLabel=&Matching Elements: OpenElementInCallHierarchyAction_upperListLabel=&Matching Elements:
OpenElementInCallHierarchyAction_message=&Choose an element (? = any character, * = any string): OpenElementInCallHierarchyAction_message=&Choose an element (? = any character, * = any string):
OpenElementInCallHierarchyAction_errorNoDefinition=Could not locate definition of element '{0}' OpenElementInCallHierarchyAction_errorNoDefinition=Could not locate definition of element ''{0}''

View file

@ -68,6 +68,7 @@ public class OpenElementInCallHierarchyAction implements IWorkbenchWindowActionD
} }
private void configureDialog(OpenTypeDialog dialog) { private void configureDialog(OpenTypeDialog dialog) {
dialog.setDialogSettings(getClass().getName());
dialog.setVisibleTypes(VISIBLE_TYPES); dialog.setVisibleTypes(VISIBLE_TYPES);
dialog.setTitle(CHMessages.OpenElementInCallHierarchyAction_title); dialog.setTitle(CHMessages.OpenElementInCallHierarchyAction_title);
dialog.setUpperListLabel(CHMessages.OpenElementInCallHierarchyAction_upperListLabel); dialog.setUpperListLabel(CHMessages.OpenElementInCallHierarchyAction_upperListLabel);

View file

@ -68,6 +68,7 @@ public class OpenTypeInHierarchyAction implements IWorkbenchWindowActionDelegate
} }
private void configureDialog(OpenTypeDialog dialog) { private void configureDialog(OpenTypeDialog dialog) {
dialog.setDialogSettings(getClass().getName());
dialog.setVisibleTypes(VISIBLE_TYPES); dialog.setVisibleTypes(VISIBLE_TYPES);
dialog.setTitle(Messages.OpenTypeInHierarchyAction_title); dialog.setTitle(Messages.OpenTypeInHierarchyAction_title);
dialog.setUpperListLabel(Messages.OpenTypeInHierarchyAction_upperListLabel); dialog.setUpperListLabel(Messages.OpenTypeInHierarchyAction_upperListLabel);

View file

@ -56,5 +56,5 @@ OpenTypeInHierarchyAction_title=Open Type in Hierarchy
OpenTypeInHierarchyAction_message=&Choose a type (? = any character, * = any string): OpenTypeInHierarchyAction_message=&Choose a type (? = any character, * = any string):
THInformationControl_regularTitle=Type Hierarchy of {0} THInformationControl_regularTitle=Type Hierarchy of {0}
THInformationControl_showDefiningTypesTitle=Types defining or implementing {0} THInformationControl_showDefiningTypesTitle=Types defining or implementing {0}
OpenTypeInHierarchyAction_errorNoDefinition=Could not locate definition of type '{0}' OpenTypeInHierarchyAction_errorNoDefinition=Could not locate definition of type ''{0}''
OpenTypeInHierarchyAction_upperListLabel=&Matching Types: OpenTypeInHierarchyAction_upperListLabel=&Matching Types: