コード例 #1
0
        private void CompareVideo_Load(object sender, EventArgs e)
        {
            this._srcControl          = new VideoControl(null);
            this._srcControl.Location = new Point(0, 0);

            this._stegoControl          = new VideoControl(this._srcControl);
            this._stegoControl.Location = new Point(this._srcControl.ClientRectangle.Width + 1, 0);

            this.Controls.Add(this._srcControl);
            this.Controls.Add(this._stegoControl);
        }
コード例 #2
0
        /// <summary>
        /// Clean up any resources being used.
        /// </summary>
        /// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
        protected override void Dispose(bool disposing)
        {
            if (this._srcControl != null)
            {
                this._srcControl.Dispose();
                this._srcControl = null;
            }
            if (this._stegoControl != null)
            {
                this._stegoControl.Dispose();
                this._stegoControl = null;
            }

            if (disposing && (components != null))
            {
                components.Dispose();
            }
            base.Dispose(disposing);
        }
コード例 #3
0
ファイル: VideoControl.cs プロジェクト: cornerback/hideit
        /// <summary>
        /// Default constructor
        /// </summary>
        public VideoControl(VideoControl source)
        {
            InitializeComponent();

            this._source = source;
            this.EnableButtons(false);

            if (this._source != null)
            {
                ///enable the media control buttons
                this._enableControls = false;
                this.HideControl(true);

                ///Register events with source
                this._source.OnStop  += new EventHandler(_source_OnStop);
                this._source.OnPause += new EventHandler(_source_OnPause);
                this._source.OnPlay  += new EventHandler(_source_OnPlay);
            }

            this.worker.DoWork             += new DoWorkEventHandler(worker_DoWork);
            this.worker.RunWorkerCompleted += new RunWorkerCompletedEventHandler(worker_RunWorkerCompleted);
        }