Ejemplo n.º 1
0
        void ShowRemarkDialog(Topic topic)
        {
            var dialog = new NoteWidgetDialog();

            dialog.ReadOnly = this.ReadOnly;
            dialog.Remark   = topic.Remark;
            if (dialog.ShowDialog(this) == DialogResult.OK && !ReadOnly)
            {
                topic.Remark = dialog.Remark;
            }
        }
Ejemplo n.º 2
0
        public void AddRemark()
        {
            if (SelectedTopics != null && SelectedTopics.Length > 0)
            {
                var dialog = new NoteWidgetDialog();

                //
                if (Clipboard.ContainsText())
                {
                    dialog.Remark = ClipboardHelper.GetHtml();
                }

                if (dialog.ShowDialog(this) == DialogResult.OK)
                {
                    var template = new NoteWidget();
                    template.Remark = dialog.Remark;
                    AddWidget(NoteWidget.TypeID, template, false);
                }
            }
        }