comparison dwtx/jface/viewers/IViewerLabelProvider.d @ 10:b6c35faf97c8

Viewers
author Frank Benoit <benoit@tionex.de>
date Mon, 31 Mar 2008 00:47:19 +0200
parents
children
comparison
equal deleted inserted replaced
9:6c14e54dfc11 10:b6c35faf97c8
1 /*******************************************************************************
2 * Copyright (c) 2004, 2006 IBM Corporation and others.
3 * All rights reserved. This program and the accompanying materials
4 * are made available under the terms of the Eclipse Public License v1.0
5 * which accompanies this distribution, and is available at
6 * http://www.eclipse.org/legal/epl-v10.html
7 *
8 * Contributors:
9 * IBM Corporation - initial API and implementation
10 * Port to the D programming language:
11 * Frank Benoit <benoit@tionex.de>
12 *******************************************************************************/
13 module dwtx.jface.viewers.IViewerLabelProvider;
14
15 import dwtx.jface.viewers.IBaseLabelProvider;
16 import dwtx.jface.viewers.ViewerLabel;
17
18 /**
19 * Extends <code>IBaseLabelProvider</code> with the methods
20 * to update the label for a given element. The label is represented by a
21 * <code>ViewerLabel</code>.
22 * Unlike <code>ILabelProvider</code>, this allows the text and image to be
23 * set in the same request, rather than via separate requests.
24 * <p>
25 * It also allows the current values for the text and image to be considered by
26 * the label provider, allowing for potential optimizations.
27 * For example, decorating label providers that run in the background can hold off
28 * applying an update to a previously populated label until the decoration is ready,
29 * thereby reducing flicker.
30 * </p>
31 *
32 * @see IDelayedLabelDecorator
33 * @since 3.0
34 */
35 public interface IViewerLabelProvider : IBaseLabelProvider {
36
37 /**
38 * Updates the label for the given element.
39 *
40 * @param label the label to update
41 * @param element the element
42 */
43 public void updateLabel(ViewerLabel label, Object element);
44 }