diff dwt/browser/StatusTextEvent.d @ 302:bfe1c57259e3

More browser code ported
author John Reimer<terminal.node@gmail.com>
date Tue, 12 Aug 2008 21:11:17 -0700
parents 93409d9838c5
children 3f4a5c7d138f
line wrap: on
line diff
--- a/dwt/browser/StatusTextEvent.d	Tue Aug 12 02:43:31 2008 +0200
+++ b/dwt/browser/StatusTextEvent.d	Tue Aug 12 21:11:17 2008 -0700
@@ -7,10 +7,12 @@
  *
  * Contributors:
  *     IBM Corporation - initial API and implementation
+ * Port to the D programming language:
+ *      John Reimer <terminal.node@gmail.com>
  *******************************************************************************/
 module dwt.browser.StatusTextEvent;
 
-import dwt.dwthelper.utils;
+//import dwt.dwthelper.utils;
 
 import dwt.events.TypedEvent;
 import dwt.widgets.Widget;
@@ -23,13 +25,13 @@
  * 
  * @since 3.0
  */
-public class StatusTextEvent extends TypedEvent {
+public class StatusTextEvent : TypedEvent {
     /** status text */
     public String text;
     
     static final long serialVersionUID = 3258407348371600439L;
 
-StatusTextEvent(Widget w) {
+this(Widget w) {
     super(w);
 }
 
@@ -39,10 +41,9 @@
  *
  * @return a string representation of the event
  */
-public String toString() {
-    String string = super.toString ();
-    return string.substring (0, string.length() - 1) // remove trailing '}'
-        + " text=" + text
-        + "}";
+public override String toString() {
+    return Format( "{} {text = {}}", 
+        super.toString[1 .. $-2], text );  
 }
+
 }