org.eclipse.cdt.debug.mi.internal.ui.dialogfields
Class CheckedListDialogField

java.lang.Object
  extended by org.eclipse.cdt.debug.mi.internal.ui.dialogfields.DialogField
      extended by org.eclipse.cdt.debug.mi.internal.ui.dialogfields.ListDialogField
          extended by org.eclipse.cdt.debug.mi.internal.ui.dialogfields.CheckedListDialogField

public class CheckedListDialogField
extends ListDialogField

A list with checkboxes and a button bar. Typical buttons are 'Check All' and 'Uncheck All'. List model is independend of widget creation. DialogFields controls are: Label, List and Composite containing buttons.


Constructor Summary
CheckedListDialogField(IListAdapter adapter, java.lang.String[] customButtonLabels, org.eclipse.jface.viewers.ILabelProvider lprovider)
           
 
Method Summary
 void checkAll(boolean state)
          Sets the check state of all elements
 void dialogFieldChanged()
          Programatical invocation of a dialog field change.
 java.util.List getCheckedElements()
          Gets the checked elements.
 org.eclipse.swt.widgets.Control getListControl(org.eclipse.swt.widgets.Composite parent)
          Returns the list control.
 boolean isChecked(java.lang.Object obj)
          Returns true if the element is checked.
 void setCheckAllButtonIndex(int checkButtonIndex)
          Sets the index of the 'check' button in the button label array passed in the constructor.
 void setChecked(java.lang.Object object, boolean state)
          Sets the checked state of an element.
 void setCheckedElements(java.util.List list)
          Sets the checked elements.
 void setCheckedWithoutUpdate(java.lang.Object object, boolean state)
          Sets the checked state of an element. no dialog changed listener informed
 void setUncheckAllButtonIndex(int uncheckButtonIndex)
          Sets the index of the 'uncheck' button in the button label array passed in the constructor.
 
Methods inherited from class org.eclipse.cdt.debug.mi.internal.ui.dialogfields.ListDialogField
addElement, addElements, doFillIntoGrid, enableButton, getButtonBox, getElement, getElements, getNumberOfControls, getSelectedElements, getSize, getTableViewer, insertElementAt, postSetSelection, refresh, removeAllElements, removeElement, removeElements, replaceElement, selectElements, selectFirstElement, setButtonsMinWidth, setDownButtonIndex, setElements, setRemoveButtonIndex, setUpButtonIndex, setViewerSorter
 
Methods inherited from class org.eclipse.cdt.debug.mi.internal.ui.dialogfields.DialogField
createEmptySpace, createEmptySpace, getLabelControl, isEnabled, postSetFocusOnDialogField, setDialogFieldListener, setEnabled, setFocus, setLabelText
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CheckedListDialogField

public CheckedListDialogField(IListAdapter adapter,
                              java.lang.String[] customButtonLabels,
                              org.eclipse.jface.viewers.ILabelProvider lprovider)
Method Detail

setCheckAllButtonIndex

public void setCheckAllButtonIndex(int checkButtonIndex)
Sets the index of the 'check' button in the button label array passed in the constructor. The behaviour of the button marked as the check button will then be handled internally. (enable state, button invocation behaviour)


setUncheckAllButtonIndex

public void setUncheckAllButtonIndex(int uncheckButtonIndex)
Sets the index of the 'uncheck' button in the button label array passed in the constructor. The behaviour of the button marked as the uncheck button will then be handled internally. (enable state, button invocation behaviour)


getListControl

public org.eclipse.swt.widgets.Control getListControl(org.eclipse.swt.widgets.Composite parent)
Description copied from class: ListDialogField
Returns the list control. When called the first time, the control will be created.

Overrides:
getListControl in class ListDialogField

dialogFieldChanged

public void dialogFieldChanged()
Description copied from class: DialogField
Programatical invocation of a dialog field change.

Overrides:
dialogFieldChanged in class ListDialogField

getCheckedElements

public java.util.List getCheckedElements()
Gets the checked elements.


isChecked

public boolean isChecked(java.lang.Object obj)
Returns true if the element is checked.


setCheckedElements

public void setCheckedElements(java.util.List list)
Sets the checked elements.


setChecked

public void setChecked(java.lang.Object object,
                       boolean state)
Sets the checked state of an element.


setCheckedWithoutUpdate

public void setCheckedWithoutUpdate(java.lang.Object object,
                                    boolean state)
Sets the checked state of an element. no dialog changed listener informed


checkAll

public void checkAll(boolean state)
Sets the check state of all elements