コード例 #1
0
        /// <summary>
        /// Enables or disables image comments. TODO: Make enable/disable mechanism better, e.g. specific to each editor instance and persistent
        /// </summary>
        public static void ToggleEnabled()
        {
            ThreadHelper.ThrowIfNotOnUIThread();

            Enabled = !Enabled;
            UIMessage.Show($"Image comments enabled: {Enabled}. Scroll editor window(s) to update.");
        }
コード例 #2
0
        /// <summary>
        /// Enables or disables image comments. TODO: Make enable/disable mechanism better, e.g. specific to each editor instance and persistent
        /// </summary>
        public static void ToggleEnabled()
        {
            Enabled = !Enabled;
            string message = string.Format("Image comments {0}. Scroll editor window(s) to update.",
                                           Enabled ? "enabled" : "disabled");

            UIMessage.Show(message);
        }
コード例 #3
0
        public static void Notify(Exception ex, bool showMessage)
        {
            string message = string.Format("{0}: {1}", DateTime.Now, ex.ToString());

            Console.WriteLine(message);
            if (showMessage)
            {
                UIMessage.Show(message);
            }
            // LM: Code for modeless message box. Removed as frequent messages make it really annoying
            ////if (showMessageBox)
            ////{
            ////    new Thread(o => {MessageBox.Show(o.ToString());}).Start(ex);
            ////}
        }
コード例 #4
0
        public static void Notify(Exception ex, bool showMessage)
        {
            ThreadHelper.ThrowIfNotOnUIThread();

            string message = $"{DateTime.Now}: {ex.ToString()}";

            Console.WriteLine(message);
            if (showMessage)
            {
                UIMessage.Show(message);
            }
            // LM: Code for modeless message box. Removed as frequent messages make it really annoying
            ////if (showMessageBox)
            ////{
            ////    new Thread(o => {MessageBox.Show(o.ToString());}).Start(ex);
            ////}
        }