Add AxHost.OcxState support
authorAlistair Leslie-Hughes <leslie_alistair@hotmail.com>
Wed, 24 Oct 2012 05:28:21 +0000 (16:28 +1100)
committerAlistair Leslie-Hughes <leslie_alistair@hotmail.com>
Wed, 31 Oct 2012 02:48:16 +0000 (13:48 +1100)
mcs/class/Managed.Windows.Forms/System.Windows.Forms/AxHost.cs

index 867f9f96503566bd6aef342d6783f468dcb1308e..e9ca02ae741c3552f077f738e7aea67eec4df818 100644 (file)
@@ -187,6 +187,7 @@ namespace System.Windows.Forms {
                //private int flags;
                //private Guid clsid;
                private AboutBoxDelegate aboutDelegate = null;
+               private AxHost.State ocxState = null;
 
                #region Protected Constructors
 
@@ -351,11 +352,15 @@ namespace System.Windows.Forms {
                [RefreshProperties (RefreshProperties.All)]
                public AxHost.State OcxState {
                        get {
-                               throw new NotImplementedException("COM/ActiveX support is not implemented");
+                               return ocxState;
                        }
 
                        set {
-                               throw new NotImplementedException("COM/ActiveX support is not implemented");
+                               if (ocxState == value || value == null)
+                               {
+                                       return;
+                               }
+                               this.ocxState = value;
                        }
                }