diff org.eclipse.swt.win32.win32.x86/src/org/eclipse/swt/custom/DefaultContent.d @ 43:b98647bc0aef

swt win compiles for d2+phobos
author Frank Benoit <benoit@tionex.de>
date Wed, 25 Mar 2009 17:08:05 +0100
parents d46287db17ed
children 9f4c18c268b2
line wrap: on
line diff
--- a/org.eclipse.swt.win32.win32.x86/src/org/eclipse/swt/custom/DefaultContent.d	Wed Mar 25 16:13:14 2009 +0100
+++ b/org.eclipse.swt.win32.win32.x86/src/org/eclipse/swt/custom/DefaultContent.d	Wed Mar 25 17:08:05 2009 +0100
@@ -493,7 +493,7 @@
         while ((length_ - 1 >= 0) && isDelimiter(textStore[start+length_-1])) {
             length_--;
         }
-        return textStore[ start .. start + length_].dup;
+        return textStore[ start .. start + length_]._idup();
     } else {
         // gap is in the specified range, strip out the gap
         StringBuffer buf = new StringBuffer();
@@ -531,14 +531,14 @@
     int end = start + length_ - 1;
     if (!gapExists() || (end < gapStart) || (start >= gapEnd)) {
         // line is before or after the gap
-        return textStore[ start .. start + length_ ].dup;
+        return textStore[ start .. start + length_ ]._idup();
     } else {
         // gap is in the specified range, strip out the gap
         StringBuffer buffer = new StringBuffer();
         int gapLength = gapEnd - gapStart;
         buffer.append(textStore[ start .. gapStart ]);
         buffer.append(textStore[ gapEnd .. gapEnd + length_ - gapLength - (gapStart - start) ]);
-        return buffer.toString().dup;
+        return buffer.toString()._idup();
     }
 }
 /**
@@ -697,7 +697,7 @@
  * @return the text
  */
 String getPhysicalText(int start, int length_) {
-    return textStore[ start .. start + length_ ].dup;
+    return textStore[ start .. start + length_ ]._idup();
 }
 /**
  * Returns a string representing the logical content of
@@ -715,15 +715,15 @@
         return "";
     int end= start + length_;
     if (!gapExists() || (end < gapStart))
-        return textStore[ start .. start + length_].dup;
+        return textStore[ start .. start + length_]._idup();
     if (gapStart < start) {
         int gapLength= gapEnd - gapStart;
-        return textStore[ start + gapLength .. start + gapLength + length_ ].dup;
+        return textStore[ start + gapLength .. start + gapLength + length_ ]._idup();
     }
     StringBuffer buf = new StringBuffer();
     buf.append(textStore[ start .. start + gapStart - start ] );
     buf.append(textStore[ gapEnd .. gapEnd + end - gapStart ] );
-    return buf.toString().dup;
+    return buf.toString()._idup();
 }
 /**
  * Removes the specified <code>TextChangeListener</code>.