Author: rolf
Date: 2007-06-12 13:32:50 -0400 (Tue, 12 Jun 2007)
New Revision: 79321

Modified:
   trunk/olive/class/agclr/System.Windows/ChangeLog
   trunk/olive/class/agclr/System.Windows/DependencyProperty.cs
   trunk/olive/class/agclr/System.Windows/Downloader.cs
Log:
* DependencyProperty.cs: Delete Register.
* Downloader.cs: Move from DependencyProperty.Register to
  DependencyProperty.Lookup.

Modified: trunk/olive/class/agclr/System.Windows/ChangeLog
===================================================================
--- trunk/olive/class/agclr/System.Windows/ChangeLog    2007-06-12 17:32:24 UTC 
(rev 79320)
+++ trunk/olive/class/agclr/System.Windows/ChangeLog    2007-06-12 17:32:50 UTC 
(rev 79321)
@@ -1,5 +1,11 @@
 2007-06-12  Rolf Bjarne Kvinge <[EMAIL PROTECTED]> 
 
+       * DependencyProperty.cs: Delete Register.
+       * Downloader.cs: Move from DependencyProperty.Register to
+         DependencyProperty.Lookup.
+
+2007-06-12  Rolf Bjarne Kvinge <[EMAIL PROTECTED]> 
+
        * DependencyObject.cs: Added back Inlines.
 
 2007-06-12  Rolf Bjarne Kvinge <[EMAIL PROTECTED]> 

Modified: trunk/olive/class/agclr/System.Windows/DependencyProperty.cs
===================================================================
--- trunk/olive/class/agclr/System.Windows/DependencyProperty.cs        
2007-06-12 17:32:24 UTC (rev 79320)
+++ trunk/olive/class/agclr/System.Windows/DependencyProperty.cs        
2007-06-12 17:32:50 UTC (rev 79321)
@@ -50,8 +50,7 @@
                        native = handle;
                        type = t;
                }
-               
-               internal static DependencyProperty Lookup (Kind type, string 
name, Type t)
+               internal static DependencyProperty Lookup (Kind type, string 
name, Type ownerType)
                {
                        IntPtr handle = 
NativeMethods.dependency_property_lookup (type, name);
 
@@ -59,15 +58,10 @@
                                throw new Exception (
                                        String.Format 
("DependencyProperty.Lookup: {0} lacks {1}", type, name));
 
-                       return new DependencyProperty (handle, t);
+                       if (ownerType == null)
+                               throw new ArgumentNullException ("ownerType");
+                       
+                       return new DependencyProperty (handle, ownerType);
                }
-
-               internal static DependencyProperty Register (string name, Type 
propertyType, Type ownerType)
-               {
-                       Console.WriteLine ("This way of registering properties 
is no longer supported:");
-                       Console.WriteLine ("owner={0} {1} of type {2}", 
ownerType, name, propertyType);
-
-                       return null;
-               }
        }
 }

Modified: trunk/olive/class/agclr/System.Windows/Downloader.cs
===================================================================
--- trunk/olive/class/agclr/System.Windows/Downloader.cs        2007-06-12 
17:32:24 UTC (rev 79320)
+++ trunk/olive/class/agclr/System.Windows/Downloader.cs        2007-06-12 
17:32:50 UTC (rev 79321)
@@ -25,16 +25,17 @@
 // OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
 // WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 //
+using Mono;
 
 namespace System.Windows {
 
        public sealed class Downloader : DependencyObject {
 
-               public static readonly DependencyProperty 
DownloadProgressProperty = DependencyProperty.Register ("DownloadProgress", 
typeof (double), typeof (Downloader));
-               public static readonly DependencyProperty ResponseTextProperty 
= DependencyProperty.Register ("ResponseText", typeof (string), typeof 
(Downloader));
-               public static readonly DependencyProperty StatusProperty = 
DependencyProperty.Register ("Status", typeof (int), typeof (Downloader));
-               public static readonly DependencyProperty StatusTextProperty = 
DependencyProperty.Register ("StatusText", typeof (string), typeof 
(Downloader));
-               public static readonly DependencyProperty UriProperty = 
DependencyProperty.Register ("Uri", typeof (Uri), typeof (Downloader));
+               public static readonly DependencyProperty 
DownloadProgressProperty = DependencyProperty.Lookup (Kind.DOUBLE, 
"DownloadProgress", typeof (Downloader));
+               public static readonly DependencyProperty ResponseTextProperty 
= DependencyProperty.Lookup (Kind.STRING, "ResponseText", typeof (Downloader));
+               public static readonly DependencyProperty StatusProperty = 
DependencyProperty.Lookup (Kind.INT32, "Status", typeof (Downloader));
+               public static readonly DependencyProperty StatusTextProperty = 
DependencyProperty.Lookup (Kind.STRING, "StatusText", typeof (Downloader));
+               public static readonly DependencyProperty UriProperty;//TODO// 
= DependencyProperty.Lookup ("Uri", Kind.URI, typeof (Downloader));
 
 
                public Downloader ()

_______________________________________________
Mono-patches maillist  -  [email protected]
http://lists.ximian.com/mailman/listinfo/mono-patches

Reply via email to