[Kde-bindings] KDE/kdebindings/csharp/qyoto

Richard Dale Richard_Dale at tipitina.demon.co.uk
Sat Jul 26 17:20:04 UTC 2008


SVN commit 838090 by rdale:

* Look in all loaded Assemblies for types in lists that might not be in
  the Qt assembly such as List<KUrl>.
* The code to look up the types of slot arguments was failing for types
  in the KTextEditor library

CCMAIL: kde-bindings at kde.org


 M  +7 -0      ChangeLog  
 M  +9 -1      src/SmokeMarshallers.cs  
 M  +3 -0      src/qyotoshared.cpp  


--- trunk/KDE/kdebindings/csharp/qyoto/ChangeLog #838089:838090
@@ -1,3 +1,10 @@
+2008-07-26  Richard Dale  <richard.j.dale at gmail.com>
+
+	* Look in all loaded Assemblies for types in lists that might not be in
+	  the Qt assembly such as List<KUrl>.
+	* The code to look up the types of slot arguments was failing for types
+	  in the KTextEditor library
+
 2008-07-26  Arno Rehn  <arno at arnorehn.de>
 
 	* Add a qobject_cast based on C# reflection and qt_metacast.
--- trunk/KDE/kdebindings/csharp/qyoto/src/SmokeMarshallers.cs #838089:838090
@@ -666,7 +666,15 @@
 
 		public static IntPtr ConstructList(string type) {
 			Type basetype = typeof(List<>);
-			Type[] generic = { Type.GetType(type) };
+			Type t = null;
+			foreach(Assembly a in AppDomain.CurrentDomain.GetAssemblies()) {
+				t = a.GetType(type);
+				if (t != null) {
+					break;
+				}
+			}
+
+			Type[] generic = { t };
 			Type merged = basetype.MakeGenericType(generic);
 			
 			object o = Activator.CreateInstance(merged);
--- trunk/KDE/kdebindings/csharp/qyoto/src/qyotoshared.cpp #838089:838090
@@ -395,6 +395,9 @@
 						smoke = it.key();
 						targetType = name;
 						typeId = smoke->idType(targetType.constData());
+						if (typeId != 0) {
+							break;
+						}
 	
 						if (typeId == 0 && !name.contains('*')) {
 							if (!name.contains("&")) {



More information about the Kde-bindings mailing list