src/Palete/Gtk.vala
authorAlan Knowles <alan@roojs.com>
Fri, 29 May 2015 06:23:36 +0000 (14:23 +0800)
committerAlan Knowles <alan@roojs.com>
Fri, 29 May 2015 06:23:36 +0000 (14:23 +0800)
src/Palete/Gtk.vala

index 8691fd3..69cf9ba 100644 (file)
@@ -351,6 +351,11 @@ namespace Palete {
                                }
                                curtype = "*" +  node.fqn();
                                cur_instance = true;
+                       } else {
+                                if (Gir.cache.get(parts[0]) == null) {
+                                       return ret;
+                               }
+                               curtype = parts[0];
                        }
                        // all Gtk.... etc.. types...
                        
@@ -407,7 +412,7 @@ namespace Palete {
                                                var scls = citer.get_key();
                                                print("checking against class %s\n",scls);
                                                var look = prevbits + parts[i];
-                                               if (scls.index_of(look,0) != 0) {
+                                               if (scls.index_of(parts[i],0) != 0) {
                                                        continue;
                                                }
                                                // got a starting match..