當前位置: 首頁>>代碼示例>>Java>>正文


Java EditingSupport類代碼示例

本文整理匯總了Java中org.eclipse.jface.viewers.EditingSupport的典型用法代碼示例。如果您正苦於以下問題:Java EditingSupport類的具體用法?Java EditingSupport怎麽用?Java EditingSupport使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。


EditingSupport類屬於org.eclipse.jface.viewers包,在下文中一共展示了EditingSupport類的8個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。

示例1: configureKeyTableViewer

import org.eclipse.jface.viewers.EditingSupport; //導入依賴的package包/類
public void configureKeyTableViewer(final EditingSupport editingSupport) {
	final TableViewer keyTableViewer = (TableViewer)editingSupport.getViewer();
	final TableViewerColumn viewerElementColumn = new TableViewerColumn(keyTableViewer, SWT.LEFT);
	final TableColumn elementColumn = viewerElementColumn.getColumn();
	elementColumn.setText("Y-Axis");

	final TableColumnLayout tableColumnLayout = new TableColumnLayout();
	tableColumnLayout.setColumnData(elementColumn, new ColumnWeightData(1, 175));
	viewerElementColumn.setEditingSupport(editingSupport);
	viewerElementColumn.setLabelProvider(createElementLabelProvider());

	final TableViewerColumn viewerValueColumn = new TableViewerColumn(keyTableViewer, SWT.NONE);
	final TableColumn valueColumn = viewerValueColumn.getColumn();
	valueColumn.setText("Value");
	tableColumnLayout.setColumnData(valueColumn, new ColumnWeightData(2, 140));

	viewerValueColumn.setLabelProvider(createValueLabelProvider());

	keyTableViewer.getTable().getParent().setLayout(tableColumnLayout);
	keyTableViewer.getTable().setLinesVisible(true);
	keyTableViewer.getTable().setHeaderVisible(true);
	keyTableViewer.setUseHashlookup(true);
	keyTableViewer.setInput(yAxisTableItems.add(createYAxisTableItem()));
	keyTableViewer.getTable().getItem(yAxisTableItems.size()-1).setChecked(true);
}
 
開發者ID:smaccm,項目名稱:smaccm,代碼行數:26,代碼來源:ChartHelper.java

示例2: initializeColumns

import org.eclipse.jface.viewers.EditingSupport; //導入依賴的package包/類
public static void initializeColumns(final TableViewer tableViewer) {

		EditingSupport[] editing_support = { null, null, null, null, null, new ImportEditingSupport(tableViewer) };

		for (int i = 0; i < TITLES.length; i++) {
			TableViewerColumn col = createTableViewerColumn(tableViewer, i);
			EditingSupport editingSupport = editing_support[i];
			if (editingSupport != null) {
				col.setEditingSupport(editingSupport);
			}
		}
	}
 
開發者ID:scenarioo,項目名稱:scenarioo-example-swtbot-e4,代碼行數:13,代碼來源:OrderSearchTableHelper.java

示例3: initializeColumns

import org.eclipse.jface.viewers.EditingSupport; //導入依賴的package包/類
public static void initializeColumns(final TableViewer tableViewer, final ArticleService articleService,
		final Label posAmountErrorMsg) {

	EditingSupport[] editing_support = { null, null, new ArticleEditingSupport(tableViewer, articleService), null,
			new AmountEditingSupport(tableViewer, posAmountErrorMsg), null };

	for (int i = 0; i < TITLES.length; i++) {
		TableViewerColumn col = createTableViewerColumn(tableViewer, i);
		EditingSupport editingSupport = editing_support[i];
		if (editingSupport != null) {
			col.setEditingSupport(editingSupport);
		}
	}
}
 
開發者ID:scenarioo,項目名稱:scenarioo-example-swtbot-e4,代碼行數:15,代碼來源:PositionsTableHelper.java

示例4: setEditingSupport

import org.eclipse.jface.viewers.EditingSupport; //導入依賴的package包/類
/** {@inheritDoc} */
public void setEditingSupport(EditingSupport editingSupport)
{
    if (editingSupport instanceof CheckEditingSupport)
    {
        if (checkEditingSupport == null)
        {
            final int colIndex = getColumn().getParent().indexOf(getColumn());
            
            getColumn().getParent().addListener(SWT.Selection, new Listener()
            {                
                public void handleEvent(Event event)
                {                         
                    if (event.detail == SWT.CHECK && event.index == colIndex)
                    {
                        GridItem item = (GridItem)event.item;
                        Object element = item.getData();
                        checkEditingSupport.setValue(element, new Boolean(item.getChecked(colIndex)));
                    }
                }                
            });
        }
        checkEditingSupport = (CheckEditingSupport)editingSupport;
    }
    else
    {
        super.setEditingSupport(editingSupport);
    }        
}
 
開發者ID:heartsome,項目名稱:translationstudio8,代碼行數:30,代碼來源:GridViewerColumn.java

示例5: getEditingSupport

import org.eclipse.jface.viewers.EditingSupport; //導入依賴的package包/類
public EditingSupport getEditingSupport() {
	return _editingSupport;
}
 
開發者ID:wolfgang-ch,項目名稱:mytourbook,代碼行數:4,代碼來源:ColumnDefinition.java

示例6: setEditingSupport

import org.eclipse.jface.viewers.EditingSupport; //導入依賴的package包/類
public void setEditingSupport(final EditingSupport editingSupport) {
	_editingSupport = editingSupport;
}
 
開發者ID:wolfgang-ch,項目名稱:mytourbook,代碼行數:4,代碼來源:ColumnDefinition.java

示例7: getEditingSupport

import org.eclipse.jface.viewers.EditingSupport; //導入依賴的package包/類
@Override
public EditingSupport getEditingSupport(ColumnViewer viewer) {
  return new GenericEditingSupport(viewer, this);
}
 
開發者ID:incentivetoken,項目名稱:offspring,代碼行數:5,代碼來源:GenericTableColumn.java

示例8: getEditingSupport

import org.eclipse.jface.viewers.EditingSupport; //導入依賴的package包/類
public EditingSupport getEditingSupport(ColumnViewer viewer); 
開發者ID:incentivetoken,項目名稱:offspring,代碼行數:2,代碼來源:IGenericTableColumn.java


注:本文中的org.eclipse.jface.viewers.EditingSupport類示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。