Class FilterBySubsystemsDialog

  • All Implemented Interfaces:
    org.eclipse.jface.window.IShellProvider

    public class FilterBySubsystemsDialog
    extends org.eclipse.ui.dialogs.SelectionDialog
    Dialog to filter model objects by subsystems.

    It provides two working modes: in 'oneProjectMode' mode the root of the subsystems tree will 'Subsystems' node in the other mode the root of the tree will be project node.

    Also it provides other two working modes: in the first mode (the "includeFromSubordinateSubsystems" or "includeFromParentSubsystems" flag is set) for the checked node its all ancestors and descendants are grayed, so the clients can select only one node at the path from any node to the root of the tree. In the other mode (the "includeFromSubordinateSubsystems" and "includeFromParentSubsystems" flags are not set) the checked nodes do not affect other, so the clients can select any set of subsystems.

    • Nested Class Summary

      • Nested classes/interfaces inherited from class org.eclipse.jface.window.Window

        org.eclipse.jface.window.Window.IExceptionHandler
    • Field Summary

      • Fields inherited from class org.eclipse.jface.dialogs.Dialog

        blockedHandler, buttonBar, DIALOG_DEFAULT_BOUNDS, DIALOG_PERSISTLOCATION, DIALOG_PERSISTSIZE, dialogArea, DLG_IMG_ERROR, DLG_IMG_HELP, DLG_IMG_INFO, DLG_IMG_MESSAGE_ERROR, DLG_IMG_MESSAGE_INFO, DLG_IMG_MESSAGE_WARNING, DLG_IMG_QUESTION, DLG_IMG_WARNING, ELLIPSIS
      • Fields inherited from class org.eclipse.jface.window.Window

        CANCEL, OK, resizeHasOccurred
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      protected void buttonPressed​(int buttonId)  
      boolean close()  
      protected void createButtonsForButtonBar​(org.eclipse.swt.widgets.Composite parent)  
      protected org.eclipse.swt.widgets.Control createDialogArea​(org.eclipse.swt.widgets.Composite parent)  
      protected org.eclipse.swt.graphics.Point getInitialSize()  
      boolean isTurnedOff()
      Checks whether the filter is turned off.
      boolean isTurnedOn()
      Checks whether the filter is turned on.
      protected void okPressed()  
      protected void turnOffPressed()
      Notifies that the turn off button of this dialog has been pressed.
      • Methods inherited from class org.eclipse.ui.dialogs.SelectionDialog

        configureShell, createMessageArea, getDialogBoundsSettings, getDialogBoundsStrategy, getInitialElementSelections, getInitialSelections, getMessage, getOkButton, getResult, isResizable, setDialogBoundsSettings, setInitialElementSelections, setInitialSelections, setMessage, setResult, setSelectionResult, setTitle
      • Methods inherited from class org.eclipse.jface.dialogs.TrayDialog

        closeTray, createButtonBar, createHelpControl, getLayout, getTray, handleShellCloseEvent, isDialogHelpAvailable, isHelpAvailable, openTray, setDialogHelpAvailable, setHelpAvailable
      • Methods inherited from class org.eclipse.jface.dialogs.Dialog

        applyDialogFont, cancelPressed, convertHeightInCharsToPixels, convertHeightInCharsToPixels, convertHorizontalDLUsToPixels, convertHorizontalDLUsToPixels, convertVerticalDLUsToPixels, convertVerticalDLUsToPixels, convertWidthInCharsToPixels, convertWidthInCharsToPixels, create, createButton, createContents, dialogFontIsDefault, getBlockedHandler, getButton, getButtonBar, getCancelButton, getDialogArea, getImage, getInitialLocation, getOKButton, initializeBounds, initializeDialogUnits, setBlockedHandler, setButtonLayoutData, setButtonLayoutFormData, shortenText
      • Methods inherited from class org.eclipse.jface.window.Window

        canHandleShellCloseEvent, constrainShellSize, createShell, getConstrainedShellBounds, getContents, getDefaultImage, getDefaultImages, getDefaultOrientation, getParentShell, getReturnCode, getShell, getShellListener, getShellStyle, getWindowManager, handleFontChange, open, setBlockOnOpen, setDefaultImage, setDefaultImages, setDefaultModalParent, setDefaultOrientation, setExceptionHandler, setParentShell, setReturnCode, setShellStyle, setWindowManager
    • Constructor Detail

      • FilterBySubsystemsDialog

        public FilterBySubsystemsDialog​(org.eclipse.swt.widgets.Shell parentShell,
                                        FilterBySubsystemsSettings filterSettings,
                                        boolean oneProjectMode,
                                        IFilterBySubsystemsManager filterBySubsystemsManager,
                                        IDtProjectManager dtProjectManager)
        Creates a new instance of FilterBySubsystemsDialog.
        Parameters:
        parentShell - the parent shell, can not be null
        filterSettings - the FilterBySubsystemsSettings instance, can not be null
        oneProjectMode - determines the mode of the subsystems tree viewer; if true then the root of the tree will 'Subsystems' node, otherwise the root of the tree will be Project node
        filterBySubsystemsManager - the filter by subsystems manager, can not be null
        dtProjectManager - the DT project manager, cannot be null
    • Method Detail

      • isTurnedOn

        public boolean isTurnedOn()
        Checks whether the filter is turned on.
        Returns:
        true if the filter is turned on and false otherwise
      • isTurnedOff

        public boolean isTurnedOff()
        Checks whether the filter is turned off.
        Returns:
        true if the filter is turned off and false otherwise
      • buttonPressed

        protected void buttonPressed​(int buttonId)
        Overrides:
        buttonPressed in class org.eclipse.jface.dialogs.Dialog
      • createButtonsForButtonBar

        protected void createButtonsForButtonBar​(org.eclipse.swt.widgets.Composite parent)
        Overrides:
        createButtonsForButtonBar in class org.eclipse.ui.dialogs.SelectionDialog
      • createDialogArea

        protected org.eclipse.swt.widgets.Control createDialogArea​(org.eclipse.swt.widgets.Composite parent)
        Overrides:
        createDialogArea in class org.eclipse.jface.dialogs.Dialog
      • okPressed

        protected void okPressed()
        Overrides:
        okPressed in class org.eclipse.jface.dialogs.Dialog
      • close

        public boolean close()
        Overrides:
        close in class org.eclipse.jface.dialogs.Dialog
      • getInitialSize

        protected org.eclipse.swt.graphics.Point getInitialSize()
        Overrides:
        getInitialSize in class org.eclipse.jface.dialogs.Dialog
      • turnOffPressed

        protected void turnOffPressed()
        Notifies that the turn off button of this dialog has been pressed.