aboutsummaryrefslogtreecommitdiffstats
path: root/Software/Visual_Studio/Scripting/Tango.Scripting.Basic/app.config
Path not found
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Media.Imaging;

namespace Tango.Scripting.Editors.Intellisense
{
    public class NamespaceCompletionItem : CompletionItem
    {
        private static BitmapSource image = GetImage("namespace.png");

        public override string Text => Name;
        public override CompletionItemPopupControl PopupControl => new NamespaceCompletionItemPopup();
        public override BitmapSource Image => image;

        public String Name { get; set; }
        public String Assembly { get; set; }

        public override void Complete(ScriptEditor editor)
        {
            var line = editor.GetCurrentLine();
            editor.Document.Replace(line, "using " + Name);
        }
    }
}