Esempio n. 1
0
        /// <summary>
        /// 关闭LED屏
        /// 注意:非线程安全
        /// </summary>
        /// <param name="ledIndex">屏幕的序号,从1开始</param>
        public void Close(int ledIndex)
        {
            return;

            LedAPI.User_DelAllProgram(ledIndex);
            LedAPI.User_CloseScreen(ledIndex);
        }
Esempio n. 2
0
        /// <summary>
        /// 刷新整个Led屏幕
        /// 由于API不支持更新某个逻辑窗口,因此需要刷新整个屏幕:让未更新的窗口立即显示以前的内容,让其他窗口更新信息(动态效果)
        /// </summary>
        /// <param name="activeWindowId"></param>
        private void RefreshWholeScreen(int activeWindowId)
        {
            return;

            var win  = windows[activeWindowId];
            var wins = windows.Values.Where(x => x.LedIndex == win.LedIndex);

            LedAPI.User_DelAllProgram(win.LedIndex);
            var programId = LedAPI.User_AddProgram(win.LedIndex, true, 0);

            foreach (var w in wins)
            {
                var text = new User_Text();
                text.chContent = w.Text;
                text.FontInfo  = w.Font;
                text.MoveSet   = w.Movement;

                if (w.Id != activeWindowId)
                {
                    text.MoveSet.iActionType = 1;                        // 除了当前窗,其他窗的文字都马上出现
                }
                text.PartInfo = w.Frame;
                LedAPI.User_AddText(win.LedIndex, ref text, programId);
            }
            LedAPI.User_SendToScreen(win.LedIndex);
        }
Esempio n. 3
0
        /// <summary>
        /// 打开一块LED屏幕,做初始化操作
        /// 注意:非线程安全
        /// </summary>
        /// <param name="ledIndex">屏幕的序号,从1开始</param>
        /// <returns></returns>
        public bool Open(int ledIndex)
        {
            return(true);

            return(LedAPI.User_OpenScreen(ledIndex));
        }