Author: jackson
Date: 2008-01-18 09:55:05 -0500 (Fri, 18 Jan 2008)
New Revision: 93262

Modified:
   trunk/moon/src/ChangeLog
   trunk/moon/src/xaml.cpp
Log:

        * xaml.cpp: KeyFrameCollections can be specified in the xaml if
        they are in a property element.
        - When searching for collections, use is subclass instead of
        making them be the same type, so derivied collections can be
used.



Modified: trunk/moon/src/ChangeLog
===================================================================
--- trunk/moon/src/ChangeLog    2008-01-18 14:52:32 UTC (rev 93261)
+++ trunk/moon/src/ChangeLog    2008-01-18 14:55:05 UTC (rev 93262)
@@ -1,3 +1,10 @@
+2008-01-18  Jackson Harper  <[EMAIL PROTECTED]>
+
+       * xaml.cpp: KeyFrameCollections can be specified in the xaml if
+       they are in a property element.
+       - When searching for collections, use is subclass instead of
+       making them be the same type, so derivied collections can be used.
+       
 2008-01-17  Chris Toshok  <[EMAIL PROTECTED]>
 
        * pipeline.h (class IMediaDemuxer): initializer streams and

Modified: trunk/moon/src/xaml.cpp
===================================================================
--- trunk/moon/src/xaml.cpp     2008-01-18 14:52:32 UTC (rev 93261)
+++ trunk/moon/src/xaml.cpp     2008-01-18 14:55:05 UTC (rev 93262)
@@ -2602,7 +2602,7 @@
                                        (char *) walk->info->GetContentProperty 
());                    
                }
 
-               if (dep && dep->value_type == i->dependency_type) {
+               if (dep && Type::Find (dep->value_type)->IsSubclassOf 
(i->dependency_type)) {
                        Value *v = ((DependencyObject * ) walk->item)->GetValue 
(dep);
                        if (v) {
                                inst->item = v->AsCollection ();
@@ -3077,7 +3077,7 @@
        XamlElementInfo *paukf = rdoe (dem, "PointAnimationUsingKeyFrames", pa, 
Type::POINTANIMATIONUSINGKEYFRAMES, (create_item_func) 
point_animation_using_key_frames_new);
        paukf->content_property = "KeyFrames";
 
-       XamlElementInfo *kfcol = register_ghost_element ("KeyFrameCollection", 
col, Type::KEYFRAME_COLLECTION);
+       XamlElementInfo *kfcol = rdoe (dem, "KeyFrameCollection", col, 
Type::KEYFRAME_COLLECTION, NULL);
 
        rdoe (dem, "ColorKeyFrameCollection", kfcol, 
Type::COLORKEYFRAME_COLLECTION, (create_item_func) 
color_key_frame_collection_new);
        rdoe (dem, "DoubleKeyFrameCollection", kfcol, 
Type::DOUBLEKEYFRAME_COLLECTION, (create_item_func) 
double_key_frame_collection_new);

_______________________________________________
Mono-patches maillist  -  Mono-patches@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-patches

Reply via email to