1 /*******************************************************************************
2 * Copyright (c) 2000, 2003 IBM Corporation and others.
3 * All rights reserved. This program and the accompanying materials
4 * are made available under the terms of the Common Public License v1.0
5 * which accompanies this distribution, and is available at
6 * http://www.eclipse.org/legal/cpl-v10.html
9 * IBM Corporation - initial API and implementation
10 *******************************************************************************/
11 package net.sourceforge.phpdt.internal.ui.viewsupport;
13 import net.sourceforge.phpdt.ui.actions.MemberFilterActionGroup;
15 import org.eclipse.jface.action.Action;
16 import org.eclipse.ui.help.WorkbenchHelp;
19 * Action used to enable / disable method filter properties
21 public class MemberFilterAction extends Action {
23 private int fFilterProperty;
24 private MemberFilterActionGroup fFilterActionGroup;
26 public MemberFilterAction(MemberFilterActionGroup actionGroup, String title, int property, String contextHelpId, boolean initValue) {
28 fFilterActionGroup= actionGroup;
29 fFilterProperty= property;
31 WorkbenchHelp.setHelp(this, contextHelpId);
33 setChecked(initValue);
37 * Returns this action's filter property.
39 public int getFilterProperty() {
40 return fFilterProperty;
44 * @see Action#actionPerformed
47 fFilterActionGroup.setMemberFilter(fFilterProperty, isChecked());