Пример #1
0
        private DisplayMarkerViewModel(int displayIndex)
        {
            var screen = NotificationUtil.GetScreenOfIndex(displayIndex);

            if (screen == null)
            {
                return;
            }
            var warea = screen.WorkingArea;

            if (warea.Width < 1 || warea.Height < 1)
            {
                return;
            }
            this._left = (int)((warea.Width - 300) / 2 + warea.Left);
            this._top  = (int)((warea.Height - 60) / 2 + warea.Top);
        }