comparison dwtx/jface/action/StatusLineContributionItem.d @ 72:5df4896124c7

JFace and its examples do compile
author Frank Benoit <benoit@tionex.de>
date Thu, 22 May 2008 17:56:17 +0200
parents 4878bef4a38e
children
comparison
equal deleted inserted replaced
71:4878bef4a38e 72:5df4896124c7
22 import dwt.widgets.Composite; 22 import dwt.widgets.Composite;
23 import dwt.widgets.Label; 23 import dwt.widgets.Label;
24 import dwtx.core.runtime.Assert; 24 import dwtx.core.runtime.Assert;
25 import dwtx.jface.util.Util; 25 import dwtx.jface.util.Util;
26 26
27 import dwtx.jface.action.ContributionItem;
28 import dwtx.jface.action.StatusLineLayoutData;
29 import dwtx.jface.action.IContributionManager;
30
27 import dwt.dwthelper.utils; 31 import dwt.dwthelper.utils;
28 32
29 /** 33 /**
30 * A contribution item to be used with status line managers. 34 * A contribution item to be used with status line managers.
31 * <p> 35 * <p>
47 * will be <code>null</code> if this instance has not yet been 51 * will be <code>null</code> if this instance has not yet been
48 * initialized. 52 * initialized.
49 */ 53 */
50 private Composite statusLine = null; 54 private Composite statusLine = null;
51 55
52 private String text = Util.ZERO_LENGTH_STRING; 56 private String text;
53 57
54 private int widthHint = -1; 58 private int widthHint = -1;
55 59
56 private int heightHint = -1; 60 private int heightHint = -1;
57 61
75 * have no id 79 * have no id
76 * @param charWidth 80 * @param charWidth
77 * the number of characters to display 81 * the number of characters to display
78 */ 82 */
79 public this(String id, int charWidth) { 83 public this(String id, int charWidth) {
84 text = Util.ZERO_LENGTH_STRING;
80 super(id); 85 super(id);
81 this.charWidth = charWidth; 86 this.charWidth = charWidth;
82 setVisible(false); // no text to start with 87 setVisible(false); // no text to start with
83 } 88 }
84 89