diff dwt/graphics/Device.d @ 158:de2578a843a7

Tango update to rev 3158, TracedException>Exception, fromUtf8z>fromStringz,Fix Bug in MenuItem Thanx to nascent for the report.
author Frank Benoit <benoit@tionex.de>
date Sun, 10 Feb 2008 04:19:19 +0100
parents 62a654ba5276
children 1fe0f5bb0ba2
line wrap: on
line diff
--- a/dwt/graphics/Device.d	Sat Feb 09 21:22:47 2008 +0100
+++ b/dwt/graphics/Device.d	Sun Feb 10 04:19:19 2008 +0100
@@ -54,7 +54,7 @@
     public static bool DEBUG;
     bool debugging;
     bool tracking;
-    TracedException [] errors;
+    Exception [] errors;
     Object [] objects;
 
     /* Colormap and reference count */
@@ -168,7 +168,7 @@
             tracking = data.tracking;
         }
         if (tracking) {
-            errors = new TracedException [128];
+            errors = new Exception [128];
             objects = new Object [128];
         }
         create (data);
@@ -330,7 +330,7 @@
     }
     int index = 0;
     data.objects = new Object [count];
-    data.errors = new TracedException [count];
+    data.errors = new Exception [count];
     for (int i=0; i<length; i++) {
         if (objects [i] !is null) {
             data.objects [index] = objects [i];
@@ -422,7 +422,7 @@
         bool match = true;
         if (faceName !is null) {
             auto familyName = OS.pango_font_family_get_name(family);
-            match = Compatibility.equalsIgnoreCase(faceName, fromUtf8z( familyName ));
+            match = Compatibility.equalsIgnoreCase(faceName, fromStringz( familyName ));
         }
         if (match) {
             OS.pango_font_family_list_faces(family, &faces, &n_faces);
@@ -682,7 +682,7 @@
     Device dev = cast(Device)user_data;
     if (dev.warningLevel is 0) {
         if (DEBUG || dev.debugging) {
-            foreach( msg; new TracedException ("") ){
+            foreach( msg; (new Exception ("")).info ){
                 Stderr.formatln( "trc {}", msg );
             }
         }
@@ -695,7 +695,7 @@
     for (int i=0; i<objects.length; i++) {
         if (objects [i] is null) {
             objects [i] = object;
-            errors [i] = new TracedException ("");
+            errors [i] = new Exception ("");
             return;
         }
     }
@@ -703,9 +703,9 @@
     System.arraycopy (objects, 0, newObjects, 0, objects.length);
     newObjects [objects.length] = object;
     objects = newObjects;
-    TracedException [] newErrors = new TracedException [errors.length + 128];
+    Exception [] newErrors = new Exception [errors.length + 128];
     System.arraycopy (errors, 0, newErrors, 0, errors.length);
-    newErrors [errors.length] = new TracedException ("");
+    newErrors [errors.length] = new Exception ("");
     errors = newErrors;
 }
 
@@ -824,7 +824,7 @@
     if (device !is null) {
         if (device.warningLevel is 0) {
             if (DEBUG || device.debugging) {
-                foreach( msg; new TracedException ("") ){
+                foreach( msg; (new Exception ("")).info ){
                     Stderr.formatln( "trc {}", msg );
                 }
             }
@@ -843,13 +843,13 @@
     Device device = findDevice (xDisplay);
     if (device !is null) {
         if (DEBUG || device.debugging) {
-            foreach( msg; new TracedException ("") ){
+            foreach( msg; (new Exception ("")).info ){
                 Stderr.formatln( "trc {}", msg );
             }
         }
     } else {
         if (DEBUG) {
-            foreach( msg; new TracedException ("") ){
+            foreach( msg; (new Exception ("")).info ){
                 Stderr.formatln( "trc {}", msg );
             }
         }