Ejemplo n.º 1
0
        /// <summary>
        /// Creates a new sound module (corresponding to a new track) on the DAW
        /// </summary>
        /// <param name="client"></param>
        /// <param name="senderID"> The id to give the sound module</param>
        public void CreateSoundModule(string senderID)
        {
            Protocol.Module.CreateSoundModule createEvent = new Protocol.Module.CreateSoundModule
            {
                SenderId = senderID
            };

            Protocol.ModuleEvent moduleEvent = new Protocol.ModuleEvent
            {
                HandlerId = "app",
                CreateSoundModuleEvent = createEvent
            };

            Protocol.Event remoteEvent = new Protocol.Event
            {
                ModuleEvent = moduleEvent,
                MethodName  = "CreateSoundModule"
            };

            Emitter.EmitEvent(remoteEvent);
        }
Ejemplo n.º 2
0
        /// <summary>
        /// Opens a browser on a module
        /// </summary>
        /// <param name="client"></param>
        /// <param name="moduleID">The module to browse on</param>
        public void OpenBrowser(string moduleID, string deviceType, string contentType, int deviceIndex, bool replaceDevice)
        {
            Protocol.Module.OpenBrowser openEvent = new Protocol.Module.OpenBrowser
            {
                DeviceType    = deviceType,
                ContentType   = contentType,
                DeviceIndex   = deviceIndex,
                ReplaceDevice = replaceDevice
            };

            Protocol.ModuleEvent moduleEvent = new Protocol.ModuleEvent
            {
                HandlerId        = moduleID,
                OpenBrowserEvent = openEvent
            };

            Protocol.Event remoteEvent = new Protocol.Event
            {
                ModuleEvent = moduleEvent,
                MethodName  = "OpenBrowser"
            };

            Emitter.EmitEvent(remoteEvent);
        }