Esempio n. 1
0
        public void SetWorkingMessage(Control host, string message, int width = 340, int height = 150)
        {
            if (string.IsNullOrEmpty(message))
            {
                return;
            }

            if (host.Controls.Contains(_infoPanel))
            {
                if (_infoPanel.Width != width || _infoPanel.Height != height)
                {
                    _infoPanel.Dispose();
                    host.Controls.Remove(_infoPanel);
                    _infoPanel = InformationPanel.GetInformationPanel(host, message, width, height);
                }
                else
                {
                    InformationPanel.ChangeInformationPanelMessage(_infoPanel, message);
                }
            }
            else
            {
                _infoPanel = InformationPanel.GetInformationPanel(host, message, width, height);
            }
        }
 private void WorkerProgressChanged(object sender, ProgressChangedEventArgs e)
 {
     InformationPanel.ChangeInformationPanelMessage(infoPanel, e.UserState.ToString());
 }