CloneSet341


Previous CloneSetNext CloneSetBack to Main Report
Clone
Mass
Clones in
CloneSet
Parameter
Count
Clone
Similarity
Syntax Category
[Sequence Length]
47210.999class_body_declarations[3]
Clone AbstractionParameter Bindings
Clone Instance
(Click to see clone)
Line CountSource Line
Source File
147237
plugins/org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/dialogfields/ListDialogField.java
247193
plugins/org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/dialogfields/TreeListDialogField.java
Clone Instance
1
Line Count
47
Source Line
237
Source File
plugins/org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/dialogfields/ListDialogField.java

        // ------ layout helpers
        /*
         * @see DialogField#doFillIntoGrid
         */
        public Control[] doFillIntoGrid(Composite parent, int nColumns) {
                PixelConverter converter = new PixelConverter(parent);

                assertEnoughColumns(nColumns);

                Label label = getLabelControl(parent);
                GridData gd = gridDataForLabel(1);
                gd.verticalAlignment = GridData.BEGINNING;
                label.setLayoutData(gd);

                Control list = getListControl(parent);
                gd = new GridData();
                gd.horizontalAlignment = GridData.FILL;
                gd.grabExcessHorizontalSpace = false;
                gd.verticalAlignment = GridData.FILL;
                gd.grabExcessVerticalSpace = true;
                gd.horizontalSpan = nColumns - 2;
                gd.widthHint = converter.convertWidthInCharsToPixels(50);
                gd.heightHint = converter.convertHeightInCharsToPixels(6);

                list.setLayoutData(gd);

                Composite buttons = getButtonBox(parent);
                gd = new GridData();
                gd.horizontalAlignment = GridData.FILL;
                gd.grabExcessHorizontalSpace = false;
                gd.verticalAlignment = GridData.FILL;
                gd.grabExcessVerticalSpace = true;
                gd.horizontalSpan = 1;
                buttons.setLayoutData(gd);

                return new Control[] {
                                       label, list, buttons
                                     };
        }

        /*
         * @see DialogField#getNumberOfControls
         */
        public int getNumberOfControls() {
                return 3;
        }

        /**
         * Sets the minimal width of the buttons. Must be called after widget creation.
         */
        public void setButtonsMinWidth(int minWidth) {
                if (fLastSeparator != null) {
                        ((GridData) fLastSeparator.getLayoutData()).widthHint = minWidth;
                }
        }


Clone Instance
2
Line Count
47
Source Line
193
Source File
plugins/org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/dialogfields/TreeListDialogField.java

        // ------ layout helpers
        /*
        * @see DialogField#doFillIntoGrid
        */
        public Control[] doFillIntoGrid(Composite parent, int nColumns) {
                PixelConverter converter = new PixelConverter(parent);

                assertEnoughColumns(nColumns);

                Label label = getLabelControl(parent);
                GridData gd = gridDataForLabel(1);
                gd.verticalAlignment = GridData.BEGINNING;
                label.setLayoutData(gd);

                Control list = getTreeControl(parent);
                gd = new GridData();
                gd.horizontalAlignment = GridData.FILL;
                gd.grabExcessHorizontalSpace = false;
                gd.verticalAlignment = GridData.FILL;
                gd.grabExcessVerticalSpace = true;
                gd.horizontalSpan = nColumns - 2;
                gd.widthHint = converter.convertWidthInCharsToPixels(50);
                gd.heightHint = converter.convertHeightInCharsToPixels(6);

                list.setLayoutData(gd);

                Composite buttons = getButtonBox(parent);
                gd = new GridData();
                gd.horizontalAlignment = GridData.FILL;
                gd.grabExcessHorizontalSpace = false;
                gd.verticalAlignment = GridData.FILL;
                gd.grabExcessVerticalSpace = true;
                gd.horizontalSpan = 1;
                buttons.setLayoutData(gd);

                return new Control[] {
                                       label, list, buttons
                                     };
        }

        /*
        * @see DialogField#getNumberOfControls
        */
        public int getNumberOfControls() {
                return 3;
        }

        /**
        * Sets the minimal width of the buttons. Must be called after widget creation.
        */
        public void setButtonsMinWidth(int minWidth) {
                if (fLastSeparator != null) {
                        ((GridData) fLastSeparator.getLayoutData()).widthHint = minWidth;
                }
        }


Clone AbstractionParameter Count: 1Parameter Bindings

// ------ layout helpers
/*
         * @see DialogField#doFillIntoGrid
         */
/*
        * @see DialogField#doFillIntoGrid
        */
public Control[] doFillIntoGrid(Composite parent, int nColumns) {
  PixelConverter converter = new PixelConverter(parent);
  assertEnoughColumns(nColumns);
  Label label = getLabelControl(parent);
  GridData gd = gridDataForLabel(1);
  gd.verticalAlignment = GridData.BEGINNING;
  label.setLayoutData(gd);
  Control list = [[#variableb9b30440]](parent);
  gd = new GridData();
  gd.horizontalAlignment = GridData.FILL;
  gd.grabExcessHorizontalSpace = false;
  gd.verticalAlignment = GridData.FILL;
  gd.grabExcessVerticalSpace = true;
  gd.horizontalSpan = nColumns - 2;
  gd.widthHint = converter.convertWidthInCharsToPixels(50);
  gd.heightHint = converter.convertHeightInCharsToPixels(6);
  list.setLayoutData(gd);
  Composite buttons = getButtonBox(parent);
  gd = new GridData();
  gd.horizontalAlignment = GridData.FILL;
  gd.grabExcessHorizontalSpace = false;
  gd.verticalAlignment = GridData.FILL;
  gd.grabExcessVerticalSpace = true;
  gd.horizontalSpan = 1;
  buttons.setLayoutData(gd);
  return new Control[] {
                         label,
                         list,
                         buttons
                       };
}

/*
         * @see DialogField#getNumberOfControls
         */
/*
        * @see DialogField#getNumberOfControls
        */
public int getNumberOfControls() {
  return 3;
}

/**
         * Sets the minimal width of the buttons. Must be called after widget creation.
         */
/**
        * Sets the minimal width of the buttons. Must be called after widget creation.
        */
public void setButtonsMinWidth(int minWidth) {
  if (fLastSeparator != null) {
    ((GridData) fLastSeparator.getLayoutData()).widthHint = minWidth;
  }
}
 

CloneAbstraction
Parameter Bindings
Parameter
Index
Clone
Instance
Parameter
Name
Value
11[[#b9b30440]]
getListControl 
12[[#b9b30440]]
getTreeControl