Esempio n. 1
0
        void TreeNodePlaybackHandler_PlayHandlingEnded(object sender, EventArgs e)
        {
            TreeNodePlaybackHandler handler = sender as TreeNodePlaybackHandler;

            if (handler != null)
            {
                handler.PlayHandlingEnded -= new EventHandler(TreeNodePlaybackHandler_PlayHandlingEnded);

                handler.Dispose();
            }
        }
Esempio n. 2
0
        public void play(TreeNode node, Channel audioCh, bool contAfterNode)
        {
            if (node == null)
            {
                throw new exception.MethodParameterIsNullException("Can not play a null TreeNode");
            }
            if (audioCh == null)
            {
                throw new exception.MethodParameterIsNullException("The audio channel to play was null");
            }
            TreeNodePlaybackHandler playbackHandler = new TreeNodePlaybackHandler(node, audioCh, contAfterNode, this);

            playbackHandler.PlayHandlingEnded += new EventHandler(TreeNodePlaybackHandler_PlayHandlingEnded);
            playbackHandler.play();
        }