# HG changeset patch # User Frank Benoit # Date 1207869865 -7200 # Node ID ea8ff534f622854b27b22a1c5d2d1c2380bebad7 # Parent 4567a6f54939b2b4f2d624b1a7cb8dd8f4b50a5d Fix override and super aliases diff -r 4567a6f54939 -r ea8ff534f622 dwtx/core/commands/Category.d --- a/dwtx/core/commands/Category.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/core/commands/Category.d Fri Apr 11 01:24:25 2008 +0200 @@ -149,7 +149,7 @@ * * @see dwtx.core.commands.common.HandleObject#toString() */ - public String toString() { + public override String toString() { if (string is null) { string = Format( "Category({},{},{},{})", id, name, description, defined ); } @@ -161,7 +161,7 @@ * * @see dwtx.core.commands.common.HandleObject#undefine() */ - public void undefine() { + public override void undefine() { string = null; final bool definedChanged = defined; diff -r 4567a6f54939 -r ea8ff534f622 dwtx/core/commands/Command.d --- a/dwtx/core/commands/Command.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/core/commands/Command.d Fri Apr 11 01:24:25 2008 +0200 @@ -212,7 +212,7 @@ * The state to add; must not be null. * @since 3.2 */ - public void addState(String id, State state) { + public override void addState(String id, State state) { super.addState(id, state); state.setId(id); if ( auto h = cast(IObjectWithState)handler) { @@ -929,7 +929,7 @@ * null. * @since 3.2 */ - public void removeState(String stateId) { + public override void removeState(String stateId) { if ( auto h = cast(IObjectWithState)handler ) { h.removeState(stateId); } @@ -1052,7 +1052,7 @@ * the name and description to null. This also removes all * state and disposes of it. Notification is sent to all listeners. */ - public final void undefine() { + public override final void undefine() { bool enabledChanged = isEnabled(); string = null; diff -r 4567a6f54939 -r ea8ff534f622 dwtx/core/commands/ExecutionEvent.d --- a/dwtx/core/commands/ExecutionEvent.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/core/commands/ExecutionEvent.d Fri Apr 11 01:24:25 2008 +0200 @@ -240,7 +240,7 @@ * * @return The string representation; never null. */ - public final String toString() { + public override final String toString() { String parm; foreach( k, v; parameters ){ parm ~= "{"~k~","~v~"}"; diff -r 4567a6f54939 -r ea8ff534f622 dwtx/core/commands/NamedHandleObjectWithState.d --- a/dwtx/core/commands/NamedHandleObjectWithState.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/core/commands/NamedHandleObjectWithState.d Fri Apr 11 01:24:25 2008 +0200 @@ -72,7 +72,7 @@ states.add(stateId, state); } - public final String getDescription() { + public override final String getDescription() { String description = super.getDescription(); // Trigger a NDE. State descriptionState = getState(INamedHandleStateIds.DESCRIPTION); @@ -86,7 +86,7 @@ return description; } - public final String getName() { + public override final String getName() { String name = super.getName(); // Trigger a NDE, if necessary. State nameState = getState(INamedHandleStateIds.NAME); diff -r 4567a6f54939 -r ea8ff534f622 dwtx/core/commands/ParameterType.d --- a/dwtx/core/commands/ParameterType.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/core/commands/ParameterType.d Fri Apr 11 01:24:25 2008 +0200 @@ -284,7 +284,7 @@ * Makes this parameter type become undefined. Notification is sent to all * listeners. */ - public final void undefine() { + public override final void undefine() { string = null; final bool definedChanged = defined; diff -r 4567a6f54939 -r ea8ff534f622 dwtx/core/commands/Parameterization.d --- a/dwtx/core/commands/Parameterization.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/core/commands/Parameterization.d Fri Apr 11 01:24:25 2008 +0200 @@ -90,7 +90,7 @@ /* (non-Javadoc) * @see java.lang.Object#equals(java.lang.Object) */ - public final bool equals(Object object) { + public override final int opEquals(Object object) { if (this is object) { return true; } diff -r 4567a6f54939 -r ea8ff534f622 dwtx/core/commands/ParameterizedCommand.d --- a/dwtx/core/commands/ParameterizedCommand.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/core/commands/ParameterizedCommand.d Fri Apr 11 01:24:25 2008 +0200 @@ -393,7 +393,7 @@ * * @see java.lang.Object#equals(java.lang.Object) */ - public final bool equals(Object object) { + public override final int opEquals(Object object) { if (this is object) { return true; } diff -r 4567a6f54939 -r ea8ff534f622 dwtx/core/commands/common/CommandException.d --- a/dwtx/core/commands/common/CommandException.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/core/commands/common/CommandException.d Fri Apr 11 01:24:25 2008 +0200 @@ -28,7 +28,7 @@ * This member variable is required here to allow us to compile against JCL * foundation libraries. The value may be null. */ - private Exception cause; +// private Exception cause; /** * Creates a new instance of this class with the specified detail message. @@ -52,7 +52,7 @@ public this(String message, Exception cause) { super(message); // don't pass the cause to super, to allow compilation against JCL Foundation - this.cause = cause; + this.next = cause; } /** @@ -61,8 +61,8 @@ * * @return the cause or null */ - public Exception getCause() { - return cause; + public /+override+/ Exception getCause() { + return next; } } diff -r 4567a6f54939 -r ea8ff534f622 dwtx/core/commands/contexts/Context.d --- a/dwtx/core/commands/contexts/Context.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/core/commands/contexts/Context.d Fri Apr 11 01:24:25 2008 +0200 @@ -268,7 +268,7 @@ * the name, description and parent identifier to null. * Notification is sent to all listeners. */ - public final void undefine() { + public override final void undefine() { string = null; bool definedChanged = defined; diff -r 4567a6f54939 -r ea8ff534f622 dwtx/core/commands/operations/AbstractOperation.d --- a/dwtx/core/commands/operations/AbstractOperation.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/core/commands/operations/AbstractOperation.d Fri Apr 11 01:24:25 2008 +0200 @@ -202,7 +202,7 @@ * * @return The string representation. */ - public String toString() { + public override String toString() { StringBuffer stringBuffer = new StringBuffer(); stringBuffer.append(getLabel()); stringBuffer.append("("); //$NON-NLS-1$ diff -r 4567a6f54939 -r ea8ff534f622 dwtx/core/commands/operations/LinearUndoEnforcer.d --- a/dwtx/core/commands/operations/LinearUndoEnforcer.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/core/commands/operations/LinearUndoEnforcer.d Fri Apr 11 01:24:25 2008 +0200 @@ -45,7 +45,7 @@ * is defined as a request to redo a particular operation even if it is not the most * recently added operation to the redo history. */ - protected IStatus allowLinearRedoViolation(IUndoableOperation operation, + protected override IStatus allowLinearRedoViolation(IUndoableOperation operation, IUndoContext context, IOperationHistory history, IAdaptable uiInfo) { return Status.CANCEL_STATUS; } @@ -55,7 +55,7 @@ * is defined as a request to undo a particular operation even if it is not the most * recently added operation to the undo history. */ - protected IStatus allowLinearUndoViolation(IUndoableOperation operation, + protected override IStatus allowLinearUndoViolation(IUndoableOperation operation, IUndoContext context, IOperationHistory history, IAdaptable uiInfo) { return Status.CANCEL_STATUS; } diff -r 4567a6f54939 -r ea8ff534f622 dwtx/core/commands/operations/ObjectUndoContext.d --- a/dwtx/core/commands/operations/ObjectUndoContext.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/core/commands/operations/ObjectUndoContext.d Fri Apr 11 01:24:25 2008 +0200 @@ -67,7 +67,7 @@ * * @see dwtx.core.commands.operations.IUndoContext#getLabel() */ - public String getLabel() { + public override String getLabel() { if (label !is null) { return label; } @@ -121,7 +121,7 @@ * @see dwtx.core.commands.operations.IUndoContext#matches(IUndoContext * context) */ - public bool matches(IUndoContext context) { + public override bool matches(IUndoContext context) { // Check first for explicit matches that have been assigned. if (children.contains(context)) { return true; diff -r 4567a6f54939 -r ea8ff534f622 dwtx/core/commands/operations/TriggeredOperations.d --- a/dwtx/core/commands/operations/TriggeredOperations.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/core/commands/operations/TriggeredOperations.d Fri Apr 11 01:24:25 2008 +0200 @@ -127,7 +127,7 @@ * @param context * the undo context being removed from the receiver. */ - public void removeContext(IUndoContext context) { + public override void removeContext(IUndoContext context) { bool recompute = false; // first check to see if we are removing the only context of the @@ -168,7 +168,7 @@ * @see dwtx.core.commands.operations.IUndoableOperation#execute(dwtx.core.runtime.IProgressMonitor, * dwtx.core.runtime.IAdaptable) */ - public IStatus execute(IProgressMonitor monitor, IAdaptable info) { + public override IStatus execute(IProgressMonitor monitor, IAdaptable info) { if (triggeringOperation !is null) { history.openOperation(this, IOperationHistory.EXECUTE); try { @@ -194,7 +194,7 @@ * @see dwtx.core.commands.operations.IUndoableOperation#redo(dwtx.core.runtime.IProgressMonitor, * dwtx.core.runtime.IAdaptable) */ - public IStatus redo(IProgressMonitor monitor, IAdaptable info) { + public override IStatus redo(IProgressMonitor monitor, IAdaptable info) { if (triggeringOperation !is null) { history.openOperation(this, IOperationHistory.REDO); Seq!(IUndoableOperation) childrenToRestore = children.dup; @@ -226,7 +226,7 @@ * @see dwtx.core.commands.operations.IUndoableOperation#undo(dwtx.core.runtime.IProgressMonitor, * dwtx.core.runtime.IAdaptable) */ - public IStatus undo(IProgressMonitor monitor, IAdaptable info) { + public override IStatus undo(IProgressMonitor monitor, IAdaptable info) { if (triggeringOperation !is null) { history.openOperation(this, IOperationHistory.UNDO); auto childrenToRestore = children.dup; @@ -257,7 +257,7 @@ * * @see dwtx.core.commands.operations.IUndoableOperation#canUndo() */ - public bool canUndo() { + public override bool canUndo() { if (triggeringOperation !is null) { return triggeringOperation.canUndo(); } @@ -269,7 +269,7 @@ * * @see dwtx.core.commands.operations.IUndoableOperation#canExecute() */ - public bool canExecute() { + public override bool canExecute() { if (triggeringOperation !is null) { return triggeringOperation.canExecute(); } @@ -281,7 +281,7 @@ * * @see dwtx.core.commands.operations.IUndoableOperation#canRedo() */ - public bool canRedo() { + public override bool canRedo() { if (triggeringOperation !is null) { return triggeringOperation.canRedo(); } @@ -291,7 +291,7 @@ /* * Dispose all operations in the receiver. */ - public void dispose() { + public override void dispose() { for (int i = 0; i < children.size(); i++) { children.get(i).dispose(); } @@ -455,7 +455,7 @@ * * @since 3.2 */ - public void addContext(IUndoContext context) { + public override void addContext(IUndoContext context) { if (triggeringOperation !is null) { triggeringOperation.addContext(context); recomputeContexts(); diff -r 4567a6f54939 -r ea8ff534f622 dwtx/core/runtime/MultiStatus.d --- a/dwtx/core/runtime/MultiStatus.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/core/runtime/MultiStatus.d Fri Apr 11 01:24:25 2008 +0200 @@ -108,14 +108,14 @@ /* (Intentionally not javadoc'd) * Implements the corresponding method on IStatus. */ - public IStatus[] getChildren() { + public override IStatus[] getChildren() { return children; } /* (Intentionally not javadoc'd) * Implements the corresponding method on IStatus. */ - public bool isMultiStatus() { + public override bool isMultiStatus() { return true; } @@ -143,7 +143,7 @@ * Returns a string representation of the status, suitable * for debugging purposes only. */ - public String toString() { + public override String toString() { tango.text.Text.Text!(char) buf = new tango.text.Text.Text!(char); buf.append(super.toString()); buf.append(" children=["); //$NON-NLS-1$ diff -r 4567a6f54939 -r ea8ff534f622 dwtx/core/runtime/Path.d --- a/dwtx/core/runtime/Path.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/core/runtime/Path.d Fri Apr 11 01:24:25 2008 +0200 @@ -574,7 +574,7 @@ /* (Intentionally not included in javadoc) * Computes the hash code for this object. */ - public int hashCode() { + public override hash_t toHash() { return separators & HASH_MASK; } @@ -956,7 +956,7 @@ /* (Intentionally not included in javadoc) * @see IPath#toString() */ - public String toString() { + public override String toString() { int resultSize = computeLength(); if (resultSize <= 0) return EMPTY_STRING; diff -r 4567a6f54939 -r ea8ff534f622 dwtx/core/runtime/Status.d --- a/dwtx/core/runtime/Status.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/core/runtime/Status.d Fri Apr 11 01:24:25 2008 +0200 @@ -262,7 +262,7 @@ * Returns a string representation of the status, suitable * for debugging purposes only. */ - public String toString() { + public override String toString() { String sev; if (severity is OK) { sev="OK"; //$NON-NLS-1$ diff -r 4567a6f54939 -r ea8ff534f622 dwtx/core/runtime/SubProgressMonitor.d --- a/dwtx/core/runtime/SubProgressMonitor.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/core/runtime/SubProgressMonitor.d Fri Apr 11 01:24:25 2008 +0200 @@ -117,7 +117,7 @@ * is specified, then the given string will be prepended to * every string passed to subTask(String). */ - public void beginTask(String name, int totalWork) { + public override void beginTask(String name, int totalWork) { nestedBeginTasks++; // Ignore nested begin task calls. if (nestedBeginTasks > 1) { @@ -135,7 +135,7 @@ /* (Intentionally not javadoc'd) * Implements the method IProgressMonitor.done. */ - public void done() { + public override void done() { // Ignore if more done calls than beginTask calls or if we are still // in some nested beginTasks if (nestedBeginTasks is 0 || --nestedBeginTasks > 0) @@ -153,7 +153,7 @@ /* (Intentionally not javadoc'd) * Implements the internal method IProgressMonitor.internalWorked. */ - public void internalWorked(double work) { + public override void internalWorked(double work) { if (usedUp || nestedBeginTasks !is 1) { return; } @@ -169,7 +169,7 @@ /* (Intentionally not javadoc'd) * Implements the method IProgressMonitor.subTask. */ - public void subTask(String name) { + public override void subTask(String name) { if ((style & SUPPRESS_SUBTASK_LABEL) !is 0) { return; } @@ -184,7 +184,7 @@ /* (Intentionally not javadoc'd) * Implements the method IProgressMonitor.worked. */ - public void worked(int work) { + public override void worked(int work) { internalWorked(work); } } diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/action/AbstractGroupMarker.d --- a/dwtx/jface/action/AbstractGroupMarker.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/action/AbstractGroupMarker.d Fri Apr 11 01:24:25 2008 +0200 @@ -56,7 +56,7 @@ * The AbstractGroupMarker implementation of this IContributionItem * method returns true iff the id is not null. Subclasses may override. */ - public bool isGroupMarker() { + public override bool isGroupMarker() { return getId() !is null; } } diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/action/ActionContributionItem.d --- a/dwtx/jface/action/ActionContributionItem.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/action/ActionContributionItem.d Fri Apr 11 01:24:25 2008 +0200 @@ -60,6 +60,7 @@ *

*/ public class ActionContributionItem : ContributionItem { + alias ContributionItem.fill fill; /** * Mode bit: Show text on tool items, even if an image is present. If this @@ -212,7 +213,7 @@ * action's checked property has been set, the button is created and primed * to the value of the checked property. */ - public void fill(Composite parent) { + public override void fill(Composite parent) { if (widget is null && parent !is null) { int flags = DWT.PUSH; if (action !is null) { @@ -259,7 +260,7 @@ * the value of the checked property. If the action's menu creator property * has been set, a cascading submenu is created. */ - public void fill(Menu parent, int index) { + public override void fill(Menu parent, int index) { if (widget is null && parent !is null) { Menu subMenu = null; int flags = DWT.PUSH; @@ -322,7 +323,7 @@ * the value of the checked property. If the action's menu creator property * has been set, a drop-down tool item is created. */ - public void fill(ToolBar parent, int index) { + public override void fill(ToolBar parent, int index) { if (widget is null && parent !is null) { int flags = DWT.PUSH; if (action !is null) { @@ -615,7 +616,7 @@ * method returns true for menu items and false * for everything else. */ - public bool isDynamic() { + public override bool isDynamic() { if (cast(MenuItem)widget ) { // Optimization. Only recreate the item is the check or radio style // has changed. @@ -634,7 +635,7 @@ /* * (non-Javadoc) Method declared on IContributionItem. */ - public bool isEnabled() { + public override bool isEnabled() { return action !is null && action.isEnabled(); } @@ -659,7 +660,7 @@ * by also checking whether the command corresponding to this action is * active. */ - public bool isVisible() { + public override bool isVisible() { return super.isVisible() && isCommandActive(); } @@ -681,7 +682,7 @@ * The action item implementation of this IContributionItem * method calls update(null). */ - public final void update() { + public override final void update() { update(null); } @@ -692,7 +693,7 @@ * the name of the property, or null meaning all * applicable properties */ - public void update(String propertyName) { + public override void update(String propertyName) { if (widget !is null) { // determine what to do bool textChanged = propertyName is null diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/action/ContributionItem.d --- a/dwtx/jface/action/ContributionItem.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/action/ContributionItem.d Fri Apr 11 01:24:25 2008 +0200 @@ -190,7 +190,7 @@ * Returns a string representation of this contribution item * suitable only for debugging. */ - public String toString() { + public override String toString() { return this.classinfo.name ~ "(id=" ~ getId() ~ ")";//$NON-NLS-2$//$NON-NLS-1$ } diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/action/ControlContribution.d --- a/dwtx/jface/action/ControlContribution.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/action/ControlContribution.d Fri Apr 11 01:24:25 2008 +0200 @@ -34,6 +34,7 @@ *

*/ public abstract class ControlContribution : ContributionItem { + alias ContributionItem.fill fill; /** * Creates a control contribution item with the given id. * @@ -79,7 +80,7 @@ * Subclasses must implement createControl rather than * overriding this method. */ - public final void fill(Composite parent) { + public override final void fill(Composite parent) { createControl(parent); } @@ -87,7 +88,7 @@ * The control item implementation of this IContributionItem * method throws an exception since controls cannot be added to menus. */ - public final void fill(Menu parent, int index) { + public override final void fill(Menu parent, int index) { Assert.isTrue(false, "Can't add a control to a menu");//$NON-NLS-1$ } @@ -99,7 +100,7 @@ * Subclasses must implement createControl rather than * overriding this method. */ - public final void fill(ToolBar parent, int index) { + public override final void fill(ToolBar parent, int index) { Control control = createControl(parent); ToolItem ti = new ToolItem(parent, DWT.SEPARATOR, index); ti.setControl(control); diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/action/CoolBarManager.d --- a/dwtx/jface/action/CoolBarManager.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/action/CoolBarManager.d Fri Apr 11 01:24:25 2008 +0200 @@ -54,6 +54,7 @@ */ public class CoolBarManager : ContributionManager, ICoolBarManager { + alias ContributionManager.add add; class ListIterator { @@ -210,7 +211,7 @@ /* (non-Javadoc) * @see dwtx.jface.action.ContributionManager#checkDuplication(dwtx.jface.action.IContributionItem) */ - protected bool allowItem(IContributionItem itemToAdd) { + protected override bool allowItem(IContributionItem itemToAdd) { /* We will allow as many null entries as they like, though there should * be none. */ @@ -502,7 +503,7 @@ * * @see dwtx.jface.action.ContributionManager#itemAdded(dwtx.jface.action.IContributionItem) */ - protected void itemAdded(IContributionItem item) { + protected override void itemAdded(IContributionItem item) { Assert.isNotNull(cast(Object)item); super.itemAdded(item); int insertedAt = indexOf(item); @@ -530,7 +531,7 @@ * * @see dwtx.jface.action.ContributionManager#itemRemoved(dwtx.jface.action.IContributionItem) */ - protected void itemRemoved(IContributionItem item) { + protected override void itemRemoved(IContributionItem item) { Assert.isNotNull(cast(Object)item); super.itemRemoved(item); CoolItem coolItem = findCoolItem(item); diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/action/GroupMarker.d --- a/dwtx/jface/action/GroupMarker.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/action/GroupMarker.d Fri Apr 11 01:24:25 2008 +0200 @@ -43,7 +43,7 @@ * The GroupMarker implementation of this method * returns false since group markers are always invisible. */ - public bool isVisible() { + public override bool isVisible() { return false; } } diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/action/MenuManager.d --- a/dwtx/jface/action/MenuManager.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/action/MenuManager.d Fri Apr 11 01:24:25 2008 +0200 @@ -357,7 +357,7 @@ /* (non-Javadoc) * @see dwtx.jface.action.IContributionManager#getOverrides() */ - public IContributionManagerOverrides getOverrides() { + public override IContributionManagerOverrides getOverrides() { if (overrides is null) { if (parent is null) { overrides = new class IContributionManagerOverrides { @@ -514,7 +514,7 @@ * * @since 3.1 */ - public void markDirty() { + public override void markDirty() { super.markDirty(); // Can't optimize by short-circuiting when the first dirty manager is encountered, // since non-visible children are not even processed. @@ -559,7 +559,7 @@ * @param newOverrides the overrides for the items of this manager * @since 2.0 */ - public void setOverrides(IContributionManagerOverrides newOverrides) { + public override void setOverrides(IContributionManagerOverrides newOverrides) { overrides = newOverrides; super.setOverrides(overrides); } diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/action/Separator.d --- a/dwtx/jface/action/Separator.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/action/Separator.d Fri Apr 11 01:24:25 2008 +0200 @@ -33,6 +33,7 @@ *

*/ public class Separator : AbstractGroupMarker { + alias AbstractGroupMarker.fill fill; /** * Creates a separator which does not start a new group. */ @@ -55,7 +56,7 @@ * Method declared on IContributionItem. * Fills the given menu with a DWT separator MenuItem. */ - public void fill(Menu menu, int index) { + public override void fill(Menu menu, int index) { if (index >= 0) { new MenuItem(menu, DWT.SEPARATOR, index); } else { @@ -67,7 +68,7 @@ * Method declared on IContributionItem. * Fills the given tool bar with a DWT separator ToolItem. */ - public void fill(ToolBar toolbar, int index) { + public override void fill(ToolBar toolbar, int index) { if (index >= 0) { new ToolItem(toolbar, DWT.SEPARATOR, index); } else { @@ -79,7 +80,7 @@ * The Separator implementation of this IContributionItem * method returns true */ - public bool isSeparator() { + public override bool isSeparator() { return true; } } diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/action/StatusLine.d --- a/dwtx/jface/action/StatusLine.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/action/StatusLine.d Fri Apr 11 01:24:25 2008 +0200 @@ -132,7 +132,7 @@ DEFAULT_DATA = new StatusLineLayoutData(); } - public Point computeSize(Composite composite, int wHint, int hHint, + public override Point computeSize(Composite composite, int wHint, int hHint, bool changed) { if (wHint !is DWT.DEFAULT && hHint !is DWT.DEFAULT) { @@ -173,7 +173,7 @@ return new Point(totalWidth, maxHeight); } - public void layout(Composite composite, bool flushCache) { + public override void layout(Composite composite, bool flushCache) { if (composite is null) { return; @@ -521,7 +521,7 @@ /** * Applies the given font to this status line. */ - public void setFont(Font font) { + public override void setFont(Font font) { super.setFont(font); Control[] children = getChildren(); for (int i = 0; i < children.length; i++) { diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/action/SubCoolBarManager.d --- a/dwtx/jface/action/SubCoolBarManager.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/action/SubCoolBarManager.d Fri Apr 11 01:24:25 2008 +0200 @@ -31,6 +31,7 @@ */ public class SubCoolBarManager : SubContributionManager, ICoolBarManager { + alias SubContributionManager.add add; /** * Constructs a new manager. diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/action/SubMenuManager.d --- a/dwtx/jface/action/SubMenuManager.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/action/SubMenuManager.d Fri Apr 11 01:24:25 2008 +0200 @@ -110,7 +110,7 @@ /* (non-Javadoc) * @see dwtx.jface.action.SubContributionManager#disposeManager() */ - public void disposeManager() { + public override void disposeManager() { if (menuListener !is null) { getParentMenuManager().removeMenuListener(menuListener); menuListener = null; @@ -187,7 +187,7 @@ * In the case of menu's not added by this manager, * ensure that we return a wrapper for the menu. */ - public IContributionItem find(String id) { + public override IContributionItem find(String id) { IContributionItem item = getParentMenuManager().find(id); if (cast(SubContributionItem)item ) { // Return the item passed to us, not the wrapper. @@ -319,7 +319,7 @@ /** * Remove all contribution items. */ - public void removeAll() { + public override void removeAll() { super.removeAll(); if (mapMenuToWrapper !is null) { foreach( v; mapMenuToWrapper.elements() ){ @@ -363,7 +363,7 @@ /* (non-Javadoc) * @see dwtx.jface.action.SubContributionManager#setVisible(bool) */ - public void setVisible(bool visible) { + public override void setVisible(bool visible) { super.setVisible(visible); if (mapMenuToWrapper !is null) { foreach( v; mapMenuToWrapper.elements() ){ diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/action/SubStatusLineManager.d --- a/dwtx/jface/action/SubStatusLineManager.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/action/SubStatusLineManager.d Fri Apr 11 01:24:25 2008 +0200 @@ -137,7 +137,7 @@ /* (non-Javadoc) * Method declared on SubContributionManager. */ - public void setVisible(bool visible) { + public override void setVisible(bool visible) { super.setVisible(visible); if (visible) { getParentStatusLineManager().setErrorMessage(errorImage, diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/action/ToolBarContributionItem.d --- a/dwtx/jface/action/ToolBarContributionItem.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/action/ToolBarContributionItem.d Fri Apr 11 01:24:25 2008 +0200 @@ -61,6 +61,8 @@ * @since 3.0 */ public class ToolBarContributionItem : ContributionItem, IToolBarContributionItem { + alias ContributionItem.fill fill; + alias ContributionItem.update update; public IContributionManager getParent() { return super.getParent(); @@ -174,7 +176,7 @@ * * @see dwtx.jface.action.IContributionItem#dispose() */ - public void dispose() { + public override void dispose() { // Dispose of the ToolBar and all its contributions if (toolBarManager !is null) { toolBarManager.dispose(); @@ -200,7 +202,7 @@ * @see dwtx.jface.action.IContributionItem#fill(dwt.widgets.CoolBar, * int) */ - public void fill(CoolBar coolBar, int index) { + public override void fill(CoolBar coolBar, int index) { if (checkDisposed()) { return; } @@ -461,7 +463,7 @@ * other than group marks and separators, and the internal state is * set to be visible. */ - public bool isVisible() { + public override bool isVisible() { if (checkDisposed()) { return false; } @@ -487,7 +489,7 @@ * * @see dwtx.jface.action.IContributionItem#saveWidgetState() */ - public void saveWidgetState() { + public override void saveWidgetState() { if (checkDisposed()) { return; } @@ -598,7 +600,7 @@ * * @see dwtx.jface.action.IContributionItem#update(java.lang.String) */ - public void update(String propertyName) { + public override void update(String propertyName) { if (checkDisposed()) { return; } diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/bindings/Scheme.d --- a/dwtx/jface/bindings/Scheme.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/bindings/Scheme.d Fri Apr 11 01:24:25 2008 +0200 @@ -249,7 +249,7 @@ * * @return The string representation; never null. */ - public final String toString() { + public override final String toString() { if (string is null) { string = Format("Scheme({},{},{},{},{})",id,name,description,parentId,defined); } @@ -261,7 +261,7 @@ * the name, description and parent identifier to null. * Notification is sent to all listeners. */ - public final void undefine() { + public override final void undefine() { string = null; bool definedChanged = defined; diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/bindings/keys/KeyBinding.d --- a/dwtx/jface/bindings/keys/KeyBinding.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/bindings/keys/KeyBinding.d Fri Apr 11 01:24:25 2008 +0200 @@ -106,7 +106,7 @@ * * @see dwtx.jface.bindings.Binding#getTriggerSequence() */ - public TriggerSequence getTriggerSequence() { + public override TriggerSequence getTriggerSequence() { return getKeySequence(); } } diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/bindings/keys/KeySequence.d --- a/dwtx/jface/bindings/keys/KeySequence.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/bindings/keys/KeySequence.d Fri Apr 11 01:24:25 2008 +0200 @@ -227,7 +227,7 @@ * @return A string representation for this key sequence using the default * look; never null. */ - public final String format() { + public override final String format() { return KeyFormatterFactory.getDefault().format(this); } @@ -251,7 +251,7 @@ * * @see dwtx.jface.bindings.TriggerSequence#getPrefixes() */ - public final TriggerSequence[] getPrefixes() { + public override final TriggerSequence[] getPrefixes() { int numberOfPrefixes = triggers.length; TriggerSequence[] prefixes = new TriggerSequence[numberOfPrefixes]; prefixes[0] = KeySequence.getInstance(); @@ -288,7 +288,7 @@ * Guaranteed not to be null. * @see java.lang.Object#toString() */ - public final String toString() { + public override final String toString() { return KeyFormatterFactory.getFormalKeyFormatter().format(this); } } diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/bindings/keys/formatting/EmacsKeyFormatter.d --- a/dwtx/jface/bindings/keys/formatting/EmacsKeyFormatter.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/bindings/keys/formatting/EmacsKeyFormatter.d Fri Apr 11 01:24:25 2008 +0200 @@ -33,6 +33,7 @@ * @since 3.1 */ public final class EmacsKeyFormatter : AbstractKeyFormatter { + alias AbstractKeyFormatter.format format; /** * The resource bundle used by format() to translate formal @@ -52,7 +53,7 @@ * The key to format; must not be null. * @return The key formatted as a string; should not be null. */ - public String format(int key) { + public override String format(int key) { IKeyLookup lookup = KeyLookupFactory.getDefault(); if (lookup.isModifierKey(key)) { String formattedName = Util.translateString(RESOURCE_BUNDLE, lookup @@ -70,7 +71,7 @@ * * @see dwtx.jface.bindings.keys.AbstractKeyFormatter#getKeyDelimiter() */ - protected String getKeyDelimiter() { + protected override String getKeyDelimiter() { return Util.translateString(RESOURCE_BUNDLE, KEY_DELIMITER_KEY, KeyStroke.KEY_DELIMITER); } @@ -80,7 +81,7 @@ * * @see dwtx.jface.bindings.keys.AbstractKeyFormatter#getKeyStrokeDelimiter() */ - protected String getKeyStrokeDelimiter() { + protected override String getKeyStrokeDelimiter() { return Util.translateString(RESOURCE_BUNDLE, KEY_STROKE_DELIMITER_KEY, KeySequence.KEY_STROKE_DELIMITER); } @@ -90,7 +91,7 @@ * * @see dwtx.jface.bindings.keys.AbstractKeyFormatter#sortModifierKeys(int) */ - protected int[] sortModifierKeys(int modifierKeys) { + protected override int[] sortModifierKeys(int modifierKeys) { IKeyLookup lookup = KeyLookupFactory.getDefault(); int[] sortedKeys = new int[4]; int index = 0; diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/bindings/keys/formatting/FormalKeyFormatter.d --- a/dwtx/jface/bindings/keys/formatting/FormalKeyFormatter.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/bindings/keys/formatting/FormalKeyFormatter.d Fri Apr 11 01:24:25 2008 +0200 @@ -31,13 +31,14 @@ * @since 3.1 */ public final class FormalKeyFormatter : AbstractKeyFormatter { + alias AbstractKeyFormatter.format format; /* * (non-Javadoc) * * @see dwtx.jface.bindings.keys.KeyFormatter#format(dwtx.ui.keys.KeySequence) */ - public String format(int key) { + public override String format(int key) { IKeyLookup lookup = KeyLookupFactory.getDefault(); return lookup.formalNameLookup(key); } @@ -47,7 +48,7 @@ * * @see dwtx.jface.bindings.keys.AbstractKeyFormatter#getKeyDelimiter() */ - protected String getKeyDelimiter() { + protected override String getKeyDelimiter() { return KeyStroke.KEY_DELIMITER; } @@ -56,7 +57,7 @@ * * @see dwtx.jface.bindings.keys.AbstractKeyFormatter#getKeyStrokeDelimiter() */ - protected String getKeyStrokeDelimiter() { + protected override String getKeyStrokeDelimiter() { return KeySequence.KEY_STROKE_DELIMITER; } @@ -65,7 +66,7 @@ * * @see dwtx.jface.bindings.keys.AbstractKeyFormatter#sortModifierKeys(int) */ - protected int[] sortModifierKeys(int modifierKeys) { + protected override int[] sortModifierKeys(int modifierKeys) { IKeyLookup lookup = KeyLookupFactory.getDefault(); int[] sortedKeys = new int[4]; int index = 0; diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/bindings/keys/formatting/NativeKeyFormatter.d --- a/dwtx/jface/bindings/keys/formatting/NativeKeyFormatter.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/bindings/keys/formatting/NativeKeyFormatter.d Fri Apr 11 01:24:25 2008 +0200 @@ -37,6 +37,7 @@ * @since 3.1 */ public final class NativeKeyFormatter : AbstractKeyFormatter { + alias AbstractKeyFormatter.format format; /** * The key into the internationalization resource bundle for the delimiter @@ -98,7 +99,7 @@ * The key to format. * @return The key formatted as a string; should not be null. */ - public final String format(int key) { + public override final String format(int key) { IKeyLookup lookup = KeyLookupFactory.getDefault(); String name = lookup.formalNameLookup(key); @@ -118,7 +119,7 @@ * * @see dwtx.jface.bindings.keys.AbstractKeyFormatter#getKeyDelimiter() */ - protected String getKeyDelimiter() { + protected override String getKeyDelimiter() { // We must do the look up every time, as our locale might change. if ("carbon".equals(DWT.getPlatform())) { //$NON-NLS-1$ return Util.translateString(RESOURCE_BUNDLE, @@ -134,7 +135,7 @@ * * @see dwtx.jface.bindings.keys.AbstractKeyFormatter#getKeyStrokeDelimiter() */ - protected String getKeyStrokeDelimiter() { + protected override String getKeyStrokeDelimiter() { // We must do the look up every time, as our locale might change. if ("win32".equals(DWT.getPlatform())) { //$NON-NLS-1$ return Util.translateString(RESOURCE_BUNDLE, @@ -151,7 +152,7 @@ * * @see dwtx.jface.bindings.keys.AbstractKeyFormatter#sortModifierKeys(int) */ - protected int[] sortModifierKeys(int modifierKeys) { + protected override int[] sortModifierKeys(int modifierKeys) { IKeyLookup lookup = KeyLookupFactory.getDefault(); String platform = DWT.getPlatform(); int[] sortedKeys = new int[4]; diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/commands/ActionHandler.d --- a/dwtx/jface/commands/ActionHandler.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/commands/ActionHandler.d Fri Apr 11 01:24:25 2008 +0200 @@ -62,7 +62,7 @@ this.action = action; } - public final void addHandlerListener(IHandlerListener handlerListener) { + public override final void addHandlerListener(IHandlerListener handlerListener) { if (!hasListeners()) { attachListener(); } @@ -106,7 +106,7 @@ * * @see dwtx.core.commands.IHandler#dispose() */ - public final void dispose() { + public override final void dispose() { if (hasListeners()) { action.removePropertyChangeListener(propertyChangeListener); } @@ -141,15 +141,15 @@ return action; } - public final bool isEnabled() { + public override final bool isEnabled() { return action.isEnabled(); } - public final bool isHandled() { + public override final bool isHandled() { return action.isHandled(); } - public final void removeHandlerListener( + public override final void removeHandlerListener( IHandlerListener handlerListener) { super.removeHandlerListener(handlerListener); @@ -158,7 +158,7 @@ } } - public final String toString() { + public override final String toString() { return "ActionHandler(" ~ (cast(Object)action).toString ~ ")"; } } diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/commands/RadioState.d --- a/dwtx/jface/commands/RadioState.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/commands/RadioState.d Fri Apr 11 01:24:25 2008 +0200 @@ -226,7 +226,7 @@ /** * Unregisters this state from the manager, which detaches the listeners. */ - public void dispose() { + public override void dispose() { setRadioGroupIdentifier(null); } @@ -256,7 +256,7 @@ * @param value * The new value; should be a bool. */ - public void setValue(Object value) { + public override void setValue(Object value) { if (!( cast(ValueWrapperBool)value )) { throw new IllegalArgumentException( "RadioState takes a bool as a value"); //$NON-NLS-1$ diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/commands/ToggleState.d --- a/dwtx/jface/commands/ToggleState.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/commands/ToggleState.d Fri Apr 11 01:24:25 2008 +0200 @@ -45,7 +45,7 @@ setValue(new ValueWrapperBool(false)); } - public final void load(IPreferenceStore store, + public override final void load(IPreferenceStore store, String preferenceKey) { bool currentValue = (cast(ValueWrapperBool) getValue()).value; store.setDefault(preferenceKey, currentValue); @@ -55,7 +55,7 @@ } } - public final void save(IPreferenceStore store, + public override final void save(IPreferenceStore store, String preferenceKey) { if (shouldPersist()) { Object value = getValue(); @@ -65,7 +65,7 @@ } } - public void setValue(Object value) { + public override void setValue(Object value) { if (!(cast(ValueWrapperBool)value)) { throw new IllegalArgumentException( "ToggleState takes a bool as a value"); //$NON-NLS-1$ diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/dialogs/Dialog.d --- a/dwtx/jface/dialogs/Dialog.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/dialogs/Dialog.d Fri Apr 11 01:24:25 2008 +0200 @@ -700,7 +700,7 @@ /* * @see Window.initializeBounds() */ - protected void initializeBounds() { + protected override void initializeBounds() { String platform = DWT.getPlatform(); if ("carbon".equals(platform)) { //$NON-NLS-1$ // On Mac OS X the default button must be the right-most button @@ -747,7 +747,7 @@ * createButtonBar are recommended rather than overriding * this method. */ - protected Control createContents(Composite parent) { + protected override Control createContents(Composite parent) { // create the top level composite for the dialog Composite composite = new Composite(parent, 0); GridLayout layout = new GridLayout(); @@ -974,7 +974,7 @@ /** * @see dwtx.jface.window.Window#close() */ - public bool close() { + public override bool close() { if (getShell() !is null && !getShell().isDisposed()) { saveDialogBounds(getShell()); } @@ -1088,7 +1088,7 @@ * * @see dwtx.jface.window.Window#create() */ - public void create() { + public override void create() { super.create(); applyDialogFont(buttonBar); } @@ -1195,7 +1195,7 @@ * @see #getDialogBoundsSettings() * @see #getDialogBoundsStrategy() */ - protected Point getInitialSize() { + protected override Point getInitialSize() { Point result = super.getInitialSize(); // Check the dialog settings for a stored size. @@ -1255,7 +1255,7 @@ * @see #getDialogBoundsSettings() * @see #getDialogBoundsStrategy() */ - protected Point getInitialLocation(Point initialSize) { + protected override Point getInitialLocation(Point initialSize) { Point result = super.getInitialLocation(initialSize); if ((getDialogBoundsStrategy() & DIALOG_PERSISTLOCATION)!is 0) { IDialogSettings settings = getDialogBoundsSettings(); diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/dialogs/ErrorDialog.d --- a/dwtx/jface/dialogs/ErrorDialog.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/dialogs/ErrorDialog.d Fri Apr 11 01:24:25 2008 +0200 @@ -156,7 +156,7 @@ * of the error details area. Note that the Details button will only be * visible if the error being displayed specifies child details. */ - protected void buttonPressed(int id) { + protected override void buttonPressed(int id) { if (id is IDialogConstants.DETAILS_ID) { // was the details button pressed? toggleDetailsArea(); @@ -168,7 +168,7 @@ /* * (non-Javadoc) Method declared in Window. */ - protected void configureShell(Shell shell) { + protected override void configureShell(Shell shell) { super.configureShell(shell); shell.setText(title); } @@ -178,7 +178,7 @@ * * @see dwtx.jface.dialogs.Dialog#createButtonsForButtonBar(dwt.widgets.Composite) */ - protected void createButtonsForButtonBar(Composite parent) { + protected override void createButtonsForButtonBar(Composite parent) { // create OK and Details buttons createButton(parent, IDialogConstants.OK_ID, IDialogConstants.OK_LABEL, true); @@ -233,7 +233,7 @@ * may either override this method, or call the super * implementation and add controls to the created composite. */ - protected Control createDialogArea(Composite parent) { + protected override Control createDialogArea(Composite parent) { createMessageArea(parent); createSupportArea(parent); // create a composite with standard margins and spacing @@ -256,7 +256,7 @@ /* * @see IconAndMessageDialog#createDialogAndButtonArea(Composite) */ - protected void createDialogAndButtonArea(Composite parent) { + protected override void createDialogAndButtonArea(Composite parent) { super.createDialogAndButtonArea(parent); if ( auto dialogComposite = cast(Composite)this.dialogArea ) { // Create a label if there are no children to force a smaller layout @@ -271,7 +271,7 @@ * * @see dwtx.jface.dialogs.IconAndMessageDialog#getImage() */ - protected Image getImage() { + protected override Image getImage() { if (status !is null) { if (status.getSeverity() is IStatus.WARNING) { return getWarningImage(); @@ -336,7 +336,7 @@ * children, the error dialog will only be displayed if there is at least * one child status matching the mask. */ - public int open() { + public override int open() { if (!AUTOMATED_MODE && shouldDisplay(status, displayMask)) { return super.open(); } @@ -604,7 +604,7 @@ * * @see dwtx.jface.window.Window#close() */ - public bool close() { + public override bool close() { if (clipboard !is null) { clipboard.dispose(); } @@ -676,7 +676,7 @@ /* (non-Javadoc) * @see dwtx.jface.dialogs.IconAndMessageDialog#getColumnCount() */ - int getColumnCount() { + override int getColumnCount() { if (Policy.getErrorSupportProvider() is null) return 2; return 3; diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/dialogs/IconAndMessageDialog.d --- a/dwtx/jface/dialogs/IconAndMessageDialog.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/dialogs/IconAndMessageDialog.d Fri Apr 11 01:24:25 2008 +0200 @@ -162,7 +162,7 @@ /* * @see Dialog.createButtonBar() */ - protected Control createButtonBar(Composite parent) { + protected override Control createButtonBar(Composite parent) { Composite composite = new Composite(parent, DWT.NONE); GridLayoutFactory.fillDefaults().numColumns(0) // this is incremented // by createButton @@ -190,7 +190,7 @@ /* * @see Dialog.createContents(Composite) */ - protected Control createContents(Composite parent) { + protected override Control createContents(Composite parent) { // initialize the dialog units initializeDialogUnits(parent); Point defaultMargins = LayoutConstants.getMargins(); diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/dialogs/ImageAndMessageArea.d --- a/dwtx/jface/dialogs/ImageAndMessageArea.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/dialogs/ImageAndMessageArea.d Fri Apr 11 01:24:25 2008 +0200 @@ -148,7 +148,7 @@ * * @see dwt.widgets.Control#setBackground(dwt.graphics.Color) */ - public void setBackground(Color bg) { + public override void setBackground(Color bg) { super.setBackground(bg); messageField.getLayoutControl().setBackground(bg); messageField.getControl().setBackground(bg); @@ -202,7 +202,7 @@ * * @see dwt.widgets.Control#setFont(dwt.graphics.Font) */ - public void setFont(Font font) { + public override void setFont(Font font) { super.setFont(font); (cast(Text) messageField.getControl()).setFont(font); } @@ -212,7 +212,7 @@ * * @see dwt.widgets.Control#setToolTipText(java.lang.String) */ - public void setToolTipText(String text) { + public override void setToolTipText(String text) { super.setToolTipText(text); (cast(Text) messageField.getControl()).setToolTipText(text); } diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/dialogs/InputDialog.d --- a/dwtx/jface/dialogs/InputDialog.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/dialogs/InputDialog.d Fri Apr 11 01:24:25 2008 +0200 @@ -114,7 +114,7 @@ /* * (non-Javadoc) Method declared on Dialog. */ - protected void buttonPressed(int buttonId) { + protected override void buttonPressed(int buttonId) { if (buttonId is IDialogConstants.OK_ID) { value = text.getText(); } else { @@ -128,7 +128,7 @@ * * @see dwtx.jface.window.Window#configureShell(dwt.widgets.Shell) */ - protected void configureShell(Shell shell) { + protected override void configureShell(Shell shell) { super.configureShell(shell); if (title !is null) { shell.setText(title); @@ -140,7 +140,7 @@ * * @see dwtx.jface.dialogs.Dialog#createButtonsForButtonBar(dwt.widgets.Composite) */ - protected void createButtonsForButtonBar(Composite parent) { + protected override void createButtonsForButtonBar(Composite parent) { // create OK and Cancel buttons by default okButton = createButton(parent, IDialogConstants.OK_ID, IDialogConstants.OK_LABEL, true); @@ -158,7 +158,7 @@ /* * (non-Javadoc) Method declared on Dialog. */ - protected Control createDialogArea(Composite parent) { + protected override Control createDialogArea(Composite parent) { // create composite Composite composite = cast(Composite) super.createDialogArea(parent); // create message diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/dialogs/MessageDialog.d --- a/dwtx/jface/dialogs/MessageDialog.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/dialogs/MessageDialog.d Fri Apr 11 01:24:25 2008 +0200 @@ -169,7 +169,7 @@ * (non-Javadoc) * @see dwtx.jface.dialogs.Dialog#buttonPressed(int) */ - protected void buttonPressed(int buttonId) { + protected override void buttonPressed(int buttonId) { setReturnCode(buttonId); close(); } @@ -178,7 +178,7 @@ * (non-Javadoc) * @see dwtx.jface.window.Window#configureShell(dwt.widgets.Shell) */ - protected void configureShell(Shell shell) { + protected override void configureShell(Shell shell) { super.configureShell(shell); if (title !is null) { shell.setText(title); @@ -191,7 +191,7 @@ /* * (non-Javadoc) Method declared on Dialog. */ - protected void createButtonsForButtonBar(Composite parent) { + protected override void createButtonsForButtonBar(Composite parent) { buttons = new Button[buttonLabels.length]; for (int i = 0; i < buttonLabels.length; i++) { String label = buttonLabels[i]; @@ -224,7 +224,7 @@ * override createCustomArea to add contents below the * message. */ - protected Control createDialogArea(Composite parent) { + protected override Control createDialogArea(Composite parent) { // create message area createMessageArea(parent); // create the top level composite for the dialog area @@ -252,7 +252,7 @@ * the index of the button in the dialog's button bar * @return a button in the dialog's button bar */ - protected Button getButton(int index) { + protected override Button getButton(int index) { return buttons[index]; } @@ -275,7 +275,7 @@ * * @see dwtx.jface.window.Window#handleShellCloseEvent() */ - protected void handleShellCloseEvent() { + protected override void handleShellCloseEvent() { //Sets a return code of DWT.DEFAULT since none of the dialog buttons // were pressed to close the dialog. super.handleShellCloseEvent(); @@ -406,7 +406,7 @@ * @see dwtx.jface.dialogs.Dialog#createButton(dwt.widgets.Composite, * int, java.lang.String, bool) */ - protected Button createButton(Composite parent, int id, String label, + protected override Button createButton(Composite parent, int id, String label, bool defaultButton) { Button button = super.createButton(parent, id, label, defaultButton); //Be sure to set the focus if the custom area cannot so as not @@ -439,7 +439,7 @@ * (non-Javadoc) * @see dwtx.jface.dialogs.IconAndMessageDialog#getImage() */ - public Image getImage() { + public override Image getImage() { return image; } diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/dialogs/MessageDialogWithToggle.d --- a/dwtx/jface/dialogs/MessageDialogWithToggle.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/dialogs/MessageDialogWithToggle.d Fri Apr 11 01:24:25 2008 +0200 @@ -401,7 +401,7 @@ /** * @see dwtx.jface.dialogs.Dialog#buttonPressed(int) */ - protected void buttonPressed(int buttonId) { + protected override void buttonPressed(int buttonId) { super.buttonPressed(buttonId); if (buttonId !is IDialogConstants.CANCEL_ID && toggleState @@ -424,7 +424,7 @@ /** * @see Dialog#createButtonBar(Composite) */ - protected void createButtonsForButtonBar(Composite parent) { + protected override void createButtonsForButtonBar(Composite parent) { String[] buttonLabels = getButtonLabels(); Button[] buttons = new Button[buttonLabels.length]; int defaultButtonIndex = getDefaultButtonIndex(); @@ -452,7 +452,7 @@ /** * @see Dialog#createDialogArea(Composite) */ - protected Control createDialogArea(Composite parent) { + protected override Control createDialogArea(Composite parent) { Composite dialogAreaComposite = cast(Composite) super .createDialogArea(parent); setToggleButton(createToggleButton(dialogAreaComposite)); diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/dialogs/PopupDialog.d --- a/dwtx/jface/dialogs/PopupDialog.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/dialogs/PopupDialog.d Fri Apr 11 01:24:25 2008 +0200 @@ -127,7 +127,7 @@ * * @see dwtx.jface.action.IAction#run() */ - public void run() { + public override void run() { performTrackerAction(DWT.NONE); } @@ -146,7 +146,7 @@ /* * @see dwtx.jface.action.Action#run() */ - public void run() { + public override void run() { performTrackerAction(DWT.RESIZE); } } @@ -168,7 +168,7 @@ * * @see dwtx.jface.action.IAction#run() */ - public void run() { + public override void run() { persistBounds = isChecked(); } } @@ -372,7 +372,7 @@ * * @see dwtx.jface.window.Window#configureShell(Shell) */ - protected void configureShell(Shell shell) { + protected override void configureShell(Shell shell) { Display display = shell.getDisplay(); shell.setBackground(display.getSystemColor(DWT.COLOR_BLACK)); @@ -456,7 +456,7 @@ * * @return the control representing the contents. */ - protected Control createContents(Composite parent) { + protected override Control createContents(Composite parent) { Composite composite = new Composite(parent, DWT.NONE); POPUP_LAYOUT_FACTORY.applyTo(composite); LAYOUTDATA_GRAB_BOTH.applyTo(composite); @@ -858,7 +858,7 @@ * * @see dwtx.jface.window.Window#open() */ - public int open() { + public override int open() { Shell shell = getShell(); if (shell is null || shell.isDisposed()) { @@ -907,7 +907,7 @@ * @return true if the window is (or was already) closed, and * false if it is still open */ - public bool close() { + public override bool close() { // If already closed, there is nothing to do. // See https://bugs.eclipse.org/bugs/show_bug.cgi?id=127505 if (getShell() is null || getShell().isDisposed()) { @@ -985,7 +985,7 @@ * * @see dwtx.jface.window.Window#getInitialSize() */ - protected Point getInitialSize() { + protected override Point getInitialSize() { Point result = super.getInitialSize(); if (persistBounds) { IDialogSettings settings = getDialogSettings(); @@ -1021,7 +1021,7 @@ * * @see dwtx.jface.window.Window#getInitialLocation(dwt.graphics.Point) */ - protected Point getInitialLocation(Point initialSize) { + protected override Point getInitialLocation(Point initialSize) { Point result = super.getInitialLocation(initialSize); if (persistBounds) { IDialogSettings settings = getDialogSettings(); diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/dialogs/ProgressMonitorDialog.d --- a/dwtx/jface/dialogs/ProgressMonitorDialog.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/dialogs/ProgressMonitorDialog.d Fri Apr 11 01:24:25 2008 +0200 @@ -340,7 +340,7 @@ * * @since 3.0 */ - protected void cancelPressed() { + protected override void cancelPressed() { // NOTE: this was previously done from a listener installed on the // cancel button. On GTK, the listener installed by // Dialog.createButton is called first and this was throwing an @@ -357,7 +357,7 @@ * The ProgressMonitorDialog implementation of this method * only closes the dialog if there are no currently running runnables. */ - public bool close() { + public override bool close() { if (getNestingDepth() <= 0) { clearCursors(); return super.close(); @@ -391,7 +391,7 @@ /* * (non-Javadoc) Method declared in Window. */ - protected void configureShell(Shell shell) { + protected override void configureShell(Shell shell) { super.configureShell(shell); shell.setText(JFaceResources.getString("ProgressMonitorDialog.title")); //$NON-NLS-1$ if (waitCursor is null) { @@ -418,7 +418,7 @@ /* * (non-Javadoc) Method declared on Dialog. */ - protected void createButtonsForButtonBar(Composite parent) { + protected override void createButtonsForButtonBar(Composite parent) { // cancel button createCancelButton(parent); } @@ -443,7 +443,7 @@ /* * (non-Javadoc) Method declared on Dialog. */ - protected Control createDialogArea(Composite parent) { + protected override Control createDialogArea(Composite parent) { setMessage(DEFAULT_TASKNAME, false); createMessageArea(parent); // Only set for backwards compatibility @@ -471,7 +471,7 @@ * * @see dwtx.jface.window.Window#getInitialSize() */ - protected Point getInitialSize() { + protected override Point getInitialSize() { Point calculatedSize = super.getInitialSize(); if (calculatedSize.x < 450) { calculatedSize.x = 450; @@ -631,7 +631,7 @@ * * @see dwtx.jface.dialogs.IconAndMessageDialog#getImage() */ - protected Image getImage() { + protected override Image getImage() { return getInfoImage(); } @@ -670,7 +670,7 @@ * * @see dwtx.jface.window.Window#open() */ - public int open() { + public override int open() { // Check to be sure it is not already done. If it is just return OK. if (!getOpenOnRun()) { if (getNestingDepth() is 0) { diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/dialogs/StatusDialog.d --- a/dwtx/jface/dialogs/StatusDialog.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/dialogs/StatusDialog.d Fri Apr 11 01:24:25 2008 +0200 @@ -197,7 +197,7 @@ /* * @see Window#create(Shell) */ - protected void configureShell(Shell shell) { + protected override void configureShell(Shell shell) { super.configureShell(shell); if (fTitle !is null) { shell.setText(fTitle); @@ -207,7 +207,7 @@ /* * @see Window#create() */ - public void create() { + public override void create() { super.create(); if (fLastStatus !is null) { // policy: dialogs are not allowed to come up with an error message @@ -224,7 +224,7 @@ /* * @see Dialog#createButtonsForButtonBar(Composite) */ - protected void createButtonsForButtonBar(Composite parent) { + protected override void createButtonsForButtonBar(Composite parent) { fOkButton = createButton(parent, IDialogConstants.OK_ID, IDialogConstants.OK_LABEL, true); createButton(parent, IDialogConstants.CANCEL_ID, @@ -234,7 +234,7 @@ /* * @see Dialog#createButtonBar(Composite) */ - protected Control createButtonBar(Composite parent) { + protected override Control createButtonBar(Composite parent) { Composite composite = new Composite(parent, DWT.NULL); GridLayout layout = new GridLayout(); diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/dialogs/TitleAreaDialog.d --- a/dwtx/jface/dialogs/TitleAreaDialog.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/dialogs/TitleAreaDialog.d Fri Apr 11 01:24:25 2008 +0200 @@ -131,7 +131,7 @@ /* * @see Dialog.createContents(Composite) */ - protected Control createContents(Composite parent) { + protected override Control createContents(Composite parent) { // create the overall composite Composite contents = new Composite(parent, DWT.NONE); contents.setLayoutData(new GridData(GridData.FILL_BOTH)); @@ -170,7 +170,7 @@ * The parent composite to contain the dialog area * @return the dialog area control */ - protected Control createDialogArea(Composite parent) { + protected override Control createDialogArea(Composite parent) { // create the top level composite for the dialog area Composite composite = new Composite(parent, DWT.NONE); GridLayout layout = new GridLayout(); @@ -329,7 +329,7 @@ * * @return the initial size of the dialog */ - protected Point getInitialSize() { + protected override Point getInitialSize() { Point shellSize = super.getInitialSize(); return new Point(Math.max( convertHorizontalDLUsToPixels(MIN_DIALOG_WIDTH), shellSize.x), diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/dialogs/TrayDialog.d --- a/dwtx/jface/dialogs/TrayDialog.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/dialogs/TrayDialog.d Fri Apr 11 01:24:25 2008 +0200 @@ -143,7 +143,7 @@ /* (non-Javadoc) * @see dwtx.jface.dialogs.Dialog#close() */ - public bool close() { + public override bool close() { /* * Close the tray to ensure that those dialogs that remember their * size do not store the tray size. @@ -157,7 +157,7 @@ /* (non-Javadoc) * @see dwtx.jface.dialogs.Dialog#createButtonBar(dwt.widgets.Composite) */ - protected Control createButtonBar(Composite parent) { + protected override Control createButtonBar(Composite parent) { Composite composite = new Composite(parent, DWT.NONE); GridLayout layout = new GridLayout(); layout.marginWidth = 0; @@ -283,7 +283,7 @@ * @see dwtx.jface.window.Window#getLayout() * @return a newly created layout or null for no layout */ - protected Layout getLayout() { + protected override Layout getLayout() { GridLayout layout = cast(GridLayout)super.getLayout(); layout.numColumns = 5; layout.horizontalSpacing = 0; diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/fieldassist/ContentProposalAdapter.d --- a/dwtx/jface/fieldassist/ContentProposalAdapter.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/fieldassist/ContentProposalAdapter.d Fri Apr 11 01:24:25 2008 +0200 @@ -446,7 +446,7 @@ /* * Create a text control for showing the info about a proposal. */ - protected Control createDialogArea(Composite parent) { + protected override Control createDialogArea(Composite parent) { text = new Text(parent, DWT.MULTI | DWT.READ_ONLY | DWT.WRAP | DWT.NO_FOCUS); @@ -470,7 +470,7 @@ /* * Adjust the bounds so that we appear adjacent to our parent shell */ - protected void adjustBounds() { + protected override void adjustBounds() { Rectangle parentBounds = getParentShell().getBounds(); Rectangle proposedBounds; // Try placing the info popup to the right @@ -603,7 +603,7 @@ * * @see dwtx.jface.dialogs.PopupDialog#createContents(dwt.widgets.Composite) */ - protected Control createContents(Composite parent) { + protected override Control createContents(Composite parent) { Control contents = super.createContents(parent); changeDefaultColors(parent); return contents; @@ -627,7 +627,7 @@ * @param parent The parent composite to contain the dialog area; must * not be null. */ - protected final Control createDialogArea(Composite parent) { + protected override final Control createDialogArea(Composite parent) { // Use virtual where appropriate (see flag definition). if (USE_VIRTUAL) { proposalTable = new Table(parent, DWT.H_SCROLL | DWT.V_SCROLL @@ -674,7 +674,7 @@ * * @see dwtx.jface.dialogs.PopupDialog.adjustBounds() */ - protected void adjustBounds() { + protected override void adjustBounds() { // Get our control's location in display coordinates. Point location = control.getDisplay().map(control.getParent(), null, control.getLocation()); @@ -870,7 +870,7 @@ * * @see dwtx.jface.window.Window#open() */ - public int open() { + public override int open() { int value = super.open(); if (popupCloser is null) { popupCloser = new PopupCloserListener(); @@ -890,7 +890,7 @@ * @return true if the window is (or was already) closed, * and false if it is still open */ - public bool close() { + public override bool close() { popupCloser.removeListeners(); if (infoPopup !is null) { infoPopup.close(); diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/internal/provisional/action/ToolBarManager2.d --- a/dwtx/jface/internal/provisional/action/ToolBarManager2.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/internal/provisional/action/ToolBarManager2.d Fri Apr 11 01:24:25 2008 +0200 @@ -184,7 +184,7 @@ /* (non-Javadoc) * @see dwtx.jface.action.ToolBarManager#relayout(dwt.widgets.ToolBar, int, int) */ - protected void relayout(ToolBar layoutBar, int oldCount, int newCount) { + protected override void relayout(ToolBar layoutBar, int oldCount, int newCount) { super.relayout(layoutBar, oldCount, newCount); firePropertyChange(PROP_LAYOUT, new Integer(oldCount), new Integer(newCount)); } diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/layout/AbstractColumnLayout.d --- a/dwtx/jface/layout/AbstractColumnLayout.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/layout/AbstractColumnLayout.d Fri Apr 11 01:24:25 2008 +0200 @@ -236,7 +236,7 @@ * @see dwt.widgets.Layout#computeSize(dwt.widgets.Composite, * int, int, bool) */ - protected Point computeSize(Composite composite, int wHint, int hHint, + protected override Point computeSize(Composite composite, int wHint, int hHint, bool flushCache) { return computeTableTreeSize(getControl(composite), wHint, hHint); } @@ -247,7 +247,7 @@ * @see dwt.widgets.Layout#layout(dwt.widgets.Composite, * bool) */ - protected void layout(Composite composite, bool flushCache) { + protected override void layout(Composite composite, bool flushCache) { Rectangle area = composite.getClientArea(); Scrollable table = getControl(composite); int tableWidth = table.getSize().x; diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/layout/TableColumnLayout.d --- a/dwtx/jface/layout/TableColumnLayout.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/layout/TableColumnLayout.d Fri Apr 11 01:24:25 2008 +0200 @@ -45,7 +45,7 @@ * * @see dwtx.jface.layout.AbstractColumnLayout#getColumnCount(dwt.widgets.Scrollable) */ - int getColumnCount(Scrollable tableTree) { + override int getColumnCount(Scrollable tableTree) { return (cast(Table) tableTree).getColumnCount(); } @@ -55,7 +55,7 @@ * @see dwtx.jface.layout.AbstractColumnLayout#setColumnWidths(dwt.widgets.Scrollable, * int[]) */ - void setColumnWidths(Scrollable tableTree, int[] widths) { + override void setColumnWidths(Scrollable tableTree, int[] widths) { TableColumn[] columns = (cast(Table) tableTree).getColumns(); for (int i = 0; i < widths.length; i++) { columns[i].setWidth(widths[i]); @@ -67,7 +67,7 @@ * * @see dwtx.jface.layout.AbstractColumnLayout#getLayoutData(int) */ - ColumnLayoutData getLayoutData(Scrollable tableTree, int columnIndex) { + override ColumnLayoutData getLayoutData(Scrollable tableTree, int columnIndex) { TableColumn column = (cast(Table) tableTree).getColumn(columnIndex); return cast(ColumnLayoutData) column.getData(LAYOUT_DATA); } @@ -79,7 +79,7 @@ /* (non-Javadoc) * @see dwtx.jface.layout.AbstractColumnLayout#updateColumnData(dwt.widgets.Widget) */ - void updateColumnData(Widget column) { + override void updateColumnData(Widget column) { TableColumn tColumn = cast(TableColumn) column; Table t = tColumn.getParent(); diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/layout/TreeColumnLayout.d --- a/dwtx/jface/layout/TreeColumnLayout.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/layout/TreeColumnLayout.d Fri Apr 11 01:24:25 2008 +0200 @@ -78,7 +78,7 @@ listener = new TreeLayoutListener(); } - protected void layout(Composite composite, bool flushCache) { + protected override void layout(Composite composite, bool flushCache) { super.layout(composite, flushCache); if( addListener ) { addListener=false; @@ -89,14 +89,14 @@ /* (non-Javadoc) * @see dwtx.jface.layout.AbstractColumnLayout#getColumnCount(dwt.widgets.Scrollable) */ - int getColumnCount(Scrollable tree) { + override int getColumnCount(Scrollable tree) { return (cast(Tree) tree).getColumnCount(); } /* (non-Javadoc) * @see dwtx.jface.layout.AbstractColumnLayout#setColumnWidths(dwt.widgets.Scrollable, int[]) */ - void setColumnWidths(Scrollable tree, int[] widths) { + override void setColumnWidths(Scrollable tree, int[] widths) { TreeColumn[] columns = (cast(Tree) tree).getColumns(); for (int i = 0; i < widths.length; i++) { columns[i].setWidth(widths[i]); @@ -106,12 +106,12 @@ /* (non-Javadoc) * @see dwtx.jface.layout.AbstractColumnLayout#getLayoutData(dwt.widgets.Scrollable, int) */ - ColumnLayoutData getLayoutData(Scrollable tableTree, int columnIndex) { + override ColumnLayoutData getLayoutData(Scrollable tableTree, int columnIndex) { TreeColumn column = (cast(Tree) tableTree).getColumn(columnIndex); return cast(ColumnLayoutData) column.getData(LAYOUT_DATA); } - void updateColumnData(Widget column) { + override void updateColumnData(Widget column) { TreeColumn tColumn = cast(TreeColumn) column; Tree t = tColumn.getParent(); diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/menus/TextState.d --- a/dwtx/jface/menus/TextState.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/menus/TextState.d Fri Apr 11 01:24:25 2008 +0200 @@ -40,13 +40,13 @@ */ public class TextState : PersistentState { - public final void load(IPreferenceStore store, + public override final void load(IPreferenceStore store, String preferenceKey) { String value = store.getString(preferenceKey); setValue(stringcast(value)); } - public final void save(IPreferenceStore store, + public override final void save(IPreferenceStore store, String preferenceKey) { Object value = getValue(); if ( cast(ArrayWrapperString)value ) { @@ -54,7 +54,7 @@ } } - public void setValue(Object value) { + public override void setValue(Object value) { if (!( cast(ArrayWrapperString)value )) { throw new IllegalArgumentException( "TextState takes a String as a value"); //$NON-NLS-1$ diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/operation/AccumulatingProgressMonitor.d --- a/dwtx/jface/operation/AccumulatingProgressMonitor.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/operation/AccumulatingProgressMonitor.d Fri Apr 11 01:24:25 2008 +0200 @@ -123,7 +123,7 @@ /* (non-Javadoc) * Method declared on IProgressMonitor. */ - public void beginTask(String name, int totalWork) { + public override void beginTask(String name, int totalWork) { synchronized (this) { collector = null; } @@ -161,7 +161,7 @@ /* (non-Javadoc) * Method declared on IProgressMonitor. */ - public void done() { + public override void done() { synchronized (this) { collector = null; } @@ -175,7 +175,7 @@ /* (non-Javadoc) * Method declared on IProgressMonitor. */ - public synchronized void internalWorked(double work) { + public override synchronized void internalWorked(double work) { if (collector is null) { createCollector(null, work); } else { @@ -186,7 +186,7 @@ /* (non-Javadoc) * Method declared on IProgressMonitor. */ - public void setTaskName(String name) { + public override void setTaskName(String name) { synchronized (this) { collector = null; } @@ -201,7 +201,7 @@ /* (non-Javadoc) * Method declared on IProgressMonitor. */ - public synchronized void subTask(String name) { + public override synchronized void subTask(String name) { if (collector is null) { createCollector(name, 0); } else { @@ -212,14 +212,14 @@ /* (non-Javadoc) * Method declared on IProgressMonitor. */ - public synchronized void worked(int work) { + public override synchronized void worked(int work) { internalWorked(work); } /* (non-Javadoc) * @see dwtx.core.runtime.ProgressMonitorWrapper#clearBlocked() */ - public void clearBlocked() { + public override void clearBlocked() { //If this is a monitor that can report blocking do so. //Don't bother with a collector as this should only ever @@ -246,7 +246,7 @@ /* (non-Javadoc) * @see dwtx.core.runtime.ProgressMonitorWrapper#setBlocked(dwtx.core.runtime.IStatus) */ - public void setBlocked(IStatus reason) { + public override void setBlocked(IStatus reason) { //If this is a monitor that can report blocking do so. //Don't bother with a collector as this should only ever //happen once and prevent any more progress. diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/operation/ModalContext.d --- a/dwtx/jface/operation/ModalContext.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/operation/ModalContext.d Fri Apr 11 01:24:25 2008 +0200 @@ -116,7 +116,7 @@ /* (non-Javadoc) * Method declared on Thread. */ - public void run() { + public /+override+/ void run() { try { if (runnable !is null) { runnable.run(progressMonitor); diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/preference/BooleanFieldEditor.d --- a/dwtx/jface/preference/BooleanFieldEditor.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/preference/BooleanFieldEditor.d Fri Apr 11 01:24:25 2008 +0200 @@ -99,7 +99,7 @@ /* (non-Javadoc) * Method declared on FieldEditor. */ - protected void adjustForNumColumns(int numColumns) { + protected override void adjustForNumColumns(int numColumns) { if (style is SEPARATE_LABEL) { numColumns--; } @@ -109,7 +109,7 @@ /* (non-Javadoc) * Method declared on FieldEditor. */ - protected void doFillIntoGrid(Composite parent, int numColumns) { + protected override void doFillIntoGrid(Composite parent, int numColumns) { String text = getLabelText(); switch (style) { case SEPARATE_LABEL: @@ -132,7 +132,7 @@ * Loads the value from the preference store and sets it to * the check box. */ - protected void doLoad() { + protected override void doLoad() { if (checkBox !is null) { bool value = getPreferenceStore() .getBoolean(getPreferenceName()); @@ -146,7 +146,7 @@ * Loads the default value from the preference store and sets it to * the check box. */ - protected void doLoadDefault() { + protected override void doLoadDefault() { if (checkBox !is null) { bool value = getPreferenceStore().getDefaultBoolean( getPreferenceName()); @@ -158,7 +158,7 @@ /* (non-Javadoc) * Method declared on FieldEditor. */ - protected void doStore() { + protected override void doStore() { getPreferenceStore().setValue(getPreferenceName(), checkBox.getSelection()); } @@ -203,7 +203,7 @@ /* (non-Javadoc) * Method declared on FieldEditor. */ - public int getNumberOfControls() { + public override int getNumberOfControls() { switch (style) { case SEPARATE_LABEL: return 2; @@ -215,7 +215,7 @@ /* (non-Javadoc) * Method declared on FieldEditor. */ - public void setFocus() { + public override void setFocus() { if (checkBox !is null) { checkBox.setFocus(); } @@ -224,7 +224,7 @@ /* (non-Javadoc) * Method declared on FieldEditor. */ - public void setLabelText(String text) { + public override void setLabelText(String text) { super.setLabelText(text); Label label = getLabelControl(); if (label is null && checkBox !is null) { @@ -250,7 +250,7 @@ /* * @see FieldEditor.setEnabled */ - public void setEnabled(bool enabled, Composite parent) { + public override void setEnabled(bool enabled, Composite parent) { //Only call super if there is a label already if (style is SEPARATE_LABEL) { super.setEnabled(enabled, parent); diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/preference/BooleanPropertyAction.d --- a/dwtx/jface/preference/BooleanPropertyAction.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/preference/BooleanPropertyAction.d Fri Apr 11 01:24:25 2008 +0200 @@ -68,7 +68,7 @@ * (non-Javadoc) * @see dwtx.jface.action.IAction#run() */ - public void run() { + public override void run() { preferenceStore.setValue(property, isChecked()); } } diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/preference/ColorFieldEditor.d --- a/dwtx/jface/preference/ColorFieldEditor.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/preference/ColorFieldEditor.d Fri Apr 11 01:24:25 2008 +0200 @@ -63,7 +63,7 @@ /* * (non-Javadoc) Method declared on FieldEditor. */ - protected void adjustForNumColumns(int numColumns) { + protected override void adjustForNumColumns(int numColumns) { (cast(GridData) colorSelector.getButton().getLayoutData()).horizontalSpan = numColumns - 1; } @@ -96,7 +96,7 @@ /* (non-Javadoc) * @see dwtx.jface.preference.FieldEditor#doFillIntoGrid(dwt.widgets.Composite, int) */ - protected void doFillIntoGrid(Composite parent, int numColumns) { + protected override void doFillIntoGrid(Composite parent, int numColumns) { Control control = getLabelControl(parent); GridData gd = new GridData(); gd.horizontalSpan = numColumns - 1; @@ -111,7 +111,7 @@ /* (non-Javadoc) * @see dwtx.jface.preference.FieldEditor#doLoad() */ - protected void doLoad() { + protected override void doLoad() { if (colorSelector is null) { return; } @@ -122,7 +122,7 @@ /* * (non-Javadoc) Method declared on FieldEditor. */ - protected void doLoadDefault() { + protected override void doLoadDefault() { if (colorSelector is null) { return; } @@ -133,7 +133,7 @@ /* * (non-Javadoc) Method declared on FieldEditor. */ - protected void doStore() { + protected override void doStore() { PreferenceConverter.setValue(getPreferenceStore(), getPreferenceName(), colorSelector.getColorValue()); } @@ -175,7 +175,7 @@ /* * (non-Javadoc) Method declared on FieldEditor. */ - public int getNumberOfControls() { + public override int getNumberOfControls() { return 2; } @@ -185,7 +185,7 @@ * @see dwtx.jface.preference.FieldEditor#setEnabled(bool, * dwt.widgets.Composite) */ - public void setEnabled(bool enabled, Composite parent) { + public override void setEnabled(bool enabled, Composite parent) { super.setEnabled(enabled, parent); getChangeControl(parent).setEnabled(enabled); } diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/preference/ComboFieldEditor.d --- a/dwtx/jface/preference/ComboFieldEditor.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/preference/ComboFieldEditor.d Fri Apr 11 01:24:25 2008 +0200 @@ -87,7 +87,7 @@ /* (non-Javadoc) * @see dwtx.jface.preference.FieldEditor#adjustForNumColumns(int) */ - protected void adjustForNumColumns(int numColumns) { + protected override void adjustForNumColumns(int numColumns) { if (numColumns > 1) { Control control = getLabelControl(); int left = numColumns; @@ -108,7 +108,7 @@ /* (non-Javadoc) * @see dwtx.jface.preference.FieldEditor#doFillIntoGrid(dwt.widgets.Composite, int) */ - protected void doFillIntoGrid(Composite parent, int numColumns) { + protected override void doFillIntoGrid(Composite parent, int numColumns) { int comboC = 1; if (numColumns > 1) { comboC = numColumns - 1; @@ -128,21 +128,21 @@ /* (non-Javadoc) * @see dwtx.jface.preference.FieldEditor#doLoad() */ - protected void doLoad() { + protected override void doLoad() { updateComboForValue(getPreferenceStore().getString(getPreferenceName())); } /* (non-Javadoc) * @see dwtx.jface.preference.FieldEditor#doLoadDefault() */ - protected void doLoadDefault() { + protected override void doLoadDefault() { updateComboForValue(getPreferenceStore().getDefaultString(getPreferenceName())); } /* (non-Javadoc) * @see dwtx.jface.preference.FieldEditor#doStore() */ - protected void doStore() { + protected override void doStore() { if (fValue is null) { getPreferenceStore().setToDefault(getPreferenceName()); return; @@ -153,7 +153,7 @@ /* (non-Javadoc) * @see dwtx.jface.preference.FieldEditor#getNumberOfControls() */ - public int getNumberOfControls() { + public override int getNumberOfControls() { return 2; } diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/preference/DirectoryFieldEditor.d --- a/dwtx/jface/preference/DirectoryFieldEditor.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/preference/DirectoryFieldEditor.d Fri Apr 11 01:24:25 2008 +0200 @@ -55,7 +55,7 @@ * Method declared on StringButtonFieldEditor. * Opens the directory chooser dialog and returns the selected directory. */ - protected String changePressed() { + protected override String changePressed() { auto f = new FilePath(getTextControl().getText()); if (!f.exists()) { f = cast(FilePath)null; @@ -72,7 +72,7 @@ * Method declared on StringFieldEditor. * Checks whether the text input field contains a valid directory. */ - protected bool doCheckState() { + protected override bool doCheckState() { String fileName = getTextControl().getText(); fileName = fileName.trim(); if (fileName.length is 0 && isEmptyStringAllowed()) { diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/preference/FieldEditorPreferencePage.d --- a/dwtx/jface/preference/FieldEditorPreferencePage.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/preference/FieldEditorPreferencePage.d Fri Apr 11 01:24:25 2008 +0200 @@ -222,7 +222,7 @@ /* (non-Javadoc) * Method declared on PreferencePage. */ - protected Control createContents(Composite parent) { + protected override Control createContents(Composite parent) { fieldEditorParent = new Composite(parent, DWT.NULL); GridLayout layout = new GridLayout(); layout.numColumns = 1; @@ -265,7 +265,7 @@ * Subclasses may override to release their own allocated DWT * resources, but must call super.dispose. */ - public void dispose() { + public override void dispose() { super.dispose(); if (fields !is null) { foreach( e; fields ){ @@ -318,7 +318,7 @@ * The field editor preference page implementation of a PreferencePage * method loads all the field editors with their default values. */ - protected void performDefaults() { + protected override void performDefaults() { if (fields !is null) { foreach( e; fields ){ FieldEditor pe = cast(FieldEditor) e; @@ -339,7 +339,7 @@ * * @see FieldEditor#store() */ - public bool performOk() { + public override bool performOk() { if (fields !is null) { foreach( e; fields ){ FieldEditor pe = cast(FieldEditor) e; @@ -373,7 +373,7 @@ /* (non-Javadoc) * Method declared on IDialog. */ - public void setVisible(bool visible) { + public override void setVisible(bool visible) { super.setVisible(visible); if (visible && invalidFieldEditor !is null) { invalidFieldEditor.setFocus(); diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/preference/FileFieldEditor.d --- a/dwtx/jface/preference/FileFieldEditor.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/preference/FileFieldEditor.d Fri Apr 11 01:24:25 2008 +0200 @@ -83,7 +83,7 @@ * Method declared on StringButtonFieldEditor. * Opens the file chooser dialog and returns the selected file. */ - protected String changePressed() { + protected override String changePressed() { auto f = new FilePath(getTextControl().getText()); if (!f.exists()) { f = cast(FilePath)null; @@ -100,7 +100,7 @@ * Method declared on StringFieldEditor. * Checks whether the text input field specifies an existing file. */ - protected bool checkState() { + protected override bool checkState() { String msg = null; diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/preference/FontFieldEditor.d --- a/dwtx/jface/preference/FontFieldEditor.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/preference/FontFieldEditor.d Fri Apr 11 01:24:25 2008 +0200 @@ -169,7 +169,7 @@ /* (non-Javadoc) * Method declared on FieldEditor. */ - protected void adjustForNumColumns(int numColumns) { + protected override void adjustForNumColumns(int numColumns) { GridData data = new GridData(); if (valueControl.getLayoutData() !is null) { @@ -183,7 +183,7 @@ /* (non-Javadoc) * Method declared on FieldEditor. */ - protected void applyFont() { + protected override void applyFont() { if (chosenFont !is null && previewer !is null) { previewer.setFont(chosenFont); } @@ -192,7 +192,7 @@ /* (non-Javadoc) * Method declared on FieldEditor. */ - protected void doFillIntoGrid(Composite parent, int numColumns) { + protected override void doFillIntoGrid(Composite parent, int numColumns) { getLabelControl(parent); valueControl = getValueControl(parent); @@ -222,7 +222,7 @@ /* (non-Javadoc) * Method declared on FieldEditor. */ - protected void doLoad() { + protected override void doLoad() { if (changeFontButton is null) { return; } @@ -233,7 +233,7 @@ /* (non-Javadoc) * Method declared on FieldEditor. */ - protected void doLoadDefault() { + protected override void doLoadDefault() { if (changeFontButton is null) { return; } @@ -244,7 +244,7 @@ /* (non-Javadoc) * Method declared on FieldEditor. */ - protected void doStore() { + protected override void doStore() { if (chosenFont !is null) { PreferenceConverter.setValue(getPreferenceStore(), getPreferenceName(), chosenFont); @@ -302,7 +302,7 @@ /* (non-Javadoc) * Method declared on FieldEditor. */ - public int getNumberOfControls() { + public override int getNumberOfControls() { if (previewer is null) { return 3; } @@ -418,7 +418,7 @@ /* * @see FieldEditor.setEnabled(bool,Composite). */ - public void setEnabled(bool enabled, Composite parent) { + public override void setEnabled(bool enabled, Composite parent) { super.setEnabled(enabled, parent); getChangeControl(parent).setEnabled(enabled); getValueControl(parent).setEnabled(enabled); diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/preference/IntegerFieldEditor.d --- a/dwtx/jface/preference/IntegerFieldEditor.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/preference/IntegerFieldEditor.d Fri Apr 11 01:24:25 2008 +0200 @@ -83,7 +83,7 @@ * Method declared on StringFieldEditor. * Checks whether the entered String is a valid integer or not. */ - protected bool checkState() { + protected override bool checkState() { Text text = getTextControl(); @@ -112,7 +112,7 @@ /* (non-Javadoc) * Method declared on FieldEditor. */ - protected void doLoad() { + protected override void doLoad() { Text text = getTextControl(); if (text !is null) { int value = getPreferenceStore().getInt(getPreferenceName()); @@ -124,7 +124,7 @@ /* (non-Javadoc) * Method declared on FieldEditor. */ - protected void doLoadDefault() { + protected override void doLoadDefault() { Text text = getTextControl(); if (text !is null) { int value = getPreferenceStore().getDefaultInt(getPreferenceName()); @@ -136,7 +136,7 @@ /* (non-Javadoc) * Method declared on FieldEditor. */ - protected void doStore() { + protected override void doStore() { Text text = getTextControl(); if (text !is null) { Integer i = new Integer(text.getText()); diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/preference/ListEditor.d --- a/dwtx/jface/preference/ListEditor.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/preference/ListEditor.d Fri Apr 11 01:24:25 2008 +0200 @@ -123,7 +123,7 @@ /* (non-Javadoc) * Method declared on FieldEditor. */ - protected void adjustForNumColumns(int numColumns) { + protected override void adjustForNumColumns(int numColumns) { Control control = getLabelControl(); (cast(GridData) control.getLayoutData()).horizontalSpan = numColumns; (cast(GridData) list.getLayoutData()).horizontalSpan = numColumns - 1; @@ -200,7 +200,7 @@ /* (non-Javadoc) * Method declared on FieldEditor. */ - protected void doFillIntoGrid(Composite parent, int numColumns) { + protected override void doFillIntoGrid(Composite parent, int numColumns) { Control control = getLabelControl(parent); GridData gd = new GridData(); gd.horizontalSpan = numColumns; @@ -222,7 +222,7 @@ /* (non-Javadoc) * Method declared on FieldEditor. */ - protected void doLoad() { + protected override void doLoad() { if (list !is null) { String s = getPreferenceStore().getString(getPreferenceName()); String[] array = parseString(s); @@ -235,7 +235,7 @@ /* (non-Javadoc) * Method declared on FieldEditor. */ - protected void doLoadDefault() { + protected override void doLoadDefault() { if (list !is null) { list.removeAll(); String s = getPreferenceStore().getDefaultString( @@ -250,7 +250,7 @@ /* (non-Javadoc) * Method declared on FieldEditor. */ - protected void doStore() { + protected override void doStore() { String s = createList(list.getItems()); if (s !is null) { getPreferenceStore().setValue(getPreferenceName(), s); @@ -332,7 +332,7 @@ /* (non-Javadoc) * Method declared on FieldEditor. */ - public int getNumberOfControls() { + public override int getNumberOfControls() { return 2; } @@ -406,7 +406,7 @@ /* (non-Javadoc) * Method declared on FieldEditor. */ - public void setFocus() { + public override void setFocus() { if (list !is null) { list.setFocus(); } @@ -443,7 +443,7 @@ /* * @see FieldEditor.setEnabled(bool,Composite). */ - public void setEnabled(bool enabled, Composite parent) { + public override void setEnabled(bool enabled, Composite parent) { super.setEnabled(enabled, parent); getListControl(parent).setEnabled(enabled); addButton.setEnabled(enabled); diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/preference/PathEditor.d --- a/dwtx/jface/preference/PathEditor.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/preference/PathEditor.d Fri Apr 11 01:24:25 2008 +0200 @@ -67,7 +67,7 @@ * Creates a single string from the given array by separating each * string with the appropriate OS-specific path separator. */ - protected String createList(String[] items) { + protected override String createList(String[] items) { StringBuffer path = new StringBuffer("");//$NON-NLS-1$ for (int i = 0; i < items.length; i++) { @@ -81,7 +81,7 @@ * Method declared on ListEditor. * Creates a new path element by means of a directory dialog. */ - protected String getNewInputObject() { + protected override String getNewInputObject() { DirectoryDialog dialog = new DirectoryDialog(getShell()); if (dirChooserLabelText !is null) { @@ -106,7 +106,7 @@ /* (non-Javadoc) * Method declared on ListEditor. */ - protected String[] parseString(String stringList) { + protected override String[] parseString(String stringList) { return tango.text.Util.delimit(stringList.dup, FileConst.PathSeparatorString ~ "\n\r");//$NON-NLS-1$ } diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/preference/PreferenceDialog.d --- a/dwtx/jface/preference/PreferenceDialog.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/preference/PreferenceDialog.d Fri Apr 11 01:24:25 2008 +0200 @@ -97,7 +97,7 @@ * */ private class PageLayout : Layout { - public Point computeSize(Composite composite, int wHint, int hHint, bool force) { + public override Point computeSize(Composite composite, int wHint, int hHint, bool force) { if (wHint !is DWT.DEFAULT && hHint !is DWT.DEFAULT) { return new Point(wHint, hHint); } @@ -127,7 +127,7 @@ return new Point(x, y); } - public void layout(Composite composite, bool force) { + public override void layout(Composite composite, bool force) { Rectangle rect = composite.getClientArea(); Control[] children = composite.getChildren(); for (int i = 0; i < children.length; i++) { @@ -240,7 +240,7 @@ * * @see dwtx.jface.dialogs.Dialog#buttonPressed(int) */ - protected void buttonPressed(int buttonId) { + protected override void buttonPressed(int buttonId) { switch (buttonId) { case IDialogConstants.OK_ID: { okPressed(); @@ -262,7 +262,7 @@ * * @see dwtx.jface.dialogs.Dialog#cancelPressed() */ - protected void cancelPressed() { + protected override void cancelPressed() { // Inform all pages that we are cancelling foreach( e; preferenceManager.getElements(PreferenceManager.PRE_ORDER)){ IPreferenceNode node = cast(IPreferenceNode) e; @@ -301,7 +301,7 @@ * * @see dwtx.jface.window.Window#close() */ - public bool close() { + public override bool close() { //Do this is in a SafeRunnable as it may run client code SafeRunnable runnable = new class SafeRunnable{ @@ -336,7 +336,7 @@ * * @see dwtx.jface.window.Window#configureShell(dwt.widgets.Shell) */ - protected void configureShell(Shell newShell) { + protected override void configureShell(Shell newShell) { super.configureShell(newShell); newShell.setText(JFaceResources.getString("PreferenceDialog.title")); //$NON-NLS-1$ newShell.addShellListener(new class ShellAdapter { @@ -355,7 +355,7 @@ * * @see dwtx.jface.window.Window#constrainShellSize() */ - protected void constrainShellSize() { + protected override void constrainShellSize() { super.constrainShellSize(); // record opening shell size if (lastShellSize is null) { @@ -368,7 +368,7 @@ * * @see dwtx.jface.dialogs.Dialog#createButtonsForButtonBar(dwt.widgets.Composite) */ - protected void createButtonsForButtonBar(Composite parent) { + protected override void createButtonsForButtonBar(Composite parent) { // create OK and Cancel buttons by default okButton = createButton(parent, IDialogConstants.OK_ID, IDialogConstants.OK_LABEL, true); getShell().setDefaultButton(okButton); @@ -380,7 +380,7 @@ * * @see dwtx.jface.window.Window#createContents(dwt.widgets.Composite) */ - protected Control createContents(Composite parent) { + protected override Control createContents(Composite parent) { Control[1] control; BusyIndicator.showWhile(getShell().getDisplay(), new class(parent) Runnable { Composite parent_; @@ -404,7 +404,7 @@ * * @see dwtx.jface.dialogs.Dialog#createDialogArea(dwt.widgets.Composite) */ - protected Control createDialogArea(Composite parent) { + protected override Control createDialogArea(Composite parent) { final Composite composite = cast(Composite) super.createDialogArea(parent); GridLayout parentLayout = (cast(GridLayout) composite.getLayout()); parentLayout.numColumns = 4; @@ -892,7 +892,7 @@ * close. Subclasses may extend or reimplement. *

*/ - protected void handleShellCloseEvent() { + protected override void handleShellCloseEvent() { // handle the same as pressing cancel cancelPressed(); } @@ -904,7 +904,7 @@ * performHelp on the currently active page. *

*/ - protected void helpPressed() { + protected /+override+/ void helpPressed() { if (currentPage !is null) { currentPage.performHelp(); } @@ -942,7 +942,7 @@ * preference dialog, then calls handleSave on this dialog to * save any state, and then calls close to close this dialog. */ - protected void okPressed() { + protected override void okPressed() { SafeRunnable.run(new class SafeRunnable { private bool errorOccurred; diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/preference/PreferenceLabelProvider.d --- a/dwtx/jface/preference/PreferenceLabelProvider.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/preference/PreferenceLabelProvider.d Fri Apr 11 01:24:25 2008 +0200 @@ -30,7 +30,7 @@ * @param element must be an instance of IPreferenceNode. * @see dwtx.jface.viewers.ILabelProvider#getText(java.lang.Object) */ - public String getText(Object element) { + public override String getText(Object element) { return (cast(IPreferenceNode) element).getLabelText(); } @@ -38,7 +38,7 @@ * @param element must be an instance of IPreferenceNode. * @see dwtx.jface.viewers.ILabelProvider#getImage(java.lang.Object) */ - public Image getImage(Object element) { + public override Image getImage(Object element) { return (cast(IPreferenceNode) element).getLabelImage(); } } diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/preference/PreferencePage.d --- a/dwtx/jface/preference/PreferencePage.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/preference/PreferencePage.d Fri Apr 11 01:24:25 2008 +0200 @@ -65,6 +65,7 @@ */ public abstract class PreferencePage : DialogPage, IPreferencePage { + alias DialogPage.setMessage setMessage; /** * Preference store, or null. @@ -509,7 +510,7 @@ * method extends the DialogPage implementation to update * the preference page container title. Subclasses may extend. */ - public void setTitle(String title) { + public override void setTitle(String title) { super.setTitle(title); if (getContainer() !is null) { getContainer().updateTitle(); @@ -541,7 +542,7 @@ /** * Returns a string suitable for debugging purpose only. */ - public String toString() { + public override String toString() { return getTitle(); } @@ -626,7 +627,7 @@ /* (non-Javadoc) * @see dwtx.jface.dialogs.IDialogPage#performHelp() */ - public void performHelp() { + public override void performHelp() { getControl().notifyListeners(DWT.Help, new Event()); } @@ -642,7 +643,7 @@ /* (non-Javadoc) * @see dwtx.jface.dialogs.DialogPage#setErrorMessage(java.lang.String) */ - public void setErrorMessage(String newMessage) { + public override void setErrorMessage(String newMessage) { super.setErrorMessage(newMessage); if (getContainer() !is null) { getContainer().updateMessage(); @@ -652,7 +653,7 @@ /* (non-Javadoc) * @see dwtx.jface.dialogs.DialogPage#setMessage(java.lang.String, int) */ - public void setMessage(String newMessage, int newType) { + public override void setMessage(String newMessage, int newType) { super.setMessage(newMessage, newType); if (getContainer() !is null) { getContainer().updateMessage(); diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/preference/RadioGroupFieldEditor.d --- a/dwtx/jface/preference/RadioGroupFieldEditor.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/preference/RadioGroupFieldEditor.d Fri Apr 11 01:24:25 2008 +0200 @@ -146,7 +146,7 @@ /* (non-Javadoc) * Method declared on FieldEditor. */ - protected void adjustForNumColumns(int numColumns) { + protected override void adjustForNumColumns(int numColumns) { Control control = getLabelControl(); if (control !is null) { (cast(GridData) control.getLayoutData()).horizontalSpan = numColumns; @@ -177,7 +177,7 @@ /* (non-Javadoc) * Method declared on FieldEditor. */ - protected void doFillIntoGrid(Composite parent, int numColumns) { + protected override void doFillIntoGrid(Composite parent, int numColumns) { if (useGroup) { Control control = getRadioBoxControl(parent); GridData gd = new GridData(GridData.FILL_HORIZONTAL); @@ -199,21 +199,21 @@ /* (non-Javadoc) * Method declared on FieldEditor. */ - protected void doLoad() { + protected override void doLoad() { updateValue(getPreferenceStore().getString(getPreferenceName())); } /* (non-Javadoc) * Method declared on FieldEditor. */ - protected void doLoadDefault() { + protected override void doLoadDefault() { updateValue(getPreferenceStore().getDefaultString(getPreferenceName())); } /* (non-Javadoc) * Method declared on FieldEditor. */ - protected void doStore() { + protected override void doStore() { if (value is null) { getPreferenceStore().setToDefault(getPreferenceName()); return; @@ -225,7 +225,7 @@ /* (non-Javadoc) * Method declared on FieldEditor. */ - public int getNumberOfControls() { + public override int getNumberOfControls() { return 1; } @@ -343,7 +343,7 @@ /* * @see FieldEditor.setEnabled(bool,Composite). */ - public void setEnabled(bool enabled, Composite parent) { + public override void setEnabled(bool enabled, Composite parent) { if (!useGroup) { super.setEnabled(enabled, parent); } diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/preference/ScaleFieldEditor.d --- a/dwtx/jface/preference/ScaleFieldEditor.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/preference/ScaleFieldEditor.d Fri Apr 11 01:24:25 2008 +0200 @@ -108,7 +108,7 @@ * * @see dwtx.jface.preference.FieldEditor#adjustForNumColumns(int) */ - protected void adjustForNumColumns(int numColumns) { + protected override void adjustForNumColumns(int numColumns) { (cast(GridData) scale.getLayoutData()).horizontalSpan = numColumns - 1; } @@ -118,7 +118,7 @@ * @see dwtx.jface.preference.FieldEditor#doFillIntoGrid(dwt.widgets.Composite, * int) */ - protected void doFillIntoGrid(Composite parent, int numColumns) { + protected override void doFillIntoGrid(Composite parent, int numColumns) { Control control = getLabelControl(parent); GridData gd = new GridData(); control.setLayoutData(gd); @@ -137,7 +137,7 @@ * * @see dwtx.jface.preference.FieldEditor#doLoad() */ - protected void doLoad() { + protected override void doLoad() { if (scale !is null) { int value = getPreferenceStore().getInt(getPreferenceName()); scale.setSelection(value); @@ -150,7 +150,7 @@ * * @see dwtx.jface.preference.FieldEditor#doLoadDefault() */ - protected void doLoadDefault() { + protected override void doLoadDefault() { if (scale !is null) { int value = getPreferenceStore().getDefaultInt(getPreferenceName()); scale.setSelection(value); @@ -163,7 +163,7 @@ * * @see dwtx.jface.preference.FieldEditor#doStore() */ - protected void doStore() { + protected override void doStore() { getPreferenceStore() .setValue(getPreferenceName(), scale.getSelection()); } @@ -203,7 +203,7 @@ * * @see dwtx.jface.preference.FieldEditor#getNumberOfControls() */ - public int getNumberOfControls() { + public override int getNumberOfControls() { return 2; } @@ -273,7 +273,7 @@ * * @see dwtx.jface.preference.FieldEditor#setFocus() */ - public void setFocus() { + public override void setFocus() { if (scale !is null && !scale.isDisposed()) { scale.setFocus(); } diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/preference/StringButtonFieldEditor.d --- a/dwtx/jface/preference/StringButtonFieldEditor.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/preference/StringButtonFieldEditor.d Fri Apr 11 01:24:25 2008 +0200 @@ -73,7 +73,7 @@ /* (non-Javadoc) * Method declared on FieldEditor. */ - protected void adjustForNumColumns(int numColumns) { + protected override void adjustForNumColumns(int numColumns) { (cast(GridData) getTextControl().getLayoutData()).horizontalSpan = numColumns - 2; } @@ -93,7 +93,7 @@ /* (non-Javadoc) * Method declared on StringFieldEditor (and FieldEditor). */ - protected void doFillIntoGrid(Composite parent, int numColumns) { + protected override void doFillIntoGrid(Composite parent, int numColumns) { super.doFillIntoGrid(parent, numColumns - 1); changeButton = getChangeControl(parent); GridData gd = new GridData(); @@ -140,7 +140,7 @@ /* (non-Javadoc) * Method declared on FieldEditor. */ - public int getNumberOfControls() { + public override int getNumberOfControls() { return 3; } @@ -175,7 +175,7 @@ /* (non-Javadoc) * @see dwtx.jface.preference.FieldEditor#setEnabled(bool, dwt.widgets.Composite) */ - public void setEnabled(bool enabled, Composite parent) { + public override void setEnabled(bool enabled, Composite parent) { super.setEnabled(enabled, parent); if (changeButton !is null) { changeButton.setEnabled(enabled); diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/preference/StringFieldEditor.d --- a/dwtx/jface/preference/StringFieldEditor.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/preference/StringFieldEditor.d Fri Apr 11 01:24:25 2008 +0200 @@ -170,7 +170,7 @@ /* (non-Javadoc) * Method declared on FieldEditor. */ - protected void adjustForNumColumns(int numColumns) { + protected override void adjustForNumColumns(int numColumns) { GridData gd = cast(GridData) textField.getLayoutData(); gd.horizontalSpan = numColumns - 1; // We only grab excess space if we have to @@ -234,7 +234,7 @@ * but must call super.doFillIntoGrid. *

*/ - protected void doFillIntoGrid(Composite parent, int numColumns) { + protected override void doFillIntoGrid(Composite parent, int numColumns) { getLabelControl(parent); textField = getTextControl(parent); @@ -258,7 +258,7 @@ /* (non-Javadoc) * Method declared on FieldEditor. */ - protected void doLoad() { + protected override void doLoad() { if (textField !is null) { String value = getPreferenceStore().getString(getPreferenceName()); textField.setText(value); @@ -269,7 +269,7 @@ /* (non-Javadoc) * Method declared on FieldEditor. */ - protected void doLoadDefault() { + protected override void doLoadDefault() { if (textField !is null) { String value = getPreferenceStore().getDefaultString( getPreferenceName()); @@ -281,7 +281,7 @@ /* (non-Javadoc) * Method declared on FieldEditor. */ - protected void doStore() { + protected override void doStore() { getPreferenceStore().setValue(getPreferenceName(), textField.getText()); } @@ -298,7 +298,7 @@ /* (non-Javadoc) * Method declared on FieldEditor. */ - public int getNumberOfControls() { + public override int getNumberOfControls() { return 2; } @@ -399,14 +399,14 @@ /* (non-Javadoc) * Method declared on FieldEditor. */ - public bool isValid() { + public override bool isValid() { return isValid_; } /* (non-Javadoc) * Method declared on FieldEditor. */ - protected void refreshValidState() { + protected override void refreshValidState() { isValid_ = checkState(); } @@ -433,7 +433,7 @@ /* (non-Javadoc) * Method declared on FieldEditor. */ - public void setFocus() { + public override void setFocus() { if (textField !is null) { textField.setFocus(); } @@ -525,7 +525,7 @@ /* * @see FieldEditor.setEnabled(bool,Composite). */ - public void setEnabled(bool enabled, Composite parent) { + public override void setEnabled(bool enabled, Composite parent) { super.setEnabled(enabled, parent); getTextControl(parent).setEnabled(enabled); } diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/resource/AbstractResourceManager.d --- a/dwtx/jface/resource/AbstractResourceManager.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/resource/AbstractResourceManager.d Fri Apr 11 01:24:25 2008 +0200 @@ -73,7 +73,7 @@ /* (non-Javadoc) * @see ResourceManager#create(DeviceResourceDescriptor) */ - public final Object create(DeviceResourceDescriptor descriptor){ + public override final Object create(DeviceResourceDescriptor descriptor){ // Lazily allocate the map if (map is null) { @@ -101,7 +101,7 @@ /* (non-Javadoc) * @see ResourceManager#destroy(DeviceResourceDescriptor) */ - public final void destroy(DeviceResourceDescriptor descriptor) { + public override final void destroy(DeviceResourceDescriptor descriptor) { // If the map is empty (null) then there are no resources to dispose if (map is null) { return; @@ -131,7 +131,7 @@ * * @since 3.1 */ - public void dispose() { + public override void dispose() { super.dispose(); if (map is null) { @@ -148,7 +148,7 @@ /* (non-Javadoc) * @see dwtx.jface.resource.ResourceManager#find(dwtx.jface.resource.DeviceResourceDescriptor) */ - public Object find(DeviceResourceDescriptor descriptor) { + public override Object find(DeviceResourceDescriptor descriptor) { if (map is null) { return null; } diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/resource/ArrayFontDescriptor.d --- a/dwtx/jface/resource/ArrayFontDescriptor.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/resource/ArrayFontDescriptor.d Fri Apr 11 01:24:25 2008 +0200 @@ -58,7 +58,7 @@ /* (non-Javadoc) * @see dwtx.jface.resource.FontDescriptor#getFontData() */ - public FontData[] getFontData() { + public override FontData[] getFontData() { // Copy the original array to ensure that callers will not modify it return copy(data); } @@ -67,7 +67,7 @@ /* (non-Javadoc) * @see dwtx.jface.resource.FontDescriptor#createFont(dwt.graphics.Device) */ - public Font createFont(Device device) { + public override Font createFont(Device device) { // If this descriptor is an existing font, then we can return the original font // if this is the same device. @@ -135,7 +135,7 @@ /* (non-Javadoc) * @see dwtx.jface.resource.FontDescriptor#destroyFont(dwt.graphics.Font) */ - public void destroyFont(Font previouslyCreatedFont) { + public override void destroyFont(Font previouslyCreatedFont) { if (previouslyCreatedFont is originalFont) { return; } diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/resource/ColorDescriptor.d --- a/dwtx/jface/resource/ColorDescriptor.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/resource/ColorDescriptor.d Fri Apr 11 01:24:25 2008 +0200 @@ -97,14 +97,14 @@ /* (non-Javadoc) * @see dwtx.jface.resource.DeviceResourceDescriptor#createResource(dwt.graphics.Device) */ - public final Object createResource(Device device){ + public override final Object createResource(Device device){ return createColor(device); } /* (non-Javadoc) * @see dwtx.jface.resource.DeviceResourceDescriptor#destroyResource(java.lang.Object) */ - public final void destroyResource(Object previouslyCreatedObject) { + public override final void destroyResource(Object previouslyCreatedObject) { destroyColor(cast(Color)previouslyCreatedObject); } } diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/resource/ColorRegistry.d --- a/dwtx/jface/resource/ColorRegistry.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/resource/ColorRegistry.d Fri Apr 11 01:24:25 2008 +0200 @@ -187,7 +187,7 @@ /* (non-Javadoc) * @see dwtx.jface.resource.ResourceRegistry#getKeySet() */ - public SetView!(String) getKeySet() { + public override SetView!(String) getKeySet() { auto res = new HashSet!(String); foreach( k,v; stringToRGB ){ res.add(k); @@ -220,7 +220,7 @@ /* (non-Javadoc) * @see dwtx.jface.resource.ResourceRegistry#clearCaches() */ - protected void clearCaches() { + protected override void clearCaches() { foreach( k, v; stringToColor ){ v.dispose(); } @@ -236,7 +236,7 @@ /* (non-Javadoc) * @see dwtx.jface.resource.ResourceRegistry#hasValueFor(java.lang.String) */ - public bool hasValueFor(String colorKey) { + public override bool hasValueFor(String colorKey) { return stringToRGB.containsKey(colorKey); } diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/resource/CompositeImageDescriptor.d --- a/dwtx/jface/resource/CompositeImageDescriptor.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/resource/CompositeImageDescriptor.d Fri Apr 11 01:24:25 2008 +0200 @@ -150,7 +150,7 @@ /* * (non-Javadoc) Method declared on ImageDesciptor. */ - public ImageData getImageData() { + public override ImageData getImageData() { Point size = getSize(); /* Create a 24 bit image data with alpha channel */ diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/resource/DerivedImageDescriptor.d --- a/dwtx/jface/resource/DerivedImageDescriptor.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/resource/DerivedImageDescriptor.d Fri Apr 11 01:24:25 2008 +0200 @@ -31,6 +31,7 @@ * @since 3.1 */ final class DerivedImageDescriptor : ImageDescriptor { + alias ImageDescriptor.createImage createImage; private ImageDescriptor original; private int flags; @@ -48,7 +49,7 @@ flags = swtFlags; } - public Object createResource(Device device) { + public override Object createResource(Device device) { try { return internalCreateImage(device); } catch (DWTException e) { @@ -56,7 +57,7 @@ } } - public Image createImage(Device device) { + public override Image createImage(Device device) { return internalCreateImage(device); } @@ -88,7 +89,7 @@ return result; } - public ImageData getImageData() { + public override ImageData getImageData() { Image image = internalCreateImage(Display.getCurrent()); ImageData result = image.getImageData(); image.dispose(); diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/resource/DeviceResourceException.d --- a/dwtx/jface/resource/DeviceResourceException.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/resource/DeviceResourceException.d Fri Apr 11 01:24:25 2008 +0200 @@ -60,7 +60,7 @@ * @return the cause or null * @since 3.1 */ - public Exception getCause() { + public override Exception getCause() { return cause; } diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/resource/DeviceResourceManager.d --- a/dwtx/jface/resource/DeviceResourceManager.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/resource/DeviceResourceManager.d Fri Apr 11 01:24:25 2008 +0200 @@ -44,7 +44,7 @@ /* (non-Javadoc) * @see dwtx.jface.resource.ResourceManager#getDevice() */ - public Device getDevice() { + public override Device getDevice() { return device; } @@ -60,21 +60,21 @@ /* (non-Javadoc) * @see dwtx.jface.resource.AbstractResourceManager#allocate(dwtx.jface.resource.DeviceResourceDescriptor) */ - protected Object allocate(DeviceResourceDescriptor descriptor){ + protected override Object allocate(DeviceResourceDescriptor descriptor){ return descriptor.createResource(device); } /* (non-Javadoc) * @see dwtx.jface.resource.AbstractResourceManager#deallocate(java.lang.Object, dwtx.jface.resource.DeviceResourceDescriptor) */ - protected void deallocate(Object resource, DeviceResourceDescriptor descriptor) { + protected override void deallocate(Object resource, DeviceResourceDescriptor descriptor) { descriptor.destroyResource(resource); } /* (non-Javadoc) * @see dwtx.jface.resource.ResourceManager#getDefaultImage() */ - protected Image getDefaultImage() { + protected override Image getDefaultImage() { if (missingImage is null) { missingImage = ImageDescriptor.getMissingImageDescriptor().createImage(); } @@ -84,7 +84,7 @@ /* (non-Javadoc) * @see dwtx.jface.resource.AbstractResourceManager#dispose() */ - public void dispose() { + public override void dispose() { super.dispose(); if (missingImage !is null) { missingImage.dispose(); diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/resource/FileImageDescriptor.d --- a/dwtx/jface/resource/FileImageDescriptor.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/resource/FileImageDescriptor.d Fri Apr 11 01:24:25 2008 +0200 @@ -73,7 +73,7 @@ /* (non-Javadoc) * Method declared on Object. */ - public bool equals(Object o) { + public override int opEquals(Object o) { if (!( cast(FileImageDescriptor)o )) { return false; } @@ -94,7 +94,7 @@ * Method declared on ImageDesciptor. * Returns null if the image data cannot be read. */ - public ImageData getImageData() { + public override ImageData getImageData() { InputStream in_ = getStream(); ImageData result = null; if (in_ !is null) { diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/resource/FontDescriptor.d --- a/dwtx/jface/resource/FontDescriptor.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/resource/FontDescriptor.d Fri Apr 11 01:24:25 2008 +0200 @@ -288,14 +288,14 @@ /* (non-Javadoc) * @see dwtx.jface.resource.DeviceResourceDescriptor#create(dwt.graphics.Device) */ - public final Object createResource(Device device) { + public override final Object createResource(Device device) { return createFont(device); } /* (non-Javadoc) * @see dwtx.jface.resource.DeviceResourceDescriptor#destroy(java.lang.Object) */ - public final void destroyResource(Object previouslyCreatedObject) { + public override final void destroyResource(Object previouslyCreatedObject) { destroyFont(cast(Font)previouslyCreatedObject); } } diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/resource/FontRegistry.d --- a/dwtx/jface/resource/FontRegistry.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/resource/FontRegistry.d Fri Apr 11 01:24:25 2008 +0200 @@ -705,7 +705,7 @@ /* (non-Javadoc) * @see dwtx.jface.resource.ResourceRegistry#getKeySet() */ - public SetView!(String) getKeySet() { + public override SetView!(String) getKeySet() { auto res = new HashSet!(String); foreach( k, v; stringToFontData ){ res.add( k ); @@ -716,14 +716,14 @@ /* (non-Javadoc) * @see dwtx.jface.resource.ResourceRegistry#hasValueFor(java.lang.String) */ - public bool hasValueFor(String fontKey) { + public override bool hasValueFor(String fontKey) { return stringToFontData.containsKey(fontKey); } /* (non-Javadoc) * @see dwtx.jface.resource.ResourceRegistry#clearCaches() */ - protected void clearCaches() { + protected override void clearCaches() { foreach( k,v; stringToFontRecord ){ v.dispose(); } diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/resource/ImageDataImageDescriptor.d --- a/dwtx/jface/resource/ImageDataImageDescriptor.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/resource/ImageDataImageDescriptor.d Fri Apr 11 01:24:25 2008 +0200 @@ -56,7 +56,7 @@ /* (non-Javadoc) * @see dwtx.jface.resource.DeviceResourceDescriptor#create(dwt.graphics.Device) */ - public Object createResource(Device device) { + public override Object createResource(Device device) { // If this descriptor is an existing font, then we can return the original font // if this is the same device. @@ -73,7 +73,7 @@ /* (non-Javadoc) * @see dwtx.jface.resource.DeviceResourceDescriptor#destroy(java.lang.Object) */ - public void destroyResource(Object previouslyCreatedObject) { + public override void destroyResource(Object previouslyCreatedObject) { if (previouslyCreatedObject is originalImage) { return; } @@ -84,7 +84,7 @@ /* (non-Javadoc) * @see dwtx.jface.resource.ImageDescriptor#getImageData() */ - public ImageData getImageData() { + public override ImageData getImageData() { return data; } diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/resource/ImageDescriptor.d --- a/dwtx/jface/resource/ImageDescriptor.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/resource/ImageDescriptor.d Fri Apr 11 01:24:25 2008 +0200 @@ -176,7 +176,7 @@ /* (non-Javadoc) * @see dwtx.jface.resource.DeviceResourceDescriptor#createResource(dwt.graphics.Device) */ - public Object createResource(Device device) { + public override Object createResource(Device device) { Image result = createImage(false, device); if (result is null) { throw new DeviceResourceException(this); @@ -187,7 +187,7 @@ /* (non-Javadoc) * @see dwtx.jface.resource.DeviceResourceDescriptor#destroyResource(Object) */ - public void destroyResource(Object previouslyCreatedObject) { + public override void destroyResource(Object previouslyCreatedObject) { (cast(Image)previouslyCreatedObject).dispose(); } diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/resource/ImageRegistry.d --- a/dwtx/jface/resource/ImageRegistry.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/resource/ImageRegistry.d Fri Apr 11 01:24:25 2008 +0200 @@ -99,7 +99,7 @@ this.originalDisplay = originalDisplay; } - public Object createResource(Device device) { + public override Object createResource(Device device) { if (device is originalDisplay) { refCount++; return original; @@ -107,7 +107,7 @@ return super.createResource(device); } - public void destroyResource(Object toDispose) { + public override void destroyResource(Object toDispose) { if (original is toDispose) { refCount--; if (refCount is 0) { @@ -122,7 +122,7 @@ /* (non-Javadoc) * @see dwtx.jface.resource.ImageDescriptor#getImageData() */ - public ImageData getImageData() { + public override ImageData getImageData() { return original.getImageData(); } } diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/resource/LocalResourceManager.d --- a/dwtx/jface/resource/LocalResourceManager.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/resource/LocalResourceManager.d Fri Apr 11 01:24:25 2008 +0200 @@ -77,21 +77,21 @@ /* (non-Javadoc) * @see dwtx.jface.resource.ResourceManager#getDevice() */ - public Device getDevice() { + public override Device getDevice() { return parentRegistry.getDevice(); } /* (non-Javadoc) * @see dwtx.jface.resource.AbstractResourceManager#allocate(dwtx.jface.resource.DeviceResourceDescriptor) */ - protected Object allocate(DeviceResourceDescriptor descriptor) { + protected override Object allocate(DeviceResourceDescriptor descriptor) { return parentRegistry.create(descriptor); } /* (non-Javadoc) * @see dwtx.jface.resource.AbstractResourceManager#deallocate(java.lang.Object, dwtx.jface.resource.DeviceResourceDescriptor) */ - protected void deallocate(Object resource, + protected override void deallocate(Object resource, DeviceResourceDescriptor descriptor) { parentRegistry.destroy(descriptor); @@ -100,7 +100,7 @@ /* (non-Javadoc) * @see dwtx.jface.resource.ResourceManager#getDefaultImage() */ - protected Image getDefaultImage() { + protected override Image getDefaultImage() { return parentRegistry.getDefaultImage_(); } } diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/resource/MissingImageDescriptor.d --- a/dwtx/jface/resource/MissingImageDescriptor.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/resource/MissingImageDescriptor.d Fri Apr 11 01:24:25 2008 +0200 @@ -37,7 +37,7 @@ /* (non-Javadoc) * Method declared on ImageDesciptor. */ - public ImageData getImageData() { + public override ImageData getImageData() { return DEFAULT_IMAGE_DATA; } diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/resource/RGBColorDescriptor.d --- a/dwtx/jface/resource/RGBColorDescriptor.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/resource/RGBColorDescriptor.d Fri Apr 11 01:24:25 2008 +0200 @@ -76,7 +76,7 @@ /* (non-Javadoc) * @see dwtx.jface.resources.ColorDescriptor#createColor() */ - public Color createColor(Device device) { + public override Color createColor(Device device) { // If this descriptor is wrapping an existing color, then we can return the original color // if this is the same device. if (originalColor !is null) { @@ -92,7 +92,7 @@ /* (non-Javadoc) * @see dwtx.jface.resource.ColorDescriptor#destroyColor(dwt.graphics.Color) */ - public void destroyColor(Color toDestroy) { + public override void destroyColor(Color toDestroy) { if (toDestroy is originalColor) { return; } diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/resource/URLImageDescriptor.d --- a/dwtx/jface/resource/URLImageDescriptor.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/resource/URLImageDescriptor.d Fri Apr 11 01:24:25 2008 +0200 @@ -46,7 +46,7 @@ /* (non-Javadoc) * Method declared on Object. */ - public bool equals(Object o) { + public override int opEquals(Object o) { if (!(cast(URLImageDescriptor)o )) { return false; } @@ -57,7 +57,7 @@ * Method declared on ImageDesciptor. * Returns null if the image data cannot be read. */ - public ImageData getImageData() { + public override ImageData getImageData() { ImageData result = null; InputStream in_ = getStream(); if (in_ !is null) { diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/util/LocalSelectionTransfer.d --- a/dwtx/jface/util/LocalSelectionTransfer.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/util/LocalSelectionTransfer.d Fri Apr 11 01:24:25 2008 +0200 @@ -99,7 +99,7 @@ * * @return the type id used to identify this transfer. */ - protected int[] getTypeIds() { + protected override int[] getTypeIds() { return [ TYPEID ]; } @@ -108,7 +108,7 @@ * * @return the type name used to identify this transfer. */ - protected String[] getTypeNames() { + protected override String[] getTypeNames() { return [ TYPE_NAME ]; } @@ -120,7 +120,7 @@ * * @see dwt.dnd.ByteArrayTransfer#javaToNative(java.lang.Object, dwt.dnd.TransferData) */ - public void javaToNative(Object object, TransferData transferData) { + public override void javaToNative(Object object, TransferData transferData) { auto check = new ArrayWrapperByte( cast(byte[])TYPE_NAME ); super.javaToNative(check, transferData); } @@ -131,7 +131,7 @@ * * @see dwt.dnd.ByteArrayTransfer#nativeToJava(TransferData) */ - public Object nativeToJava(TransferData transferData) { + public override Object nativeToJava(TransferData transferData) { Object result = super.nativeToJava(transferData); if (isInvalidNativeType(result)) { Policy.getLog().log(new Status( diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/util/SafeRunnableDialog.d --- a/dwtx/jface/util/SafeRunnableDialog.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/util/SafeRunnableDialog.d Fri Apr 11 01:24:25 2008 +0200 @@ -99,7 +99,7 @@ * * @see dwtx.jface.dialogs.ErrorDialog#createDialogArea(dwt.widgets.Composite) */ - protected Control createDialogArea(Composite parent) { + protected override Control createDialogArea(Composite parent) { Control area = super.createDialogArea(parent); createStatusList(cast(Composite) area); return area; @@ -325,7 +325,7 @@ * * @see dwtx.jface.dialogs.ErrorDialog#shouldShowDetailsButton() */ - protected bool shouldShowDetailsButton() { + protected override bool shouldShowDetailsButton() { return true; } diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/viewers/AbstractListViewer.d --- a/dwtx/jface/viewers/AbstractListViewer.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/viewers/AbstractListViewer.d Fri Apr 11 01:24:25 2008 +0200 @@ -44,6 +44,8 @@ * @since 3.0 */ public abstract class AbstractListViewer : StructuredViewer { + alias StructuredViewer.internalRefresh internalRefresh; + alias StructuredViewer.setSelectionToWidget setSelectionToWidget; /** * A list of viewer elements (element type: Object). @@ -229,7 +231,7 @@ * Method declared on StructuredViewer. * Since DWT.List doesn't use items we always return the List itself. */ - protected Widget doFindInputItem(Object element) { + protected override Widget doFindInputItem(Object element) { if (element !is null && opEquals(element, getRoot())) { return getControl(); } @@ -240,7 +242,7 @@ * Method declared on StructuredViewer. * Since DWT.List doesn't use items we always return the List itself. */ - protected Widget doFindItem(Object element) { + protected override Widget doFindItem(Object element) { if (element !is null) { if (listMapContains(element)) { return getControl(); @@ -252,7 +254,7 @@ /* (non-Javadoc) * Method declared on StructuredViewer. */ - protected void doUpdateItem(Widget data, Object element, bool fullMap) { + protected override void doUpdateItem(Widget data, Object element, bool fullMap) { if (element !is null) { int ix = getElementIndex(element); if (ix >= 0) { @@ -265,7 +267,7 @@ /* (non-Javadoc) * Method declared on Viewer. */ - public abstract Control getControl(); + public override abstract Control getControl(); /** * Returns the element with the given index from this list viewer. @@ -287,7 +289,7 @@ * method returns the label provider, which in the case of list * viewers will be an instance of ILabelProvider. */ - public IBaseLabelProvider getLabelProvider() { + public override IBaseLabelProvider getLabelProvider() { return super.getLabelProvider(); } @@ -297,7 +299,7 @@ /* (non-Javadoc) * Method declared on StructuredViewer. */ - protected SeqView!(Object) getSelectionFromWidget() { + protected override SeqView!(Object) getSelectionFromWidget() { int[] ixs = listGetSelectionIndices(); ArraySeq!(Object) list = new ArraySeq!(Object); list.capacity(ixs.length); @@ -349,7 +351,7 @@ /* (non-Javadoc) * Method declared on Viewer. */ - protected void inputChanged(Object input, Object oldInput) { + protected override void inputChanged(Object input, Object oldInput) { listMap.clear(); Object[] children = getSortedChildren(getRoot()); int size = children.length; @@ -368,7 +370,7 @@ /* (non-Javadoc) * Method declared on StructuredViewer. */ - protected void internalRefresh(Object element) { + protected override void internalRefresh(Object element) { Control list = getControl(); if (element is null || opEquals(element, getRoot())) { // the parent @@ -507,7 +509,7 @@ * The optional interfaces {@link IColorProvider} and * {@link IFontProvider} have no effect for this type of viewer */ - public void setLabelProvider(IBaseLabelProvider labelProvider) { + public override void setLabelProvider(IBaseLabelProvider labelProvider) { Assert.isTrue( null !is cast(ILabelProvider)labelProvider ); super.setLabelProvider(labelProvider); } @@ -515,7 +517,7 @@ /* (non-Javadoc) * Method declared on StructuredViewer. */ - protected void setSelectionToWidget(SeqView!(Object) in_, bool reveal) { + protected override void setSelectionToWidget(SeqView!(Object) in_, bool reveal) { if (in_ is null || in_.size() is 0) { // clear selection listDeselectAll(); } else { diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/viewers/AbstractTableViewer.d --- a/dwtx/jface/viewers/AbstractTableViewer.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/viewers/AbstractTableViewer.d Fri Apr 11 01:24:25 2008 +0200 @@ -49,6 +49,8 @@ * @since 3.3 */ public abstract class AbstractTableViewer : ColumnViewer { + alias ColumnViewer.getLabelProvider getLabelProvider; + alias ColumnViewer.setSelectionToWidget setSelectionToWidget; private class VirtualManager { @@ -221,7 +223,7 @@ super(); } - protected void hookControl(Control control) { + protected override void hookControl(Control control) { super.hookControl(control); initializeVirtualManager(getControl().getStyle()); } @@ -322,7 +324,7 @@ * * @see dwtx.jface.viewers.StructuredViewer#doFindInputItem(java.lang.Object) */ - protected Widget doFindInputItem(Object element) { + protected override Widget doFindInputItem(Object element) { if (opEquals(element, getRoot())) { return getControl(); } @@ -334,7 +336,7 @@ * * @see dwtx.jface.viewers.StructuredViewer#doFindItem(java.lang.Object) */ - protected Widget doFindItem(Object element) { + protected override Widget doFindItem(Object element) { Item[] children = doGetItems(); for (int i = 0; i < children.length; i++) { @@ -354,7 +356,7 @@ * @see dwtx.jface.viewers.StructuredViewer#doUpdateItem(dwt.widgets.Widget, * java.lang.Object, bool) */ - protected void doUpdateItem(Widget widget, Object element, bool fullMap) { + protected override void doUpdateItem(Widget widget, Object element, bool fullMap) { bool oldBusy = busy; busy = true; try { @@ -422,7 +424,7 @@ * * @see dwtx.jface.viewers.ColumnViewer#getColumnViewerOwner(int) */ - protected Widget getColumnViewerOwner(int columnIndex) { + protected override Widget getColumnViewerOwner(int columnIndex) { int columnCount = doGetColumnCount(); if (columnIndex < 0 @@ -468,7 +470,7 @@ * then it provides only the label text and image for the first column, and * any remaining columns are blank. */ - public IBaseLabelProvider getLabelProvider() { + public override IBaseLabelProvider getLabelProvider() { return super.getLabelProvider(); } @@ -477,7 +479,7 @@ * * @see dwtx.jface.viewers.StructuredViewer#getSelectionFromWidget() */ - protected SeqView!(Object) getSelectionFromWidget() { + protected override SeqView!(Object) getSelectionFromWidget() { if (virtualManager !is null) { return getVirtualSelection(); } @@ -582,7 +584,7 @@ * @see dwtx.jface.viewers.Viewer#inputChanged(java.lang.Object, * java.lang.Object) */ - protected void inputChanged(Object input, Object oldInput) { + protected override void inputChanged(Object input, Object oldInput) { getControl().setRedraw(false); try { preservingSelection(new class Runnable { @@ -630,7 +632,7 @@ * * @see dwtx.jface.viewers.StructuredViewer#internalRefresh(java.lang.Object) */ - protected void internalRefresh(Object element) { + protected override void internalRefresh(Object element) { internalRefresh(element, true); } @@ -640,7 +642,7 @@ * @see dwtx.jface.viewers.StructuredViewer#internalRefresh(java.lang.Object, * bool) */ - protected void internalRefresh(Object element, bool updateLabels) { + protected override void internalRefresh(Object element, bool updateLabels) { applyEditorValue(); if (element is null || opEquals(element, getRoot())) { if (virtualManager is null) { @@ -862,7 +864,7 @@ * * @see dwtx.jface.viewers.StructuredViewer#reveal(java.lang.Object) */ - public void reveal(Object element) { + public override void reveal(Object element) { Assert.isNotNull(element); Widget w = findItem(element); if (auto i = cast(Item)w ) { @@ -876,7 +878,7 @@ * @see dwtx.jface.viewers.StructuredViewer#setSelectionToWidget(java.util.List, * bool) */ - protected void setSelectionToWidget(SeqView!(Object) list, bool reveal) { + protected override void setSelectionToWidget(SeqView!(Object) list, bool reveal) { if (list is null) { doDeselectAll(); return; @@ -1073,7 +1075,7 @@ * * @see dwtx.jface.viewers.StructuredViewer#getRawChildren(java.lang.Object) */ - protected Object[] getRawChildren(Object parent) { + protected override Object[] getRawChildren(Object parent) { Assert.isTrue(!( null !is cast(ILazyContentProvider) getContentProvider() ), "Cannot get raw children with an ILazyContentProvider");//$NON-NLS-1$ @@ -1086,7 +1088,7 @@ * * @see dwtx.jface.viewers.StructuredViewer#assertContentProviderType(dwtx.jface.viewers.IContentProvider) */ - protected void assertContentProviderType(IContentProvider provider) { + protected override void assertContentProviderType(IContentProvider provider) { Assert.isTrue(null !is cast(IStructuredContentProvider)provider || null !is cast(ILazyContentProvider)provider ); } diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/viewers/AbstractTreeViewer.d --- a/dwtx/jface/viewers/AbstractTreeViewer.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/viewers/AbstractTreeViewer.d Fri Apr 11 01:24:25 2008 +0200 @@ -85,8 +85,8 @@ * @see TreeViewer */ public abstract class AbstractTreeViewer : ColumnViewer { - alias ColumnViewer.buildLabel buildLabel; + alias ColumnViewer.filter filter; alias ColumnViewer.setSelection setSelection; /** @@ -606,7 +606,7 @@ * * @see dwtx.jface.viewers.StructuredViewer#getSortedChildren(java.lang.Object) */ - protected Object[] getSortedChildren(Object parentElementOrTreePath) { + protected override Object[] getSortedChildren(Object parentElementOrTreePath) { Object[] result = getFilteredChildren(parentElementOrTreePath); ViewerComparator comparator = getComparator(); if (parentElementOrTreePath !is null @@ -640,7 +640,7 @@ * * @see dwtx.jface.viewers.StructuredViewer#getFilteredChildren(java.lang.Object) */ - protected Object[] getFilteredChildren(Object parentElementOrTreePath) { + protected override Object[] getFilteredChildren(Object parentElementOrTreePath) { Object[] result = getRawChildren(parentElementOrTreePath); ViewerFilter[] filters = getFilters(); for (int i = 0; i < filters.length; i++) { @@ -713,7 +713,7 @@ * * @see StructuredViewer#associate(Object, Item) */ - protected void associate(Object element, Item item) { + protected override void associate(Object element, Item item) { Object data = item.getData(); if (data !is null && data !is element && opEquals(data, element)) { // workaround for PR 1FV62BT @@ -846,7 +846,7 @@ * The AbstractTreeViewer implementation of this method also * recurses over children of the corresponding element. */ - protected void disassociate(Item item) { + protected override void disassociate(Item item) { super.disassociate(item); // recursively unmapping the items is only required when // the hash map is used. In the other case disposing @@ -873,7 +873,7 @@ } /* (non-Javadoc) Method declared on StructuredViewer. */ - protected Widget doFindInputItem(Object element) { + protected override Widget doFindInputItem(Object element) { // compare with root Object root = getRoot(); if (root is null) { @@ -887,7 +887,7 @@ } /* (non-Javadoc) Method declared on StructuredViewer. */ - protected Widget doFindItem(Object element) { + protected override Widget doFindItem(Object element) { // compare with root Object root = getRoot(); if (root is null) { @@ -1005,7 +1005,7 @@ /* (non-Javadoc) Method declared on StructuredViewer. */ - protected void doUpdateItem(Widget widget, Object element, bool fullMap) { + protected override void doUpdateItem(Widget widget, Object element, bool fullMap) { bool oldBusy = busy; busy = true; try { @@ -1326,7 +1326,7 @@ } /* (non-Javadoc) Method declared on StructuredViewer. */ - protected Object[] getRawChildren(Object parentElementOrTreePath) { + protected override Object[] getRawChildren(Object parentElementOrTreePath) { bool oldBusy = busy; busy = true; try { @@ -1386,7 +1386,7 @@ * * @see dwtx.jface.viewers.StructuredViewer#getSelectionFromWidget() */ - protected SeqView!(Object) getSelectionFromWidget() { + protected override SeqView!(Object) getSelectionFromWidget() { Widget[] items = getSelection(getControl()); ArraySeq!(Object) list = new ArraySeq!(Object); list.capacity(items.length); @@ -1406,7 +1406,7 @@ * * @see dwtx.jface.viewers.StructuredViewer#handleDoubleSelect(dwt.events.SelectionEvent) */ - protected void handleDoubleSelect(SelectionEvent event) { + protected override void handleDoubleSelect(SelectionEvent event) { // handle case where an earlier selection listener disposed the control. Control control = getControl(); if (control !is null && !control.isDisposed()) { @@ -1458,7 +1458,7 @@ } /* (non-Javadoc) Method declared on Viewer. */ - protected void hookControl(Control control) { + protected override void hookControl(Control control) { super.hookControl(control); addTreeListener(control, new class TreeListener { public void treeExpanded(TreeEvent event) { @@ -1475,7 +1475,7 @@ * (non-Javadoc) Method declared on StructuredViewer. Builds the initial * tree and handles the automatic expand feature. */ - protected void inputChanged(Object input, Object oldInput) { + protected override void inputChanged(Object input, Object oldInput) { preservingSelection(new class Runnable { public void run() { Control tree = getControl(); @@ -1780,12 +1780,12 @@ } /* (non-Javadoc) Method declared on StructuredViewer. */ - protected void internalRefresh(Object element) { + protected override void internalRefresh(Object element) { internalRefresh(element, true); } /* (non-Javadoc) Method declared on StructuredViewer. */ - protected void internalRefresh(Object element, bool updateLabels) { + protected override void internalRefresh(Object element, bool updateLabels) { Trace.formatln( "{} {}: ", __FILE__, __LINE__ ); PrintStackTrace(); // If element is null, do a full refresh. @@ -2086,7 +2086,7 @@ } /* (non-Javadoc) Method declared on Viewer. */ - protected void labelProviderChanged() { + protected override void labelProviderChanged() { // we have to walk the (visible) tree and update every item Control tree = getControl(); tree.setRedraw(false); @@ -2217,7 +2217,7 @@ /** * This implementation of reveal() reveals the given element or tree path. */ - public void reveal(Object elementOrTreePath) { + public override void reveal(Object elementOrTreePath) { Assert.isNotNull(elementOrTreePath); Widget w = internalExpand(elementOrTreePath, true); if ( auto item = cast(Item)w ) { @@ -2243,7 +2243,7 @@ } /* (non-Javadoc) Method declared on Viewer. */ - public Item scrollDown(int x, int y) { + public override Item scrollDown(int x, int y) { Item current = getItem(x, y); if (current !is null) { Item next = getNextItem(current, true); @@ -2254,7 +2254,7 @@ } /* (non-Javadoc) Method declared on Viewer. */ - public Item scrollUp(int x, int y) { + public override Item scrollUp(int x, int y) { Item current = getItem(x, y); if (current !is null) { Item previous = getPreviousItem(current); @@ -2287,12 +2287,12 @@ * checks to ensure that the content provider is an * ITreeContentProvider. */ - public void setContentProvider(IContentProvider provider) { + public override void setContentProvider(IContentProvider provider) { // the actual check is in assertContentProviderType super.setContentProvider(provider); } - protected void assertContentProviderType(IContentProvider provider) { + protected override void assertContentProviderType(IContentProvider provider) { Assert.isTrue(cast(ITreeContentProvider)provider || cast(ITreePathContentProvider)provider ); } @@ -2429,7 +2429,7 @@ * This implementation of setSelectionToWidget accepts a list of elements or * a list of tree paths. */ - protected void setSelectionToWidget(SeqView!(Object) v, bool reveal) { + protected override void setSelectionToWidget(SeqView!(Object) v, bool reveal) { if (v is null) { setSelection(new ArraySeq!(Item)); return; @@ -2810,7 +2810,7 @@ * * @since 3.2 */ - public ISelection getSelection() { + public override ISelection getSelection() { Control control = getControl(); if (control is null || control.isDisposed()) { return TreeSelection.EMPTY; @@ -2827,7 +2827,7 @@ return new TreeSelection( list.toArray(), getComparer()); } - protected void setSelectionToWidget(ISelection selection, bool reveal) { + protected override void setSelectionToWidget(ISelection selection, bool reveal) { if ( auto treeSelection = cast(ITreeSelection)selection ) { auto list = new ArraySeq!(Object); auto paths = treeSelection.getPaths(); @@ -2942,7 +2942,7 @@ * * @see dwtx.jface.viewers.ColumnViewer#getColumnViewerOwner(int) */ - protected Widget getColumnViewerOwner(int columnIndex) { + protected override Widget getColumnViewerOwner(int columnIndex) { // Return null by default return null; } @@ -2953,7 +2953,7 @@ * * @since 3.3 */ - protected Item getItemAt(Point point) { + protected override Item getItemAt(Point point) { return null; } @@ -2963,7 +2963,7 @@ * * @since 3.3 */ - protected ColumnViewerEditor createViewerEditor() { + protected override ColumnViewerEditor createViewerEditor() { return null; } @@ -2976,7 +2976,7 @@ * * @since 3.3 */ - protected int doGetColumnCount() { + protected override int doGetColumnCount() { return 0; } @@ -2992,7 +2992,7 @@ * @see dwtx.jface.viewers.StructuredViewer#buildLabel(dwtx.jface.viewers.ViewerLabel, * java.lang.Object) */ - protected void buildLabel(ViewerLabel updateLabel, Object elementOrPath) { + protected override void buildLabel(ViewerLabel updateLabel, Object elementOrPath) { Trace.formatln( "{} {}:", __FILE__, __LINE__ ); Object element; if (auto path = cast(TreePath)elementOrPath ) { @@ -3028,7 +3028,7 @@ /* * Subclasses should implement */ - protected ViewerRow getViewerRowFromItem(Widget item) { + protected override ViewerRow getViewerRowFromItem(Widget item) { return null; } } diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/viewers/AcceptAllFilter.d --- a/dwtx/jface/viewers/AcceptAllFilter.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/viewers/AcceptAllFilter.d Fri Apr 11 01:24:25 2008 +0200 @@ -56,7 +56,7 @@ /* (non-Javadoc) * @see java.lang.Object#equals(java.lang.Object) */ - public bool equals(Object other) { + public override int opEquals(Object other) { return other is this || null !is cast(AcceptAllFilter)other ; } diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/viewers/CheckboxCellEditor.d --- a/dwtx/jface/viewers/CheckboxCellEditor.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/viewers/CheckboxCellEditor.d Fri Apr 11 01:24:25 2008 +0200 @@ -86,7 +86,7 @@ * the toggling of the checkbox control and notifies * listeners with ICellEditorListener.applyEditorValue. */ - public void activate() { + public override void activate() { value = !value; fireApplyEditorValue(); } @@ -96,7 +96,7 @@ * this CellEditor framework method does * nothing and returns null. */ - protected Control createControl(Composite parent) { + protected override Control createControl(Composite parent) { return null; } @@ -107,14 +107,14 @@ * * @return the bool checkbox value */ - protected Object doGetValue() { + protected override Object doGetValue() { return new ValueWrapperBool( value ); } /* (non-Javadoc) * Method declared on CellEditor. */ - protected void doSetFocus() { + protected override void doSetFocus() { // Ignore } @@ -125,12 +125,12 @@ * * @param value a bool value */ - protected void doSetValue(Object value) { + protected override void doSetValue(Object value) { Assert.isTrue( null !is cast(ValueWrapperBool)value ); this.value = (cast(ValueWrapperBool) value).value; } - public void activate(ColumnViewerEditorActivationEvent activationEvent) { + public override void activate(ColumnViewerEditorActivationEvent activationEvent) { if (activationEvent.eventType !is ColumnViewerEditorActivationEvent.TRAVERSAL) { super.activate(activationEvent); } diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/viewers/CheckboxTableViewer.d --- a/dwtx/jface/viewers/CheckboxTableViewer.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/viewers/CheckboxTableViewer.d Fri Apr 11 01:24:25 2008 +0200 @@ -48,6 +48,7 @@ *

*/ public class CheckboxTableViewer : TableViewer, ICheckable { + alias TableViewer.preservingSelection preservingSelection; /** * List of check state listeners (element type: ICheckStateListener). @@ -276,7 +277,7 @@ /* (non-Javadoc) * Method declared on StructuredViewer. */ - public void handleSelect(SelectionEvent event) { + public override void handleSelect(SelectionEvent event) { if (event.detail is DWT.CHECK) { super.handleSelect(event); // this will change the current selection @@ -294,7 +295,7 @@ /* (non-Javadoc) * Method declared on Viewer. */ - protected void preservingSelection(Runnable updateCode) { + protected override void preservingSelection(Runnable updateCode) { TableItem[] children = getTable().getItems(); CustomHashtable checked = newHashtable(children.length * 2 + 1); diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/viewers/CheckboxTreeViewer.d --- a/dwtx/jface/viewers/CheckboxTreeViewer.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/viewers/CheckboxTreeViewer.d Fri Apr 11 01:24:25 2008 +0200 @@ -47,6 +47,7 @@ *

*/ public class CheckboxTreeViewer : TreeViewer, ICheckable { + alias TreeViewer.preservingSelection preservingSelection; /** * List of check state listeners (element type: ICheckStateListener). @@ -247,7 +248,7 @@ /* (non-Javadoc) * Method declared on StructuredViewer. */ - protected void handleDoubleSelect(SelectionEvent event) { + protected override void handleDoubleSelect(SelectionEvent event) { if (lastClickedItem !is null) { TreeItem item = lastClickedItem; @@ -267,7 +268,7 @@ /* (non-Javadoc) * Method declared on StructuredViewer. */ - protected void handleSelect(SelectionEvent event) { + protected override void handleSelect(SelectionEvent event) { lastClickedItem = null; if (event.detail is DWT.CHECK) { @@ -373,7 +374,7 @@ /* (non-Javadoc) * Method declared on Viewer. */ - protected void preservingSelection(Runnable updateCode) { + protected override void preservingSelection(Runnable updateCode) { int n = getItemCount(getControl()); CustomHashtable checkedNodes = newHashtable(n * 2 + 1); diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/viewers/ColorCellEditor.d --- a/dwtx/jface/viewers/ColorCellEditor.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/viewers/ColorCellEditor.d Fri Apr 11 01:24:25 2008 +0200 @@ -79,7 +79,7 @@ * Internal class for laying out this cell editor. */ private class ColorCellLayout : Layout { - public Point computeSize(Composite editor, int wHint, int hHint, + public override Point computeSize(Composite editor, int wHint, int hHint, bool force) { if (wHint !is DWT.DEFAULT && hHint !is DWT.DEFAULT) { return new Point(wHint, hHint); @@ -92,7 +92,7 @@ colorSize.y, rgbSize.y)); } - public void layout(Composite editor, bool force) { + public override void layout(Composite editor, bool force) { Rectangle bounds = editor.getClientArea(); Point colorSize = colorLabel.computeSize(DWT.DEFAULT, DWT.DEFAULT, force); @@ -191,7 +191,7 @@ /* (non-Javadoc) * Method declared on DialogCellEditor. */ - protected Control createContents(Composite cell) { + protected override Control createContents(Composite cell) { Color bg = cell.getBackground(); composite = new Composite(cell, getStyle()); composite.setBackground(bg); @@ -207,7 +207,7 @@ /* (non-Javadoc) * Method declared on CellEditor. */ - public void dispose() { + public override void dispose() { if (image !is null) { image.dispose(); image = null; @@ -218,7 +218,7 @@ /* (non-Javadoc) * Method declared on DialogCellEditor. */ - protected Object openDialogBox(Control cellEditorWindow) { + protected override Object openDialogBox(Control cellEditorWindow) { ColorDialog dialog = new ColorDialog(cellEditorWindow.getShell()); Object value = getValue(); if (value !is null) { @@ -231,7 +231,7 @@ /* (non-Javadoc) * Method declared on DialogCellEditor. */ - protected void updateContents(Object value) { + protected override void updateContents(Object value) { RGB rgb = cast(RGB) value; // XXX: We don't have a value the first time this method is called". if (rgb is null) { diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/viewers/ColumnLabelProvider.d --- a/dwtx/jface/viewers/ColumnLabelProvider.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/viewers/ColumnLabelProvider.d Fri Apr 11 01:24:25 2008 +0200 @@ -41,7 +41,7 @@ /* (non-Javadoc) * @see dwtx.jface.viewers.CellLabelProvider#update(dwtx.jface.viewers.ViewerCell) */ - public void update(ViewerCell cell) { + public override void update(ViewerCell cell) { Object element = cell.getElement(); cell.setText(getText(element)); Image image = getImage(element); diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/viewers/ColumnViewer.d --- a/dwtx/jface/viewers/ColumnViewer.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/viewers/ColumnViewer.d Fri Apr 11 01:24:25 2008 +0200 @@ -58,9 +58,9 @@ * */ public abstract class ColumnViewer : StructuredViewer { - alias StructuredViewer.getLabelProvider getLabelProvider; alias StructuredViewer.refresh refresh; + alias StructuredViewer.update update; private CellEditor[] cellEditors; @@ -106,7 +106,7 @@ return false; } - protected void hookControl(Control control) { + protected override void hookControl(Control control) { super.hookControl(control); viewerEditor = createViewerEditor(); hookEditingSupport(control); @@ -379,7 +379,7 @@ * * @see dwtx.jface.viewers.StructuredViewer#getItem(int, int) */ - protected Item getItem(int x, int y) { + protected override Item getItem(int x, int y) { return getItemAt(getControl().toControl(x, y)); } @@ -404,7 +404,8 @@ *

* */ - public void setLabelProvider(IBaseLabelProvider labelProvider) { + public override void setLabelProvider(IBaseLabelProvider labelProvider) { + Trace.formatln( "{} {}: setLabelProvider", __FILE__, __LINE__ ); Assert.isTrue( null !is cast(ITableLabelProvider)labelProvider || null !is cast(ILabelProvider)labelProvider || null !is cast(CellLabelProvider)labelProvider ); @@ -420,7 +421,9 @@ ViewerColumn column; int i = 0; + Trace.formatln( "{} {}: updateColumnParts", __FILE__, __LINE__ ); while ((column = getViewerColumn(i++)) !is null) { + Trace.formatln( "{} {}: updateColumnParts loop", __FILE__, __LINE__ ); column.setLabelProvider(CellLabelProvider .createViewerLabelProvider(this, labelProvider), false); } @@ -566,7 +569,7 @@ return false; } - public void refresh(Object element) { + public override void refresh(Object element) { if (isBusy()) return; @@ -577,7 +580,7 @@ super.refresh(element); } - public void refresh(Object element, bool updateLabels) { + public override void refresh(Object element, bool updateLabels) { if (isBusy()) return; @@ -588,7 +591,7 @@ super.refresh(element, updateLabels); } - public void update(Object element, String[] properties) { + public override void update(Object element, String[] properties) { if (isBusy()) return; super.update(element, properties); @@ -735,7 +738,7 @@ return viewerEditor; } - protected Object[] getRawChildren(Object parent) { + protected override Object[] getRawChildren(Object parent) { bool oldBusy = busy; busy = true; try { diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/viewers/ColumnViewerToolTipSupport.d --- a/dwtx/jface/viewers/ColumnViewerToolTipSupport.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/viewers/ColumnViewerToolTipSupport.d Fri Apr 11 01:24:25 2008 +0200 @@ -96,11 +96,11 @@ new ColumnViewerToolTipSupport(viewer,style,false); } - protected Object getToolTipArea(Event event) { + protected override Object getToolTipArea(Event event) { return viewer.getCell(new Point(event.x,event.y)); } - protected final bool shouldCreateToolTip(Event event) { + protected override final bool shouldCreateToolTip(Event event) { if( ! super.shouldCreateToolTip(event) ) { return false; } @@ -165,7 +165,7 @@ return rv; } - protected void afterHideToolTip(Event event) { + protected override void afterHideToolTip(Event event) { if (event !is null && event.widget !is viewer.getControl()) { if (event.type is DWT.MouseDown) { viewer.setSelection(new StructuredSelection()); diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/viewers/ComboBoxCellEditor.d --- a/dwtx/jface/viewers/ComboBoxCellEditor.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/viewers/ComboBoxCellEditor.d Fri Apr 11 01:24:25 2008 +0200 @@ -132,7 +132,7 @@ /* (non-Javadoc) * Method declared on CellEditor. */ - protected Control createControl(Composite parent) { + protected override Control createControl(Composite parent) { comboBox = new CCombo(parent, getStyle()); comboBox.setFont(parent.getFont()); @@ -181,14 +181,14 @@ * @return the zero-based index of the current selection wrapped * as an Integer */ - protected Object doGetValue() { + protected override Object doGetValue() { return new ValueWrapperInt(selection); } /* (non-Javadoc) * Method declared on CellEditor. */ - protected void doSetFocus() { + protected override void doSetFocus() { comboBox.setFocus(); } @@ -200,7 +200,7 @@ * else it is 60 pixels to make sure the arrow button and some text is visible. * The list of CCombo will be wide enough to show its longest item. */ - public LayoutData getLayoutData() { + public override LayoutData getLayoutData() { LayoutData layoutData = super.getLayoutData(); if ((comboBox is null) || comboBox.isDisposed()) { layoutData.minimumWidth = 60; @@ -222,7 +222,7 @@ * @param value the zero-based index of the selection wrapped * as an Integer */ - protected void doSetValue(Object value) { + protected override void doSetValue(Object value) { Assert.isTrue(comboBox !is null && (cast(ValueWrapperInt)value )); selection = (cast(ValueWrapperInt) value).value; comboBox.select(selection); @@ -277,7 +277,7 @@ * (non-Javadoc) * @see dwtx.jface.viewers.CellEditor#focusLost() */ - protected void focusLost() { + protected override void focusLost() { if (isActivated()) { applyEditorValueAndDeactivate(); } @@ -287,7 +287,7 @@ * (non-Javadoc) * @see dwtx.jface.viewers.CellEditor#keyReleaseOccured(dwt.events.KeyEvent) */ - protected void keyReleaseOccured(KeyEvent keyEvent) { + protected override void keyReleaseOccured(KeyEvent keyEvent) { if (keyEvent.character is '\u001b') { // Escape character fireCancelEditor(); } else if (keyEvent.character is '\t') { // tab key diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/viewers/ComboViewer.d --- a/dwtx/jface/viewers/ComboViewer.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/viewers/ComboViewer.d Fri Apr 11 01:24:25 2008 +0200 @@ -107,7 +107,7 @@ hookControl(list); } - protected void listAdd(String string, int index) { + protected override void listAdd(String string, int index) { if (combo is null) { ccombo.add(string, index); } else { @@ -115,7 +115,7 @@ } } - protected void listSetItem(int index, String string) { + protected override void listSetItem(int index, String string) { if (combo is null) { ccombo.setItem(index, string); } else { @@ -123,7 +123,7 @@ } } - protected int[] listGetSelectionIndices() { + protected override int[] listGetSelectionIndices() { if (combo is null) { return [ ccombo.getSelectionIndex() ]; } else { @@ -131,7 +131,7 @@ } } - protected int listGetItemCount() { + protected override int listGetItemCount() { if (combo is null) { return ccombo.getItemCount(); } else { @@ -139,7 +139,7 @@ } } - protected void listSetItems(String[] labels) { + protected override void listSetItems(String[] labels) { if (combo is null) { ccombo.setItems(labels); } else { @@ -147,7 +147,7 @@ } } - protected void listRemoveAll() { + protected override void listRemoveAll() { if (combo is null) { ccombo.removeAll(); } else { @@ -155,7 +155,7 @@ } } - protected void listRemove(int index) { + protected override void listRemove(int index) { if (combo is null) { ccombo.remove(index); } else { @@ -166,7 +166,7 @@ /* (non-Javadoc) * Method declared on Viewer. */ - public Control getControl() { + public override Control getControl() { if (combo is null) { return ccombo; } else { @@ -202,13 +202,13 @@ * we can ensure that the given element is visible without changing the selection. * Method defined on StructuredViewer. */ - public void reveal(Object element) { + public override void reveal(Object element) { } /* (non-Javadoc) * @see dwtx.jface.viewers.AbstractListViewer#listSetSelection(int[]) */ - protected void listSetSelection(int[] ixs) { + protected override void listSetSelection(int[] ixs) { if (combo is null) { for (int idx = 0; idx < ixs.length; idx++) { ccombo.select(ixs[idx]); @@ -223,7 +223,7 @@ /* (non-Javadoc) * @see dwtx.jface.viewers.AbstractListViewer#listDeselectAll() */ - protected void listDeselectAll() { + protected override void listDeselectAll() { if (combo is null) { ccombo.deselectAll(); ccombo.clearSelection(); @@ -236,6 +236,6 @@ /* (non-Javadoc) * @see dwtx.jface.viewers.AbstractListViewer#listShowSelection() */ - protected void listShowSelection() { + protected override void listShowSelection() { } } diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/viewers/ContentViewer.d --- a/dwtx/jface/viewers/ContentViewer.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/viewers/ContentViewer.d Fri Apr 11 01:24:25 2008 +0200 @@ -119,7 +119,7 @@ * if none. The viewer's input provides the "model" for the viewer's * content. */ - public Object getInput() { + public override Object getInput() { return input; } @@ -138,11 +138,12 @@ * @return a label provider */ public IBaseLabelProvider getLabelProvider() { - Trace.formatln( "{} {}:", __FILE__, __LINE__ ); + Trace.formatln( "{} {}:", __FILE__, __LINE__ ); if (labelProvider is null) { - Trace.formatln( "{} {}:", __FILE__, __LINE__ ); + Trace.formatln( "{} {}:", __FILE__, __LINE__ ); labelProvider = new LabelProvider(); } + PrintStackTrace(); return labelProvider; } @@ -168,6 +169,7 @@ labelProvider.removeListener(labelProviderListener); labelProvider.dispose(); labelProvider = null; + Trace.formatln( "{} {}: labelProvider = null;", __FILE__, __LINE__ ); } input = null; } @@ -253,7 +255,7 @@ * inputChanged rather than this method, but may extend this method * if required. */ - public void setInput(Object input) { + public override void setInput(Object input) { Assert .isTrue(getContentProvider() !is null, "ContentViewer must have a content provider when input is set."); //$NON-NLS-1$ @@ -280,7 +282,7 @@ * @param labelProvider the label provider, or null if none */ public void setLabelProvider(IBaseLabelProvider labelProvider) { - Trace.formatln( "{} {}:", __FILE__, __LINE__ ); + Trace.formatln( "{} {}: setLabelProvider", __FILE__, __LINE__ ); IBaseLabelProvider oldProvider = this.labelProvider; // If it hasn't changed, do nothing. // This also ensures that the provider is not disposed @@ -301,6 +303,6 @@ if (oldProvider !is null) { oldProvider.dispose(); } - Trace.formatln( "{} {}:", __FILE__, __LINE__ ); + Trace.formatln( "{} {}: setLabelProvider", __FILE__, __LINE__ ); } } diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/viewers/CustomHashtable.d --- a/dwtx/jface/viewers/CustomHashtable.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/viewers/CustomHashtable.d Fri Apr 11 01:24:25 2008 +0200 @@ -34,6 +34,7 @@ * CustomHashtable allows a custom comparator and hash code provider. */ /* package */final class CustomHashtable { + alias Object.toHash toHash; /** * HashMapEntry is an internal class which is used to hold the entries of a Hashtable. diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/viewers/DecoratingLabelProvider.d --- a/dwtx/jface/viewers/DecoratingLabelProvider.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/viewers/DecoratingLabelProvider.d Fri Apr 11 01:24:25 2008 +0200 @@ -78,7 +78,7 @@ * * @param listener a label provider listener */ - public void addListener(ILabelProviderListener listener) { + public override void addListener(ILabelProviderListener listener) { super.addListener(listener); provider.addListener(listener); if (decorator !is null) { @@ -91,7 +91,7 @@ * The DecoratingLabelProvider implementation of this IBaseLabelProvider method * disposes both the nested label provider and the label decorator. */ - public void dispose() { + public override void dispose() { provider.dispose(); if (decorator !is null) { decorator.dispose(); @@ -105,7 +105,7 @@ * decorated with the decoration provided by the label decorator's * decorateImage method. */ - public Image getImage(Object element) { + public override Image getImage(Object element) { Image image = provider.getImage(element); if (decorator !is null) { if ( auto ld2 = cast(LabelDecorator)decorator ) { @@ -148,7 +148,7 @@ * decorated with the decoration provided by the label decorator's * decorateText method. */ - public String getText(Object element) { + public override String getText(Object element) { String text = provider.getText(element); if (decorator !is null) { if ( auto ld2 = cast(LabelDecorator)decorator ) { @@ -172,7 +172,7 @@ * on the nested label provider returns true or if the corresponding method on the * decorator returns true. */ - public bool isLabelProperty(Object element, String property) { + public override bool isLabelProperty(Object element, String property) { if (provider.isLabelProperty(element, property)) { return true; } @@ -188,7 +188,7 @@ * * @param listener a label provider listener */ - public void removeListener(ILabelProviderListener listener) { + public override void removeListener(ILabelProviderListener listener) { super.removeListener(listener); provider.removeListener(listener); if (decorator !is null) { diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/viewers/DecorationOverlayIcon.d --- a/dwtx/jface/viewers/DecorationOverlayIcon.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/viewers/DecorationOverlayIcon.d Fri Apr 11 01:24:25 2008 +0200 @@ -170,7 +170,7 @@ /* (non-Javadoc) * @see dwtx.jface.resource.CompositeImageDescriptor#drawCompositeImage(int, int) */ - protected void drawCompositeImage(int width, int height) { + protected override void drawCompositeImage(int width, int height) { if (overlays.length > IDecoration.UNDERLAY) { ImageDescriptor underlay = overlays[IDecoration.UNDERLAY]; if (underlay !is null) { @@ -184,14 +184,14 @@ /* (non-Javadoc) * @see dwtx.jface.resource.CompositeImageDescriptor#getSize() */ - protected Point getSize() { + protected override Point getSize() { return size; } /* (non-Javadoc) * @see dwtx.jface.resource.CompositeImageDescriptor#getTransparentPixel() */ - protected int getTransparentPixel() { + protected override int getTransparentPixel() { return base.getImageData().transparentPixel; } diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/viewers/DialogCellEditor.d --- a/dwtx/jface/viewers/DialogCellEditor.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/viewers/DialogCellEditor.d Fri Apr 11 01:24:25 2008 +0200 @@ -103,7 +103,7 @@ * Internal class for laying out the dialog. */ private class DialogCellLayout : Layout { - public void layout(Composite editor, bool force) { + public override void layout(Composite editor, bool force) { Rectangle bounds = editor.getClientArea(); Point size = button.computeSize(DWT.DEFAULT, DWT.DEFAULT, force); if (contents !is null) { @@ -112,7 +112,7 @@ button.setBounds(bounds.width - size.x, 0, size.x, bounds.height); } - public Point computeSize(Composite editor, int wHint, int hHint, + public override Point computeSize(Composite editor, int wHint, int hHint, bool force) { if (wHint !is DWT.DEFAULT && hHint !is DWT.DEFAULT) { return new Point(wHint, hHint); @@ -208,7 +208,7 @@ /* (non-Javadoc) * Method declared on CellEditor. */ - protected Control createControl(Composite parent) { + protected override Control createControl(Composite parent) { Font font = parent.getFont(); Color bg = parent.getBackground(); @@ -278,7 +278,7 @@ * * @see dwtx.jface.viewers.CellEditor#deactivate() */ - public void deactivate() { + public override void deactivate() { if (button !is null && !button.isDisposed()) { button.removeFocusListener(getButtonFocusListener()); } @@ -289,7 +289,7 @@ /* (non-Javadoc) * Method declared on CellEditor. */ - protected Object doGetValue() { + protected override Object doGetValue() { return value; } @@ -297,7 +297,7 @@ * Method declared on CellEditor. * The focus is set to the cell editor's button. */ - protected void doSetFocus() { + protected override void doSetFocus() { button.setFocus(); // add a FocusListener to the button @@ -334,7 +334,7 @@ /* (non-Javadoc) * Method declared on CellEditor. */ - protected void doSetValue(Object value) { + protected override void doSetValue(Object value) { this.value = value; updateContents(value); } diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/viewers/FocusCellOwnerDrawHighlighter.d --- a/dwtx/jface/viewers/FocusCellOwnerDrawHighlighter.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/viewers/FocusCellOwnerDrawHighlighter.d Fri Apr 11 01:24:25 2008 +0200 @@ -145,7 +145,7 @@ * * @see dwtx.jface.viewers.FocusCellHighlighter#focusCellChanged(dwtx.jface.viewers.ViewerCell) */ - protected void focusCellChanged(ViewerCell cell) { + protected override void focusCellChanged(ViewerCell cell) { super.focusCellChanged(cell); // Redraw new area diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/viewers/LabelProvider.d --- a/dwtx/jface/viewers/LabelProvider.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/viewers/LabelProvider.d Fri Apr 11 01:24:25 2008 +0200 @@ -18,6 +18,7 @@ import dwt.graphics.Image; import dwt.dwthelper.utils; +import tango.util.log.Trace; /** * A label provider implementation which, by default, uses an element's @@ -58,6 +59,7 @@ * toString string. Subclasses may override. */ public String getText(Object element) { + Trace.formatln( "{} {}: getText", __FILE__, __LINE__ ); return element is null ? "" : element.toString();//$NON-NLS-1$ } } diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/viewers/ListViewer.d --- a/dwtx/jface/viewers/ListViewer.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/viewers/ListViewer.d Fri Apr 11 01:24:25 2008 +0200 @@ -43,6 +43,7 @@ * @see TableViewer */ public class ListViewer : AbstractListViewer { + alias AbstractListViewer.setSelectionToWidget setSelectionToWidget; /** * This viewer's list control. @@ -89,7 +90,7 @@ /* (non-Javadoc) * Method declared on Viewer. */ - public Control getControl() { + public override Control getControl() { return list; } @@ -106,7 +107,7 @@ * Non-Javadoc. * Method defined on StructuredViewer. */ - public void reveal(Object element) { + public override void reveal(Object element) { Assert.isNotNull(element); int index = getElementIndex(element); if (index is -1) { @@ -133,77 +134,77 @@ /* (non-Javadoc) * @see dwtx.jface.viewers.AbstractListViewer#listAdd(java.lang.String, int) */ - protected void listAdd(String string, int index) { + protected override void listAdd(String string, int index) { list.add(string, index); } /* (non-Javadoc) * @see dwtx.jface.viewers.AbstractListViewer#listSetItem(int, java.lang.String) */ - protected void listSetItem(int index, String string) { + protected override void listSetItem(int index, String string) { list.setItem(index, string); } /* (non-Javadoc) * @see dwtx.jface.viewers.AbstractListViewer#listGetSelectionIndices() */ - protected int[] listGetSelectionIndices() { + protected override int[] listGetSelectionIndices() { return list.getSelectionIndices(); } /* (non-Javadoc) * @see dwtx.jface.viewers.AbstractListViewer#listGetItemCount() */ - protected int listGetItemCount() { + protected override int listGetItemCount() { return list.getItemCount(); } /* (non-Javadoc) * @see dwtx.jface.viewers.AbstractListViewer#listSetItems(java.lang.String[]) */ - protected void listSetItems(String[] labels) { + protected override void listSetItems(String[] labels) { list.setItems(labels); } /* (non-Javadoc) * @see dwtx.jface.viewers.AbstractListViewer#listRemoveAll() */ - protected void listRemoveAll() { + protected override void listRemoveAll() { list.removeAll(); } /* (non-Javadoc) * @see dwtx.jface.viewers.AbstractListViewer#listRemove(int) */ - protected void listRemove(int index) { + protected override void listRemove(int index) { list.remove(index); } /* (non-Javadoc) * @see dwtx.jface.viewers.AbstractListViewer#listSelectAndShow(int[]) */ - protected void listSetSelection(int[] ixs) { + protected override void listSetSelection(int[] ixs) { list.setSelection(ixs); } /* (non-Javadoc) * @see dwtx.jface.viewers.AbstractListViewer#listDeselectAll() */ - protected void listDeselectAll() { + protected override void listDeselectAll() { list.deselectAll(); } /* (non-Javadoc) * @see dwtx.jface.viewers.AbstractListViewer#listShowSelection() */ - protected void listShowSelection() { + protected override void listShowSelection() { list.showSelection(); } /* (non-Javadoc) * @see dwtx.jface.viewers.AbstractListViewer#listGetTopIndex() */ - protected int listGetTopIndex() { + protected override int listGetTopIndex() { return list.getTopIndex(); } @@ -211,14 +212,14 @@ * (non-Javadoc) * @see dwtx.jface.viewers.AbstractListViewer#listSetTopIndex(int) */ - protected void listSetTopIndex(int index) { + protected override void listSetTopIndex(int index) { list.setTopIndex(index); } /* (non-Javadoc) * @see dwtx.jface.viewers.AbstractListViewer#setSelectionToWidget(java.util.List, bool) */ - protected void setSelectionToWidget(SeqView!(Object) in_, bool reveal) { + protected override void setSelectionToWidget(SeqView!(Object) in_, bool reveal) { if( reveal ) { super.setSelectionToWidget(in_, reveal); } else { diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/viewers/NamedHandleObjectLabelProvider.d --- a/dwtx/jface/viewers/NamedHandleObjectLabelProvider.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/viewers/NamedHandleObjectLabelProvider.d Fri Apr 11 01:24:25 2008 +0200 @@ -41,7 +41,7 @@ * @return the name of the handle object; null if there is no * name or if the element is not a named handle object. */ - public final String getText(Object element) { + public override final String getText(Object element) { if ( cast(NamedHandleObject)element ) { try { return (cast(NamedHandleObject) element).getName(); diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/viewers/OwnerDrawLabelProvider.d --- a/dwtx/jface/viewers/OwnerDrawLabelProvider.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/viewers/OwnerDrawLabelProvider.d Fri Apr 11 01:24:25 2008 +0200 @@ -200,7 +200,7 @@ * * @see dwtx.jface.viewers.ViewerLabelProvider#update(dwtx.jface.viewers.ViewerCell) */ - public void update(ViewerCell cell) { + public override void update(ViewerCell cell) { // Force a redraw Rectangle cellBounds = cell.getBounds(); cell.getControl().redraw(cellBounds.x, cellBounds.y, cellBounds.width, diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/viewers/StructuredSelection.d --- a/dwtx/jface/viewers/StructuredSelection.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/viewers/StructuredSelection.d Fri Apr 11 01:24:25 2008 +0200 @@ -95,7 +95,7 @@ * @param o the other object * @return true if they are equal, and false otherwise */ - public bool equals(Object o) { + public override int opEquals(Object o) { if (this is o) { return true; } @@ -185,7 +185,7 @@ * * @return debug string */ - public String toString() { + public override String toString() { return isEmpty() ? JFaceResources.getString("") : (cast(Object)toList()).toString(); //$NON-NLS-1$ } } diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/viewers/StructuredViewer.d --- a/dwtx/jface/viewers/StructuredViewer.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/viewers/StructuredViewer.d Fri Apr 11 01:24:25 2008 +0200 @@ -85,6 +85,7 @@ * @see ViewerComparator */ public abstract class StructuredViewer : ContentViewer, IPostSelectionProvider { + alias ContentViewer.opEquals opEquals; alias ContentViewer.setSelection setSelection; /** * A map from the viewer's model elements to DWT widgets. (key type: @@ -202,7 +203,7 @@ /* (non-Javadoc) * @see dwtx.jface.viewers.StructuredViewer.ColorAndFontManager#setFontsAndColors(java.lang.Object) */ - public void setFontsAndColors(Object element){ + public override void setFontsAndColors(Object element){ if(fontProvider !is null){ if(font is null) { @@ -228,7 +229,7 @@ * required. * @param control */ - public void applyFontsAndColors(TableItem control) { + public override void applyFontsAndColors(TableItem control) { if(colorProvider is null){ if(usedDecorators){ @@ -264,7 +265,7 @@ /* (non-Javadoc) * @see dwtx.jface.viewers.StructuredViewer.ColorAndFontManager#applyFontsAndColors(dwt.widgets.TreeItem) */ - public void applyFontsAndColors(TreeItem control) { + public override void applyFontsAndColors(TreeItem control) { if(colorProvider is null){ if(usedDecorators){ @@ -299,7 +300,7 @@ /* (non-Javadoc) * @see dwtx.jface.viewers.StructuredViewer.ColorAndFontManager#applyFontsAndColors(dwt.custom.TableTreeItem) */ - public void applyFontsAndColors(TableTreeItem control) { + public override void applyFontsAndColors(TableTreeItem control) { if(colorProvider is null){ if(usedDecorators){ @@ -1013,7 +1014,7 @@ *

* @return ISelection */ - public ISelection getSelection() { + public override ISelection getSelection() { Control control = getControl(); if (control is null || control.isDisposed()) { return StructuredSelection.EMPTY; @@ -1164,7 +1165,7 @@ *

* @param event the event that generated this update */ - protected void handleLabelProviderChanged(LabelProviderChangedEvent event) { + protected override void handleLabelProviderChanged(LabelProviderChangedEvent event) { Object[] elements = event.getElements(); if (elements !is null) { update(elements, null); @@ -1211,7 +1212,7 @@ /* * (non-Javadoc) Method declared on Viewer. */ - protected void hookControl(Control control) { + protected override void hookControl(Control control) { super.hookControl(control); OpenStrategy handler = new OpenStrategy(control); handler.addSelectionListener(new class SelectionListener { @@ -1446,7 +1447,7 @@ /* * Non-Javadoc. Method declared on Viewer. */ - public void refresh() { + public override void refresh() { refresh(getRoot()); } @@ -1652,7 +1653,7 @@ * (non-Javadoc) * @see dwtx.jface.viewers.ContentViewer#setContentProvider(dwtx.jface.viewers.IContentProvider) */ - public void setContentProvider(IContentProvider provider) { + public override void setContentProvider(IContentProvider provider) { assertContentProviderType(provider); super.setContentProvider(provider); } @@ -1670,7 +1671,7 @@ * (non-Javadoc) * @see dwtx.jface.viewers.Viewer#setInput(java.lang.Object) */ - public final void setInput(Object input) { + public override final void setInput(Object input) { try { // fInChange= true; @@ -1688,7 +1689,7 @@ * (non-Javadoc) * @see dwtx.jface.viewers.Viewer#setSelection(dwtx.jface.viewers.ISelection, bool) */ - public void setSelection(ISelection selection, bool reveal) { + public override void setSelection(ISelection selection, bool reveal) { /** *

* If the new selection differs from the current selection the hook @@ -2146,7 +2147,7 @@ /* (non-Javadoc) * @see dwtx.jface.viewers.ContentViewer#setLabelProvider(dwtx.jface.viewers.IBaseLabelProvider) */ - public void setLabelProvider(IBaseLabelProvider labelProvider) { + public override void setLabelProvider(IBaseLabelProvider labelProvider) { if ( null !is cast(IColorProvider)labelProvider || null !is cast(IFontProvider)labelProvider ) { colorAndFontCollector = new ColorAndFontCollectorWithProviders(labelProvider); } else { @@ -2268,7 +2269,7 @@ return colorAndFontCollector; } - protected void handleDispose(DisposeEvent event) { + protected override void handleDispose(DisposeEvent event) { super.handleDispose(event); sorter = null; comparer = null; diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/viewers/TableColumnViewerLabelProvider.d --- a/dwtx/jface/viewers/TableColumnViewerLabelProvider.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/viewers/TableColumnViewerLabelProvider.d Fri Apr 11 01:24:25 2008 +0200 @@ -68,7 +68,7 @@ /* (non-Javadoc) * @see dwtx.jface.viewers.WrappedViewerLabelProvider#update(dwtx.jface.viewers.ViewerCell) */ - public void update(ViewerCell cell) { + public override void update(ViewerCell cell) { Object element = cell.getElement(); int index = cell.getColumnIndex(); diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/viewers/TableLayout.d --- a/dwtx/jface/viewers/TableLayout.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/viewers/TableLayout.d Fri Apr 11 01:24:25 2008 +0200 @@ -84,7 +84,7 @@ /* * (non-Javadoc) Method declared on Layout. */ - public Point computeSize(Composite c, int wHint, int hHint, bool flush) { + public override Point computeSize(Composite c, int wHint, int hHint, bool flush) { if (wHint !is DWT.DEFAULT && hHint !is DWT.DEFAULT) { return new Point(wHint, hHint); } @@ -119,7 +119,7 @@ /* * (non-Javadoc) Method declared on Layout. */ - public void layout(Composite c, bool flush) { + public override void layout(Composite c, bool flush) { // Only do initial layout. Trying to maintain proportions when resizing // is too hard, // causes lots of widget flicker, causes scroll bars to appear and diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/viewers/TableTreeViewer.d --- a/dwtx/jface/viewers/TableTreeViewer.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/viewers/TableTreeViewer.d Fri Apr 11 01:24:25 2008 +0200 @@ -73,7 +73,12 @@ * @deprecated As of 3.1 use {@link TreeViewer} instead */ public class TableTreeViewer : AbstractTreeViewer { + alias AbstractTreeViewer.addTreeListener addTreeListener; + alias AbstractTreeViewer.doUpdateItem doUpdateItem; + alias AbstractTreeViewer.getLabelProvider getLabelProvider; + alias AbstractTreeViewer.getSelection getSelection; alias AbstractTreeViewer.setSelection setSelection; + /** * Internal table viewer implementation. */ @@ -516,7 +521,7 @@ /* * (non-Javadoc) Method declared on AbstractTreeViewer. */ - protected void addTreeListener(Control c, TreeListener listener) { + protected override void addTreeListener(Control c, TreeListener listener) { (cast(TableTree) c).addTreeListener(listener); } @@ -524,14 +529,14 @@ * Cancels a currently active cell editor. All changes already done in the * cell editor are lost. */ - public void cancelEditing() { + public override void cancelEditing() { tableEditorImpl.cancelEditing(); } /* * (non-Javadoc) Method declared on AbstractTreeViewer. */ - protected void doUpdateItem(Item item, Object element) { + protected override void doUpdateItem(Item item, Object element) { // update icon and label // Similar code in TableTreeViewer.doUpdateItem() IBaseLabelProvider prov = getLabelProvider(); @@ -594,7 +599,7 @@ * @param column * the column number */ - public void editElement(Object element, int column) { + public override void editElement(Object element, int column) { tableEditorImpl.editElement(element, column); } @@ -603,7 +608,7 @@ * * @return the list of cell editors */ - public CellEditor[] getCellEditors() { + public override CellEditor[] getCellEditors() { return tableEditorImpl.getCellEditors(); } @@ -612,14 +617,14 @@ * * @return the cell modifier */ - public ICellModifier getCellModifier() { + public override ICellModifier getCellModifier() { return tableEditorImpl.getCellModifier(); } /* * (non-Javadoc) Method declared on AbstractTreeViewer. */ - protected Item[] getChildren(Widget o) { + protected override Item[] getChildren(Widget o) { if (auto i = cast(TableTreeItem) o ) { return i.getItems(); } @@ -635,7 +640,7 @@ * @see dwtx.jface.viewers.AbstractTreeViewer#getChild(dwt.widgets.Widget, * int) */ - protected Item getChild(Widget widget, int index) { + protected override Item getChild(Widget widget, int index) { if (auto w = cast(TableTreeItem) widget ) { return w.getItem(index); } @@ -652,14 +657,14 @@ * * @return the list of column properties */ - public Object[] getColumnProperties() { + public override Object[] getColumnProperties() { return tableEditorImpl.getColumnProperties(); } /* * (non-Javadoc) Method declared on Viewer. */ - public Control getControl() { + public override Control getControl() { return tableTree; } @@ -688,7 +693,7 @@ /* * (non-Javadoc) Method declared on AbstractTreeViewer. */ - protected bool getExpanded(Item item) { + protected override bool getExpanded(Item item) { return (cast(TableTreeItem) item).getExpanded(); } @@ -697,28 +702,28 @@ * * @see dwtx.jface.viewers.ColumnViewer#getItemAt(dwt.graphics.Point) */ - protected Item getItemAt(Point p) { + protected override Item getItemAt(Point p) { return getTableTree().getTable().getItem(p); } /* * (non-Javadoc) Method declared on AbstractTreeViewer. */ - protected int getItemCount(Control widget) { + protected override int getItemCount(Control widget) { return (cast(TableTree) widget).getItemCount(); } /* * (non-Javadoc) Method declared on AbstractTreeViewer. */ - protected int getItemCount(Item item) { + protected override int getItemCount(Item item) { return (cast(TableTreeItem) item).getItemCount(); } /* * (non-Javadoc) Method declared on AbstractTreeViewer. */ - protected dwt.widgets.Item.Item[] getItems( + protected override dwt.widgets.Item.Item[] getItems( dwt.widgets.Item.Item item) { return (cast(TableTreeItem) item).getItems(); } @@ -733,21 +738,21 @@ * ILabelProvider, then it provides only the label text and * image for the first column, and any remaining columns are blank. */ - public IBaseLabelProvider getLabelProvider() { + public override IBaseLabelProvider getLabelProvider() { return super.getLabelProvider(); } /* * (non-Javadoc) Method declared on AbstractTreeViewer. */ - protected Item getParentItem(Item item) { + protected override Item getParentItem(Item item) { return (cast(TableTreeItem) item).getParentItem(); } /* * (non-Javadoc) Method declared on AbstractTreeViewer. */ - protected Item[] getSelection(Control widget) { + protected override Item[] getSelection(Control widget) { return (cast(TableTree) widget).getSelection(); } @@ -763,7 +768,7 @@ /* * (non-Javadoc) Method declared on AbstractTreeViewer. */ - protected void hookControl(Control control) { + protected override void hookControl(Control control) { super.hookControl(control); tableTree.getTable().addMouseListener(new class MouseAdapter { public void mouseDown(MouseEvent e) { @@ -795,14 +800,14 @@ * @return true if there is an active cell editor, and * false otherwise */ - public bool isCellEditorActive() { + public override bool isCellEditorActive() { return tableEditorImpl.isCellEditorActive(); } /* * (non-Javadoc) Method declared in AbstractTreeViewer. */ - protected Item newItem(Widget parent, int flags, int ix) { + protected override Item newItem(Widget parent, int flags, int ix) { TableTreeItem item; if (ix >= 0) { if (cast(TableTreeItem) parent ) { @@ -823,7 +828,7 @@ /* * (non-Javadoc) Method declared in AbstractTreeViewer. */ - protected void removeAll(Control widget) { + protected override void removeAll(Control widget) { (cast(TableTree) widget).removeAll(); } @@ -833,7 +838,7 @@ * @param editors * the list of cell editors */ - public void setCellEditors(CellEditor[] editors) { + public override void setCellEditors(CellEditor[] editors) { tableEditorImpl.setCellEditors(editors); } @@ -843,7 +848,7 @@ * @param modifier * the cell modifier */ - public void setCellModifier(ICellModifier modifier) { + public override void setCellModifier(ICellModifier modifier) { tableEditorImpl.setCellModifier(modifier); } @@ -855,28 +860,28 @@ * @param columnProperties * the list of column properties */ - public void setColumnProperties(String[] columnProperties) { + public override void setColumnProperties(String[] columnProperties) { tableEditorImpl.setColumnProperties(columnProperties); } /* * (non-Javadoc) Method declared in AbstractTreeViewer. */ - protected void setExpanded(Item node, bool expand) { + protected override void setExpanded(Item node, bool expand) { (cast(TableTreeItem) node).setExpanded(expand); } /* * (non-Javadoc) Method declared in AbstractTreeViewer. */ - protected void setSelection(SeqView!(Item) items) { + protected override void setSelection(SeqView!(Item) items) { getTableTree().setSelection(cast(TableTreeItem[]) items.toArray); } /* * (non-Javadoc) Method declared in AbstractTreeViewer. */ - protected void showItem(Item item) { + protected override void showItem(Item item) { getTableTree().showItem(cast(TableTreeItem) item); } } diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/viewers/TableViewer.d --- a/dwtx/jface/viewers/TableViewer.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/viewers/TableViewer.d Fri Apr 11 01:24:25 2008 +0200 @@ -70,9 +70,8 @@ * @see #internalRefresh(Object, bool) */ public class TableViewer : AbstractTableViewer { - - public alias AbstractTableViewer.preservingSelection preservingSelection; - public alias AbstractTableViewer.refresh refresh; + alias AbstractTableViewer.refresh refresh; + alias AbstractTableViewer.setSelection setSelection; /** * This viewer's table control. @@ -126,7 +125,7 @@ hookControl(table); } - public Control getControl() { + public override Control getControl() { return table; } @@ -139,7 +138,7 @@ return table; } - protected ColumnViewerEditor createViewerEditor() { + protected override ColumnViewerEditor createViewerEditor() { return new TableViewerEditor(this,null,new ColumnViewerEditorActivationStrategy(this),ColumnViewerEditor.DEFAULT); } @@ -163,11 +162,11 @@ * @see Table#setSelection(int[]) * @see Table#showSelection() */ - public void setSelection(ISelection selection, bool reveal) { + public override void setSelection(ISelection selection, bool reveal) { super.setSelection(selection, reveal); } - protected ViewerRow getViewerRowFromItem(Widget item) { + protected override ViewerRow getViewerRowFromItem(Widget item) { if( cachedRow is null ) { cachedRow = new TableViewerRow(cast(TableItem) item); } else { @@ -185,7 +184,7 @@ * @return ViewerRow * @since 3.3 */ - protected ViewerRow internalCreateNewRowPart(int style, int rowIndex) { + protected override ViewerRow internalCreateNewRowPart(int style, int rowIndex) { TableItem item; if (rowIndex >= 0) { @@ -197,7 +196,7 @@ return getViewerRowFromItem(item); } - protected Item getItemAt(Point p) { + protected override Item getItemAt(Point p) { TableItem[] selection = table.getSelection(); if( selection.length is 1 ) { @@ -215,47 +214,47 @@ // Methods to provide widget independency - protected int doGetItemCount() { + protected override int doGetItemCount() { return table.getItemCount(); } - protected int doIndexOf(Item item) { + protected override int doIndexOf(Item item) { return table.indexOf(cast(TableItem)item); } - protected void doSetItemCount(int count) { + protected override void doSetItemCount(int count) { table.setItemCount(count); } - protected Item[] doGetItems() { + protected override Item[] doGetItems() { return table.getItems(); } - protected int doGetColumnCount() { + protected override int doGetColumnCount() { return table.getColumnCount(); } - protected Widget doGetColumn(int index) { + protected override Widget doGetColumn(int index) { return table.getColumn(index); } - protected Item doGetItem(int index) { + protected override Item doGetItem(int index) { return table.getItem(index); } - protected Item[] doGetSelection() { + protected override Item[] doGetSelection() { return table.getSelection(); } - protected int[] doGetSelectionIndices() { + protected override int[] doGetSelectionIndices() { return table.getSelectionIndices(); } - protected void doClearAll() { + protected override void doClearAll() { table.clearAll(); } - protected void doResetItem(Item item) { + protected override void doResetItem(Item item) { TableItem tableItem = cast(TableItem) item; int columnCount = Math.max(1, table.getColumnCount()); for (int i = 0; i < columnCount; i++) { @@ -266,27 +265,27 @@ } } - protected void doRemove(int start, int end) { + protected override void doRemove(int start, int end) { table.remove(start, end); } - protected void doRemoveAll() { + protected override void doRemoveAll() { table.removeAll(); } - protected void doRemove(int[] indices) { + protected override void doRemove(int[] indices) { table.remove(indices); } - protected void doShowItem(Item item) { + protected override void doShowItem(Item item) { table.showItem(cast(TableItem)item); } - protected void doDeselectAll() { + protected override void doDeselectAll() { table.deselectAll(); } - protected void doSetSelection(Item[] items) { + protected override void doSetSelection(Item[] items) { // Assert.isNotNull(items, "Items-Array can not be null"); //$NON-NLS-1$ TableItem[] t = new TableItem[items.length]; @@ -295,19 +294,19 @@ table.setSelection(t); } - protected void doShowSelection() { + protected override void doShowSelection() { table.showSelection(); } - protected void doSetSelection(int[] indices) { + protected override void doSetSelection(int[] indices) { table.setSelection(indices); } - protected void doClear(int index) { + protected override void doClear(int index) { table.clear(index); } - protected void doSelect(int[] indices) { + protected override void doSelect(int[] indices) { table.select(indices); } diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/viewers/TableViewerEditor.d --- a/dwtx/jface/viewers/TableViewerEditor.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/viewers/TableViewerEditor.d Fri Apr 11 01:24:25 2008 +0200 @@ -121,17 +121,17 @@ create(viewer, null, editorActivationStrategy, feature); } - protected void setEditor(Control w, Item item, int columnNumber) { + protected override void setEditor(Control w, Item item, int columnNumber) { tableEditor.setEditor(w, cast(TableItem) item, columnNumber); } - protected void setLayoutData(CellEditor.LayoutData layoutData) { + protected override void setLayoutData(CellEditor.LayoutData layoutData) { tableEditor.grabHorizontal = layoutData.grabHorizontal; tableEditor.horizontalAlignment = layoutData.horizontalAlignment; tableEditor.minimumWidth = layoutData.minimumWidth; } - public ViewerCell getFocusCell() { + public override ViewerCell getFocusCell() { if (focusCellManager !is null) { return focusCellManager.getFocusCell(); } @@ -139,7 +139,7 @@ return super.getFocusCell(); } - protected void updateFocusCell(ViewerCell focusCell, + protected override void updateFocusCell(ViewerCell focusCell, ColumnViewerEditorActivationEvent event) { // Update the focus cell when we activated the editor with these 2 // events diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/viewers/TableViewerFocusCellManager.d --- a/dwtx/jface/viewers/TableViewerFocusCellManager.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/viewers/TableViewerFocusCellManager.d Fri Apr 11 01:24:25 2008 +0200 @@ -49,7 +49,7 @@ super(viewer, focusDrawingDelegate, TABLE_NAVIGATE); } - ViewerCell getInitialFocusCell() { + override ViewerCell getInitialFocusCell() { Table table = cast(Table) getViewer().getControl(); if (table.getItemCount() > 0) { diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/viewers/TableViewerRow.d --- a/dwtx/jface/viewers/TableViewerRow.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/viewers/TableViewerRow.d Fri Apr 11 01:24:25 2008 +0200 @@ -47,14 +47,14 @@ /* (non-Javadoc) * @see dwtx.jface.viewers.ViewerRow#getBounds(int) */ - public Rectangle getBounds(int columnIndex) { + public override Rectangle getBounds(int columnIndex) { return item.getBounds(columnIndex); } /* (non-Javadoc) * @see dwtx.jface.viewers.ViewerRow#getBounds() */ - public Rectangle getBounds() { + public override Rectangle getBounds() { return item.getBounds(); } @@ -72,70 +72,70 @@ /* (non-Javadoc) * @see dwtx.jface.viewers.ViewerRow#getColumnCount() */ - public int getColumnCount() { + public override int getColumnCount() { return item.getParent().getColumnCount(); } /* (non-Javadoc) * @see dwtx.jface.viewers.ViewerRow#getBackground(int) */ - public Color getBackground(int columnIndex) { + public override Color getBackground(int columnIndex) { return item.getBackground(columnIndex); } /* (non-Javadoc) * @see dwtx.jface.viewers.ViewerRow#getFont(int) */ - public Font getFont(int columnIndex) { + public override Font getFont(int columnIndex) { return item.getFont(columnIndex); } /* (non-Javadoc) * @see dwtx.jface.viewers.ViewerRow#getForeground(int) */ - public Color getForeground(int columnIndex) { + public override Color getForeground(int columnIndex) { return item.getForeground(columnIndex); } /* (non-Javadoc) * @see dwtx.jface.viewers.ViewerRow#getImage(int) */ - public Image getImage(int columnIndex) { + public override Image getImage(int columnIndex) { return item.getImage(columnIndex); } /* (non-Javadoc) * @see dwtx.jface.viewers.ViewerRow#getText(int) */ - public String getText(int columnIndex) { + public override String getText(int columnIndex) { return item.getText(columnIndex); } /* (non-Javadoc) * @see dwtx.jface.viewers.ViewerRow#setBackground(int, dwt.graphics.Color) */ - public void setBackground(int columnIndex, Color color) { + public override void setBackground(int columnIndex, Color color) { item.setBackground(columnIndex, color); } /* (non-Javadoc) * @see dwtx.jface.viewers.ViewerRow#setFont(int, dwt.graphics.Font) */ - public void setFont(int columnIndex, Font font) { + public override void setFont(int columnIndex, Font font) { item.setFont(columnIndex, font); } /* (non-Javadoc) * @see dwtx.jface.viewers.ViewerRow#setForeground(int, dwt.graphics.Color) */ - public void setForeground(int columnIndex, Color color) { + public override void setForeground(int columnIndex, Color color) { item.setForeground(columnIndex, color); } /* (non-Javadoc) * @see dwtx.jface.viewers.ViewerRow#setImage(int, dwt.graphics.Image) */ - public void setImage(int columnIndex, Image image) { + public override void setImage(int columnIndex, Image image) { Image oldImage = item.getImage(columnIndex); if (oldImage !is image) { item.setImage(columnIndex,image); @@ -145,18 +145,18 @@ /* (non-Javadoc) * @see dwtx.jface.viewers.ViewerRow#setText(int, java.lang.String) */ - public void setText(int columnIndex, String text) { + public override void setText(int columnIndex, String text) { item.setText(columnIndex, text is null ? "" : text); //$NON-NLS-1$ } /* (non-Javadoc) * @see dwtx.jface.viewers.ViewerRow#getControl() */ - public Control getControl() { + public override Control getControl() { return item.getParent(); } - public ViewerRow getNeighbor(int direction, bool sameLevel) { + public override ViewerRow getNeighbor(int direction, bool sameLevel) { if( direction is ViewerRow.ABOVE ) { return getRowAbove(); } else if( direction is ViewerRow.BELOW ) { @@ -191,15 +191,15 @@ return null; } - public TreePath getTreePath() { + public override TreePath getTreePath() { return new TreePath([item.getData()]); } - public Object clone() { + public override Object clone() { return new TableViewerRow(item); } - public Object getElement() { + public override Object getElement() { return item.getData(); } } diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/viewers/TextCellEditor.d --- a/dwtx/jface/viewers/TextCellEditor.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/viewers/TextCellEditor.d Fri Apr 11 01:24:25 2008 +0200 @@ -145,7 +145,7 @@ /* (non-Javadoc) * Method declared on CellEditor. */ - protected Control createControl(Composite parent) { + protected override Control createControl(Composite parent) { text = new Text(parent, getStyle()); text.addSelectionListener(new class SelectionAdapter { public void widgetDefaultSelected(SelectionEvent e) { @@ -204,14 +204,14 @@ * * @return the text string */ - protected Object doGetValue() { + protected override Object doGetValue() { return new ArrayWrapperString(text.getText()); } /* (non-Javadoc) * Method declared on CellEditor. */ - protected void doSetFocus() { + protected override void doSetFocus() { if (text !is null) { text.selectAll(); text.setFocus(); @@ -228,7 +228,7 @@ * * @param value a text string (type String) */ - protected void doSetValue(Object value) { + protected override void doSetValue(Object value) { Assert.isTrue(text !is null && ( cast(ArrayWrapperString)value )); text.removeModifyListener(getModifyListener()); text.setText((cast(ArrayWrapperString)value).array); @@ -267,7 +267,7 @@ * Since a text editor field is scrollable we don't * set a minimumSize. */ - public LayoutData getLayoutData() { + public override LayoutData getLayoutData() { return new LayoutData(); } @@ -304,7 +304,7 @@ * CellEditor method returns true if * the current selection is not empty. */ - public bool isCopyEnabled() { + public override bool isCopyEnabled() { if (text is null || text.isDisposed()) { return false; } @@ -316,7 +316,7 @@ * CellEditor method returns true if * the current selection is not empty. */ - public bool isCutEnabled() { + public override bool isCutEnabled() { if (text is null || text.isDisposed()) { return false; } @@ -329,7 +329,7 @@ * if there is a selection or if the caret is not positioned * at the end of the text. */ - public bool isDeleteEnabled() { + public override bool isDeleteEnabled() { if (text is null || text.isDisposed()) { return false; } @@ -341,7 +341,7 @@ * The TextCellEditor implementation of this * CellEditor method always returns true. */ - public bool isPasteEnabled() { + public override bool isPasteEnabled() { if (text is null || text.isDisposed()) { return false; } @@ -372,7 +372,7 @@ * @return true if select all is possible, * false otherwise */ - public bool isSelectAllEnabled() { + public override bool isSelectAllEnabled() { if (text is null || text.isDisposed()) { return false; } @@ -391,7 +391,7 @@ * * @param keyEvent the key event */ - protected void keyReleaseOccured(KeyEvent keyEvent) { + protected override void keyReleaseOccured(KeyEvent keyEvent) { if (keyEvent.character is '\r') { // Return key // Enter is handled in handleDefaultSelection. // Do not apply the editor value in response to an Enter key event @@ -417,7 +417,7 @@ * CellEditor method copies the * current selection to the clipboard. */ - public void performCopy() { + public override void performCopy() { text.copy(); } @@ -426,7 +426,7 @@ * CellEditor method cuts the * current selection to the clipboard. */ - public void performCut() { + public override void performCut() { text.cut(); checkSelection(); checkDeleteable(); @@ -439,7 +439,7 @@ * current selection or, if there is no selection, * the character next character from the current position. */ - public void performDelete() { + public override void performDelete() { if (text.getSelectionCount() > 0) { // remove the contents of the current selection text.insert(""); //$NON-NLS-1$ @@ -461,7 +461,7 @@ * CellEditor method pastes the * the clipboard contents over the current selection. */ - public void performPaste() { + public override void performPaste() { text.paste(); checkSelection(); checkDeleteable(); @@ -473,13 +473,13 @@ * CellEditor method selects all of the * current text. */ - public void performSelectAll() { + public override void performSelectAll() { text.selectAll(); checkSelection(); checkDeleteable(); } - bool dependsOnExternalFocusListener() { + override bool dependsOnExternalFocusListener() { return this.classinfo !is TextCellEditor.classinfo; } } diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/viewers/TreeColumnViewerLabelProvider.d --- a/dwtx/jface/viewers/TreeColumnViewerLabelProvider.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/viewers/TreeColumnViewerLabelProvider.d Fri Apr 11 01:24:25 2008 +0200 @@ -111,7 +111,7 @@ * * @see dwtx.jface.viewers.ViewerLabelProvider#setProviders(java.lang.Object) */ - public void setProviders(Object provider) { + public override void setProviders(Object provider) { super.setProviders(provider); if ( auto p = cast(ITreePathLabelProvider) provider ) treePathProvider = p; diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/viewers/TreePathViewerSorter.d --- a/dwtx/jface/viewers/TreePathViewerSorter.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/viewers/TreePathViewerSorter.d Fri Apr 11 01:24:25 2008 +0200 @@ -30,9 +30,10 @@ * @since 3.2 */ public class TreePathViewerSorter : ViewerSorter { - public alias ViewerSorter.category category; - public alias ViewerSorter.compare compare; - public alias ViewerSorter.isSorterProperty isSorterProperty; + alias ViewerSorter.category category; + alias ViewerSorter.compare compare; + alias ViewerSorter.isSorterProperty isSorterProperty; + alias ViewerSorter.sort sort; /** * Provide a category for the given element that will have the given parent diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/viewers/TreeSelection.d --- a/dwtx/jface/viewers/TreeSelection.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/viewers/TreeSelection.d Fri Apr 11 01:24:25 2008 +0200 @@ -178,7 +178,7 @@ public override int opEquals(Object obj) { if (!(cast(TreeSelection)obj)) { // Fall back to super implementation, see bug 135837. - return super.equals(obj); + return super.opEquals(obj); } TreeSelection selection = cast(TreeSelection) obj; int size = getPaths().length; diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/viewers/TreeViewer.d --- a/dwtx/jface/viewers/TreeViewer.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/viewers/TreeViewer.d Fri Apr 11 01:24:25 2008 +0200 @@ -76,10 +76,12 @@ *

*/ public class TreeViewer : AbstractTreeViewer { - - public alias AbstractTreeViewer.preservingSelection preservingSelection; - public alias AbstractTreeViewer.getSelection getSelection; - public alias AbstractTreeViewer.setSelection setSelection; + alias AbstractTreeViewer.addTreeListener addTreeListener; + alias AbstractTreeViewer.getLabelProvider getLabelProvider; + alias AbstractTreeViewer.getSelection getSelection; + alias AbstractTreeViewer.preservingSelection preservingSelection; + alias AbstractTreeViewer.remove remove; + alias AbstractTreeViewer.setSelection setSelection; private static final String VIRTUAL_DISPOSE_KEY = Policy.JFACE ~ ".DISPOSE_LISTENER"; //$NON-NLS-1$ @@ -153,7 +155,7 @@ /* * (non-Javadoc) Method declared in AbstractTreeViewer. */ - protected void addTreeListener(Control c, TreeListener listener) { + protected override void addTreeListener(Control c, TreeListener listener) { (cast(Tree) c).addTreeListener(listener); } @@ -162,7 +164,7 @@ * * @see dwtx.jface.viewers.ColumnViewer#getColumnViewerOwner(int) */ - protected Widget getColumnViewerOwner(int columnIndex) { + protected override Widget getColumnViewerOwner(int columnIndex) { if (columnIndex < 0 || ( columnIndex > 0 && columnIndex >= getTree().getColumnCount() ) ) { return null; } @@ -176,7 +178,7 @@ /* * (non-Javadoc) Method declared in AbstractTreeViewer. */ - protected Item[] getChildren(Widget o) { + protected override Item[] getChildren(Widget o) { if (auto ti = cast(TreeItem)o ) { return ti.getItems(); } @@ -189,14 +191,14 @@ /* * (non-Javadoc) Method declared in Viewer. */ - public Control getControl() { + public override Control getControl() { return tree; } /* * (non-Javadoc) Method declared in AbstractTreeViewer. */ - protected bool getExpanded(Item item) { + protected override bool getExpanded(Item item) { return (cast(TreeItem) item).getExpanded(); } @@ -205,7 +207,7 @@ * * @see dwtx.jface.viewers.ColumnViewer#getItemAt(dwt.graphics.Point) */ - protected Item getItemAt(Point p) { + protected override Item getItemAt(Point p) { TreeItem[] selection = tree.getSelection(); if( selection.length is 1 ) { @@ -224,21 +226,21 @@ /* * (non-Javadoc) Method declared in AbstractTreeViewer. */ - protected int getItemCount(Control widget) { + protected override int getItemCount(Control widget) { return (cast(Tree) widget).getItemCount(); } /* * (non-Javadoc) Method declared in AbstractTreeViewer. */ - protected int getItemCount(Item item) { + protected override int getItemCount(Item item) { return (cast(TreeItem) item).getItemCount(); } /* * (non-Javadoc) Method declared in AbstractTreeViewer. */ - protected Item[] getItems(Item item) { + protected override Item[] getItems(Item item) { return (cast(TreeItem) item).getItems(); } @@ -251,21 +253,21 @@ * ILabelProvider, then it provides only the label text and * image for the first column, and any remaining columns are blank. */ - public IBaseLabelProvider getLabelProvider() { + public override IBaseLabelProvider getLabelProvider() { return super.getLabelProvider(); } /* * (non-Javadoc) Method declared in AbstractTreeViewer. */ - protected Item getParentItem(Item item) { + protected override Item getParentItem(Item item) { return (cast(TreeItem) item).getParentItem(); } /* * (non-Javadoc) Method declared in AbstractTreeViewer. */ - protected Item[] getSelection(Control widget) { + protected override Item[] getSelection(Control widget) { return (cast(Tree) widget).getSelection(); } @@ -283,7 +285,7 @@ * * @see dwtx.jface.viewers.AbstractTreeViewer#hookControl(dwt.widgets.Control) */ - protected void hookControl(Control control) { + protected override void hookControl(Control control) { super.hookControl(control); Tree treeControl = cast(Tree) control; @@ -311,14 +313,14 @@ } } - protected ColumnViewerEditor createViewerEditor() { + protected override ColumnViewerEditor createViewerEditor() { return new TreeViewerEditor(this,null,new ColumnViewerEditorActivationStrategy(this),ColumnViewerEditor.DEFAULT); } /* * (non-Javadoc) Method declared in AbstractTreeViewer. */ - protected Item newItem(Widget parent, int flags, int ix) { + protected override Item newItem(Widget parent, int flags, int ix) { TreeItem item; if ( cast(TreeItem)parent ) { @@ -334,14 +336,14 @@ /* * (non-Javadoc) Method declared in AbstractTreeViewer. */ - protected void removeAll(Control widget) { + protected override void removeAll(Control widget) { (cast(Tree) widget).removeAll(); } /* * (non-Javadoc) Method declared in AbstractTreeViewer. */ - protected void setExpanded(Item node, bool expand) { + protected override void setExpanded(Item node, bool expand) { (cast(TreeItem) node).setExpanded(expand); if (contentProviderIsLazy) { // force repaints to happen @@ -352,7 +354,7 @@ /* * (non-Javadoc) Method declared in AbstractTreeViewer. */ - protected void setSelection(SeqView!(Item) items) { + protected override void setSelection(SeqView!(Item) items) { Item[] current = getSelection(getTree()); @@ -367,7 +369,7 @@ /* * (non-Javadoc) Method declared in AbstractTreeViewer. */ - protected void showItem(Item item) { + protected override void showItem(Item item) { getTree().showItem(cast(TreeItem) item); } @@ -377,7 +379,7 @@ * @see dwtx.jface.viewers.AbstractTreeViewer#getChild(dwt.widgets.Widget, * int) */ - protected Item getChild(Widget widget, int index) { + protected override Item getChild(Widget widget, int index) { if (auto ti = cast(TreeItem)widget ) { return ti.getItem(index); } @@ -387,7 +389,7 @@ return null; } - protected void assertContentProviderType(IContentProvider provider) { + protected override void assertContentProviderType(IContentProvider provider) { if ( null !is cast(ILazyTreeContentProvider)provider || null !is cast(ILazyTreePathContentProvider)provider ) { return; @@ -395,14 +397,14 @@ super.assertContentProviderType(provider); } - protected Object[] getRawChildren(Object parent) { + protected override Object[] getRawChildren(Object parent) { if (contentProviderIsLazy) { return new Object[0]; } return super.getRawChildren(parent); } - void preservingSelection(Runnable updateCode, bool reveal) { + override void preservingSelection(Runnable updateCode, bool reveal) { if (preservingSelection_){ // avoid preserving the selection if called reentrantly, // see bug 172640 @@ -591,7 +593,7 @@ return selection; } - public bool isExpandable(Object element) { + public override bool isExpandable(Object element) { if (contentProviderIsLazy) { TreeItem treeItem = cast(TreeItem) internalExpand(element, false); if (treeItem is null) { @@ -603,7 +605,7 @@ return super.isExpandable(element); } - protected Object getParentElement(Object element) { + protected override Object getParentElement(Object element) { bool oldBusy = busy; busy = true; try { @@ -625,7 +627,7 @@ } } - protected void createChildren(Widget widget) { + protected override void createChildren(Widget widget) { if (contentProviderIsLazy) { Object element = widget.getData(); if (element is null && cast(TreeItem)widget ) { @@ -655,7 +657,7 @@ super.createChildren(widget); } - protected void internalAdd(Widget widget, Object parentElement, + protected override void internalAdd(Widget widget, Object parentElement, Object[] childElements) { if (contentProviderIsLazy) { if (auto ti = cast(TreeItem)widget ) { @@ -702,7 +704,7 @@ * @see dwtx.jface.viewers.AbstractTreeViewer#internalRefreshStruct(dwt.widgets.Widget, * java.lang.Object, bool) */ - protected void internalRefreshStruct(Widget widget, Object element, + protected override void internalRefreshStruct(Widget widget, Object element, bool updateLabels) { if (contentProviderIsLazy) { // clear all starting with the given widget @@ -765,7 +767,7 @@ * To unmap elements correctly, we need to register a dispose listener with * the item if the tree is virtual. */ - protected void mapElement(Object element, Widget item) { + protected override void mapElement(Object element, Widget item) { super.mapElement(element, item); // make sure to unmap elements if the tree is virtual if ((getTree().getStyle() & DWT.VIRTUAL) !is 0) { @@ -796,7 +798,7 @@ * * @see dwtx.jface.viewers.ColumnViewer#getRowPartFromItem(dwt.widgets.Widget) */ - protected ViewerRow getViewerRowFromItem(Widget item) { + protected override ViewerRow getViewerRowFromItem(Widget item) { if( cachedRow is null ) { cachedRow = new TreeViewerRow(cast(TreeItem) item); } else { @@ -836,7 +838,7 @@ * * @see dwtx.jface.viewers.AbstractTreeViewer#internalInitializeTree(dwt.widgets.Control) */ - protected void internalInitializeTree(Control widget) { + protected override void internalInitializeTree(Control widget) { if (contentProviderIsLazy) { if (cast(Tree)widget && widget.getData() !is null) { virtualLazyUpdateChildCount(widget, 0); @@ -852,7 +854,7 @@ * @see dwtx.jface.viewers.AbstractTreeViewer#updatePlus(dwt.widgets.Item, * java.lang.Object) */ - protected void updatePlus(Item item, Object element) { + protected override void updatePlus(Item item, Object element) { if (contentProviderIsLazy) { Object data = item.getData(); int itemCount = 0; @@ -938,7 +940,7 @@ /* (non-Javadoc) * @see dwtx.jface.viewers.AbstractTreeViewer#handleTreeExpand(dwt.events.TreeEvent) */ - protected void handleTreeExpand(TreeEvent event) { + protected override void handleTreeExpand(TreeEvent event) { if (contentProviderIsLazy) { if (event.item.getData() !is null) { Item[] children = getChildren(event.item); @@ -958,7 +960,7 @@ /* (non-Javadoc) * @see dwtx.jface.viewers.AbstractTreeViewer#setContentProvider(dwtx.jface.viewers.IContentProvider) */ - public void setContentProvider(IContentProvider provider) { + public override void setContentProvider(IContentProvider provider) { contentProviderIsLazy = (cast(ILazyTreeContentProvider)provider ) || (cast(ILazyTreePathContentProvider)provider ); contentProviderIsTreeBased = null !is cast(ILazyTreePathContentProvider)provider ; @@ -1108,7 +1110,7 @@ } } - protected void disassociate(Item item) { + protected override void disassociate(Item item) { if (contentProviderIsLazy) { // avoid causing a callback: item.setText(" "); //$NON-NLS-1$ @@ -1116,7 +1118,7 @@ super.disassociate(item); } - protected int doGetColumnCount() { + protected override int doGetColumnCount() { return tree.getColumnCount(); } @@ -1134,11 +1136,11 @@ * true if the selection is to be made visible, * and false otherwise */ - public void setSelection(ISelection selection, bool reveal) { + public override void setSelection(ISelection selection, bool reveal) { super.setSelection(selection, reveal); } - public void editElement(Object element, int column) { + public override void editElement(Object element, int column) { if( cast(TreePath)element ) { setSelection(new TreeSelection(cast(TreePath) element)); TreeItem[] items = tree.getSelection(); diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/viewers/TreeViewerEditor.d --- a/dwtx/jface/viewers/TreeViewerEditor.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/viewers/TreeViewerEditor.d Fri Apr 11 01:24:25 2008 +0200 @@ -118,17 +118,17 @@ create(viewer, null, editorActivationStrategy, feature); } - protected void setEditor(Control w, Item item, int fColumnNumber) { + protected override void setEditor(Control w, Item item, int fColumnNumber) { treeEditor.setEditor(w, cast(TreeItem) item, fColumnNumber); } - protected void setLayoutData(CellEditor.LayoutData layoutData) { + protected override void setLayoutData(CellEditor.LayoutData layoutData) { treeEditor.grabHorizontal = layoutData.grabHorizontal; treeEditor.horizontalAlignment = layoutData.horizontalAlignment; treeEditor.minimumWidth = layoutData.minimumWidth; } - public ViewerCell getFocusCell() { + public override ViewerCell getFocusCell() { if (focusCellManager !is null) { return focusCellManager.getFocusCell(); } @@ -136,7 +136,7 @@ return super.getFocusCell(); } - protected void updateFocusCell(ViewerCell focusCell, + protected override void updateFocusCell(ViewerCell focusCell, ColumnViewerEditorActivationEvent event) { // Update the focus cell when we activated the editor with these 2 // events diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/viewers/TreeViewerFocusCellManager.d --- a/dwtx/jface/viewers/TreeViewerFocusCellManager.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/viewers/TreeViewerFocusCellManager.d Fri Apr 11 01:24:25 2008 +0200 @@ -87,7 +87,7 @@ super(viewer, focusDrawingDelegate,TREE_NAVIGATE); } - ViewerCell getInitialFocusCell() { + override ViewerCell getInitialFocusCell() { Tree tree = cast(Tree) getViewer().getControl(); if( tree.getItemCount() > 0 ) { diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/viewers/TreeViewerRow.d --- a/dwtx/jface/viewers/TreeViewerRow.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/viewers/TreeViewerRow.d Fri Apr 11 01:24:25 2008 +0200 @@ -51,91 +51,91 @@ /* (non-Javadoc) * @see dwtx.jface.viewers.ViewerRow#getBounds(int) */ - public Rectangle getBounds(int columnIndex) { + public override Rectangle getBounds(int columnIndex) { return item.getBounds(columnIndex); } /* (non-Javadoc) * @see dwtx.jface.viewers.ViewerRow#getBounds() */ - public Rectangle getBounds() { + public override Rectangle getBounds() { return item.getBounds(); } /* (non-Javadoc) * @see dwtx.jface.viewers.ViewerRow#getColumnCount() */ - public int getColumnCount() { + public override int getColumnCount() { return item.getParent().getColumnCount(); } /* (non-Javadoc) * @see dwtx.jface.viewers.ViewerRow#getItem() */ - public Widget getItem() { + public override Widget getItem() { return item; } /* (non-Javadoc) * @see dwtx.jface.viewers.ViewerRow#getBackground(int) */ - public Color getBackground(int columnIndex) { + public override Color getBackground(int columnIndex) { return item.getBackground(columnIndex); } /* (non-Javadoc) * @see dwtx.jface.viewers.ViewerRow#getFont(int) */ - public Font getFont(int columnIndex) { + public override Font getFont(int columnIndex) { return item.getFont(columnIndex); } /* (non-Javadoc) * @see dwtx.jface.viewers.ViewerRow#getForeground(int) */ - public Color getForeground(int columnIndex) { + public override Color getForeground(int columnIndex) { return item.getForeground(columnIndex); } /* (non-Javadoc) * @see dwtx.jface.viewers.ViewerRow#getImage(int) */ - public Image getImage(int columnIndex) { + public override Image getImage(int columnIndex) { return item.getImage(columnIndex); } /* (non-Javadoc) * @see dwtx.jface.viewers.ViewerRow#getText(int) */ - public String getText(int columnIndex) { + public override String getText(int columnIndex) { return item.getText(columnIndex); } /* (non-Javadoc) * @see dwtx.jface.viewers.ViewerRow#setBackground(int, dwt.graphics.Color) */ - public void setBackground(int columnIndex, Color color) { + public override void setBackground(int columnIndex, Color color) { item.setBackground(columnIndex, color); } /* (non-Javadoc) * @see dwtx.jface.viewers.ViewerRow#setFont(int, dwt.graphics.Font) */ - public void setFont(int columnIndex, Font font) { + public override void setFont(int columnIndex, Font font) { item.setFont(columnIndex, font); } /* (non-Javadoc) * @see dwtx.jface.viewers.ViewerRow#setForeground(int, dwt.graphics.Color) */ - public void setForeground(int columnIndex, Color color) { + public override void setForeground(int columnIndex, Color color) { item.setForeground(columnIndex, color); } /* (non-Javadoc) * @see dwtx.jface.viewers.ViewerRow#setImage(int, dwt.graphics.Image) */ - public void setImage(int columnIndex, Image image) { + public override void setImage(int columnIndex, Image image) { Image oldImage = item.getImage(columnIndex); if (image !is oldImage) { item.setImage(columnIndex, image); @@ -145,19 +145,19 @@ /* (non-Javadoc) * @see dwtx.jface.viewers.ViewerRow#setText(int, java.lang.String) */ - public void setText(int columnIndex, String text) { + public override void setText(int columnIndex, String text) { item.setText(columnIndex, text is null ? "" : text); //$NON-NLS-1$ } /* (non-Javadoc) * @see dwtx.jface.viewers.ViewerRow#getControl() */ - public Control getControl() { + public override Control getControl() { return item.getParent(); } - public ViewerRow getNeighbor(int direction, bool sameLevel) { + public override ViewerRow getNeighbor(int direction, bool sameLevel) { if( direction is ViewerRow.ABOVE ) { return getRowAbove(sameLevel); } else if( direction is ViewerRow.BELOW ) { @@ -294,7 +294,7 @@ return rv; } - public TreePath getTreePath() { + public override TreePath getTreePath() { TreeItem tItem = item; auto segments = new LinkSeq!(Object); while (tItem !is null) { @@ -311,11 +311,11 @@ this.item = item; } - public Object clone() { + public override Object clone() { return new TreeViewerRow(item); } - public Object getElement() { + public override Object getElement() { return item.getData(); } } diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/viewers/ViewerDropAdapter.d --- a/dwtx/jface/viewers/ViewerDropAdapter.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/viewers/ViewerDropAdapter.d Fri Apr 11 01:24:25 2008 +0200 @@ -193,7 +193,7 @@ * The drag has entered this widget's region. See * if the drop should be allowed. */ - public void dragEnter(DropTargetEvent event) { + public override void dragEnter(DropTargetEvent event) { currentTarget = determineTarget(event); doDropValidation(event); } @@ -203,7 +203,7 @@ * The drop operation has changed, see if the action * should still be enabled. */ - public void dragOperationChanged(DropTargetEvent event) { + public override void dragOperationChanged(DropTargetEvent event) { currentTarget = determineTarget(event); doDropValidation(event); } @@ -214,7 +214,7 @@ * target item has changed, notify the action and check * that it is still enabled. */ - public void dragOver(DropTargetEvent event) { + public override void dragOver(DropTargetEvent event) { //use newly revealed item as target if scrolling occurs Object target = determineTarget(event); @@ -234,7 +234,7 @@ * Method declared on DropTargetAdapter. * The user has dropped something on the desktop viewer. */ - public void drop(DropTargetEvent event) { + public override void drop(DropTargetEvent event) { currentLocation = determineLocation(event); //perform the drop behavior @@ -248,7 +248,7 @@ * Method declared on DropTargetAdapter. * Last chance for the action to disable itself */ - public void dropAccept(DropTargetEvent event) { + public override void dropAccept(DropTargetEvent event) { if (!validateDrop(currentTarget, event.detail, event.currentDataType)) { event.detail = DND.DROP_NONE; } diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/viewers/ViewerRow.d --- a/dwtx/jface/viewers/ViewerRow.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/viewers/ViewerRow.d Fri Apr 11 01:24:25 2008 +0200 @@ -239,14 +239,14 @@ */ public abstract TreePath getTreePath(); - public abstract Object clone(); + public /+override+/ abstract Object clone(); /** * @return the model element */ public abstract Object getElement(); - public int hashCode() { + public override hash_t toHash() { final int prime = 31; int result = 1; result = prime * result @@ -254,7 +254,7 @@ return result; } - public bool equals(Object obj) { + public override int opEquals(Object obj) { if (this is obj) return true; if (obj is null) diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/viewers/WrappedViewerLabelProvider.d --- a/dwtx/jface/viewers/WrappedViewerLabelProvider.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/viewers/WrappedViewerLabelProvider.d Fri Apr 11 01:24:25 2008 +0200 @@ -98,7 +98,7 @@ * * @see dwtx.jface.viewers.IFontProvider#getFont(java.lang.Object) */ - public Font getFont(Object element) { + public override Font getFont(Object element) { if (fontProvider is null) { return null; } @@ -112,7 +112,7 @@ * * @see dwtx.jface.viewers.IColorProvider#getBackground(java.lang.Object) */ - public Color getBackground(Object element) { + public override Color getBackground(Object element) { if (colorProvider is null) { return null; } @@ -125,7 +125,7 @@ * * @see dwtx.jface.viewers.ILabelProvider#getText(java.lang.Object) */ - public String getText(Object element) { + public override String getText(Object element) { return getLabelProvider().getText(element); } @@ -134,7 +134,7 @@ * * @see dwtx.jface.viewers.ILabelProvider#getImage(java.lang.Object) */ - public Image getImage(Object element) { + public override Image getImage(Object element) { return getLabelProvider().getImage(element); } @@ -143,7 +143,7 @@ * * @see dwtx.jface.viewers.IColorProvider#getForeground(java.lang.Object) */ - public Color getForeground(Object element) { + public override Color getForeground(Object element) { if (colorProvider is null) { return null; } @@ -178,7 +178,7 @@ return fontProvider; } - public void update(ViewerCell cell) { + public override void update(ViewerCell cell) { Object element = cell.getElement(); if(viewerLabelProvider is null && treePathLabelProvider is null){ // inlined super implementation with performance optimizations diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/viewers/deferred/BackgroundContentProvider.d --- a/dwtx/jface/viewers/deferred/BackgroundContentProvider.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/viewers/deferred/BackgroundContentProvider.d Fri Apr 11 01:24:25 2008 +0200 @@ -480,7 +480,7 @@ super(/+name+/); } - public void run() { + public /+override+/ void run() { loop: while (true) { synchronized (lock) { sortScheduled = false; diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/viewers/deferred/DeferredContentProvider.d --- a/dwtx/jface/viewers/deferred/DeferredContentProvider.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/viewers/deferred/DeferredContentProvider.d Fri Apr 11 01:24:25 2008 +0200 @@ -68,42 +68,42 @@ /* (non-Javadoc) * @see dwtx.jface.viewers.deferred.AbstractVirtualTable#flushCache(java.lang.Object) */ - public void clear(int index) { + public override void clear(int index) { viewer.clear(index); } /* (non-Javadoc) * @see dwtx.jface.viewers.deferred.AbstractVirtualTable#replace(java.lang.Object, int) */ - public void replace(Object element, int itemIndex) { + public override void replace(Object element, int itemIndex) { viewer.replace(element, itemIndex); } /* (non-Javadoc) * @see dwtx.jface.viewers.deferred.AbstractVirtualTable#setItemCount(int) */ - public void setItemCount(int total) { + public override void setItemCount(int total) { viewer.setItemCount(total); } /* (non-Javadoc) * @see dwtx.jface.viewers.deferred.AbstractVirtualTable#getItemCount() */ - public int getItemCount() { + public override int getItemCount() { return viewer.getTable().getItemCount(); } /* (non-Javadoc) * @see dwtx.jface.viewers.deferred.AbstractVirtualTable#getTopIndex() */ - public int getTopIndex() { + public override int getTopIndex() { return Math.max(viewer.getTable().getTopIndex() - 1, 0); } /* (non-Javadoc) * @see dwtx.jface.viewers.deferred.AbstractVirtualTable#getVisibleItemCount() */ - public int getVisibleItemCount() { + public override int getVisibleItemCount() { int start = getTopIndex(); int itemCount = getItemCount(); Table table = viewer.getTable(); @@ -114,7 +114,7 @@ /* (non-Javadoc) * @see dwtx.jface.viewers.deferred.AbstractVirtualTable#getControl() */ - public Control getControl() { + public override Control getControl() { return viewer.getControl(); } diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/window/ApplicationWindow.d --- a/dwtx/jface/window/ApplicationWindow.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/window/ApplicationWindow.d Fri Apr 11 01:24:25 2008 +0200 @@ -128,7 +128,7 @@ static final int BAR_SIZE = 23; - protected Point computeSize(Composite composite, int wHint, int hHint, + protected override Point computeSize(Composite composite, int wHint, int hHint, bool flushCache) { if (wHint !is DWT.DEFAULT && hHint !is DWT.DEFAULT) { return new Point(wHint, hHint); @@ -172,7 +172,7 @@ return result; } - protected void layout(Composite composite, bool flushCache) { + protected override void layout(Composite composite, bool flushCache) { Rectangle clientArea = composite.getClientArea(); Control[] ws = composite.getChildren(); @@ -298,14 +298,14 @@ /* (non-Javadoc) * Method declared on Window. */ - protected bool canHandleShellCloseEvent() { + protected override bool canHandleShellCloseEvent() { return super.canHandleShellCloseEvent() && !operationInProgress; } /* (non-Javadoc) * Method declared on Window. */ - public bool close() { + public override bool close() { if (operationInProgress) { return false; } @@ -343,7 +343,7 @@ /** * Extends the super implementation by creating the trim widgets using createTrimWidgets. */ - protected void configureShell(Shell shell) { + protected override void configureShell(Shell shell) { super.configureShell(shell); @@ -375,7 +375,7 @@ /* (non-Javadoc) * @see dwtx.jface.window.Window#getLayout() */ - protected Layout getLayout() { + protected override Layout getLayout() { return new ApplicationWindowLayout(); } diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/window/DefaultToolTip.d --- a/dwtx/jface/window/DefaultToolTip.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/window/DefaultToolTip.d Fri Apr 11 01:24:25 2008 +0200 @@ -91,7 +91,7 @@ * the parent of the content area * @return the content area created */ - protected Composite createToolTipContentArea(Event event, Composite parent) { + protected override Composite createToolTipContentArea(Event event, Composite parent) { Image image = getImage(event); Image bgImage = getBackgroundImage(event); String text = getText(event); diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/wizard/ProgressMonitorPart.d --- a/dwtx/jface/wizard/ProgressMonitorPart.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/wizard/ProgressMonitorPart.d Fri Apr 11 01:24:25 2008 +0200 @@ -237,7 +237,7 @@ /** * Sets the progress monitor part's font. */ - public void setFont(Font font) { + public override void setFont(Font font) { super.setFont(font); fLabel.setFont(font); fProgressIndicator.setFont(font); diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/wizard/WizardDialog.d --- a/dwtx/jface/wizard/WizardDialog.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/wizard/WizardDialog.d Fri Apr 11 01:24:25 2008 +0200 @@ -204,7 +204,7 @@ /* * (non-Javadoc) Method declared on Layout. */ - public Point computeSize(Composite composite, int wHint, int hHint, + public override Point computeSize(Composite composite, int wHint, int hHint, bool force) { if (wHint !is DWT.DEFAULT && hHint !is DWT.DEFAULT) { return new Point(wHint, hHint); @@ -255,7 +255,7 @@ /* * (non-Javadoc) Method declared on Layout. */ - public void layout(Composite composite, bool force) { + public override void layout(Composite composite, bool force) { Rectangle rect = getClientArea(composite); Control[] children = composite.getChildren(); for (int i = 0; i < children.length; i++) { @@ -372,7 +372,7 @@ /* * (non-Javadoc) Method declared on Dialog. */ - protected void buttonPressed(int buttonId) { + protected override void buttonPressed(int buttonId) { switch (buttonId) { case IDialogConstants.HELP_ID: { helpPressed(); @@ -421,7 +421,7 @@ /* * (non-Javadoc) Method declared on Dialog. */ - protected void cancelPressed() { + protected override void cancelPressed() { if (activeRunningOperations <= 0) { // Close the dialog. The check whether the dialog can be // closed or not is done in okToClose. @@ -439,7 +439,7 @@ * * @see dwtx.jface.window.Window#close() */ - public bool close() { + public override bool close() { if (okToClose()) { return hardClose(); } @@ -449,7 +449,7 @@ /* * (non-Javadoc) Method declared on Window. */ - protected void configureShell(Shell newShell) { + protected override void configureShell(Shell newShell) { super.configureShell(newShell); // Register help listener on the shell newShell.addHelpListener(new class HelpListener { @@ -473,7 +473,7 @@ * @param parent * the parent composite to contain the buttons */ - protected void createButtonsForButtonBar(Composite parent) { + protected override void createButtonsForButtonBar(Composite parent) { (cast(GridLayout) parent.getLayout()).makeColumnsEqualWidth = false; if (wizard.isHelpAvailable()) { helpButton = createButton(parent, IDialogConstants.HELP_ID, @@ -492,7 +492,7 @@ * * @see dwtx.jface.dialogs.Dialog#setButtonLayoutData(dwt.widgets.Button) */ - protected void setButtonLayoutData(Button button) { + protected override void setButtonLayoutData(Button button) { GridData data = new GridData(GridData.HORIZONTAL_ALIGN_FILL); int widthHint = convertHorizontalDLUsToPixels(IDialogConstants.BUTTON_WIDTH); @@ -534,7 +534,7 @@ * the button id * @return the button corresponding to the button id */ - protected Button getButton(int id) { + protected override Button getButton(int id) { if (id is IDialogConstants.CANCEL_ID) { return cancelButton; } @@ -550,7 +550,7 @@ * pre-create their page controls prior to opening, so that the wizard opens * to the correct size. And finally it shows the first page. */ - protected Control createContents(Composite parent) { + protected override Control createContents(Composite parent) { // Allow the wizard to add pages to itself // Need to call this now so page count is correct // for determining if next/previous buttons are needed @@ -566,7 +566,7 @@ /* * (non-Javadoc) Method declared on Dialog. */ - protected Control createDialogArea(Composite parent) { + protected override Control createDialogArea(Composite parent) { Composite composite = cast(Composite) super.createDialogArea(parent); // Build the Page container pageContainer = createPageContainer(composite); diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/wizard/WizardPage.d --- a/dwtx/jface/wizard/WizardPage.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/wizard/WizardPage.d Fri Apr 11 01:24:25 2008 +0200 @@ -62,6 +62,7 @@ *

*/ public abstract class WizardPage : DialogPage, IWizardPage { + alias DialogPage.setMessage setMessage; /** * This page's name. @@ -152,7 +153,7 @@ /* (non-Javadoc) * Method declared on IDialogPage. */ - public Image getImage() { + public override Image getImage() { Image result = super.getImage(); if (result is null && wizard !is null) { @@ -204,7 +205,7 @@ * once the container is created even though this page's control may not * yet be created. */ - public Shell getShell() { + public override Shell getShell() { IWizardContainer container = getContainer(); if (container is null) { @@ -247,7 +248,7 @@ * method extends the DialogPage implementation to update * the wizard container title bar. Subclasses may extend. */ - public void setDescription(String description) { + public override void setDescription(String description) { super.setDescription(description); if (isCurrentPage()) { getContainer().updateTitleBar(); @@ -259,7 +260,7 @@ * declared on DialogPage updates the container * if this is the current page. */ - public void setErrorMessage(String newMessage) { + public override void setErrorMessage(String newMessage) { super.setErrorMessage(newMessage); if (isCurrentPage()) { getContainer().updateMessage(); @@ -271,7 +272,7 @@ * declared on DialogPage updates the container * if this page is the current page. */ - public void setImageDescriptor(ImageDescriptor image) { + public override void setImageDescriptor(ImageDescriptor image) { super.setImageDescriptor(image); if (isCurrentPage()) { getContainer().updateTitleBar(); @@ -283,7 +284,7 @@ * declared on DialogPage updates the container * if this is the current page. */ - public void setMessage(String newMessage, int newType) { + public override void setMessage(String newMessage, int newType) { super.setMessage(newMessage, newType); if (isCurrentPage()) { getContainer().updateMessage(); @@ -320,7 +321,7 @@ * method extends the DialogPage implementation to update * the wizard container title bar. Subclasses may extend. */ - public void setTitle(String title) { + public override void setTitle(String title) { super.setTitle(title); if (isCurrentPage()) { getContainer().updateTitleBar(); @@ -338,7 +339,7 @@ * Returns a printable representation of this wizard page suitable * only for debug purposes. */ - public String toString() { + public override String toString() { return name; } } diff -r 4567a6f54939 -r ea8ff534f622 dwtx/jface/wizard/WizardSelectionPage.d --- a/dwtx/jface/wizard/WizardSelectionPage.d Thu Apr 10 19:10:12 2008 +0200 +++ b/dwtx/jface/wizard/WizardSelectionPage.d Fri Apr 11 01:24:25 2008 +0200 @@ -82,7 +82,7 @@ * this IWizardPage method returns true * if there is a selected node. */ - public bool canFlipToNextPage() { + public override bool canFlipToNextPage() { return selectedNode !is null; } @@ -90,7 +90,7 @@ * The WizardSelectionPage implementation of an IDialogPage * method disposes of all nested wizards. Subclasses may extend. */ - public void dispose() { + public override void dispose() { super.dispose(); // notify nested wizards for (int i = 0; i < selectedWizardNodes.size(); i++) { @@ -103,7 +103,7 @@ * this IWizardPage method returns the first page * of the currently selected wizard if there is one. */ - public IWizardPage getNextPage() { + public override IWizardPage getNextPage() { if (selectedNode is null) { return null; }