RemoveProp() private method

private RemoveProp ( IntPtr hwnd, string lpString ) : int
hwnd System.IntPtr
lpString string
return int
示例#1
0
        /// <summary>
        ///     Unregisters the channel name with the instance, so that messages from this
        ///     channel will no longer be received.
        /// </summary>
        /// <param name = "channelName">The channel name to stop listening for.</param>
        public void UnRegisterChannel(string channelName)
        {
            Validate.That(channelName).IsNotNullOrEmpty();

            if (!disposed)
            {
                lock (disposeLock)
                {
                    if (!disposed)
                    {
                        Native.RemoveProp(Handle, GetChannelKey(channelName));
                        return;
                    }
                }
            }
            throw new ObjectDisposedException("IXDListener", "This instance has been disposed.");
        }
示例#2
0
        public void UnRegisterChannel(string channelName)
        {
            channelName.Requires("channelName").IsNotNullOrWhiteSpace();

            if (disposed)
            {
                throw new ObjectDisposedException("IXDListener", "This instance has been disposed.");
            }

            lock (disposeLock)
            {
                if (disposed)
                {
                    throw new ObjectDisposedException("IXDListener", "This instance has been disposed.");
                }

                Native.RemoveProp(Handle, GetChannelKey(channelName));
            }
        }