Exemplo n.º 1
0
        public unsafe object ConvertToObject()
        {
            if (_type == (short)VarEnum.VT_BOOL && _booleanValue == 4)
            {
                return(null);
            }

            // Can't take an address of this since it might move, so....
            HACK_VariantStructure localCopy = this;

            return(Marshal.GetObjectForNativeVariant((IntPtr)(&localCopy)));
        }
        public int SetOption(CompilerOptions optionID, HACK_VariantStructure value)
        {
            VisualStudioProjectOptionsProcessor[optionID] = value.ConvertToObject();

            if (optionID == CompilerOptions.OPTID_COMPATIBILITY)
            {
                // HACK: we want the project system to use the out-of-proc compiler rather than
                // us, because we really don't build much of anything yet. We can say we don't
                // support pretty much anything we want to do this. Let's just say we don't
                // support any version of C# yet

                return(VSConstants.S_FALSE);
            }

            return(VSConstants.S_OK);
        }
 public int SetOption(CompilerOptions optionID, HACK_VariantStructure value)
 {
     return(SetOptionWithMarshaledValue(optionID, value.ConvertToObject()));
 }
 public int SetOption(CompilerOptions optionID, HACK_VariantStructure value)
 {
     return SetOptionWithMarshaledValue(optionID, value.ConvertToObject());
 }