コード例 #1
0
		protected void deleteBookMark (BookmarkNode node) {
			if (node.Bookmark.Document != null) {
				node.Bookmark.Document.BookmarkManager.RemoveMark(node.Bookmark);
			} else {
				ICSharpCode.SharpDevelop.Bookmarks.BookmarkManager.RemoveMark(node.Bookmark);
			}
		}
コード例 #2
0
 protected void deleteBookMark(BookmarkNode node)
 {
     if (node.Bookmark.Document != null)
     {
         node.Bookmark.Document.BookmarkManager.RemoveMark(node.Bookmark);
     }
     else
     {
         ICSharpCode.SharpDevelop.Bookmarks.BookmarkManager.RemoveMark(node.Bookmark);
     }
 }
コード例 #3
0
        protected override void Initialize()
        {
            Nodes.Clear();
            if (marks.Count > 0)
            {
//				IDocument document = marks[0].Document;
//				if (document != null && document.HighlightingStrategy == null) {
//					document.HighlightingStrategy = HighlightingStrategyFactory.CreateHighlightingStrategyForFile(fileName);
//				}
                foreach (SDBookmark mark in marks)
                {
                    TreeNode newResult = new BookmarkNode(mark);
                    Nodes.Add(newResult);
                }
            }
        }
コード例 #4
0
        public override void Run()
        {
            BookmarkNode node = BookmarkPad.Instance.CurrentNode;

            if (node != null)
            {
                if (node.Bookmark.Document != null)
                {
                    node.Bookmark.Document.BookmarkManager.RemoveMark(node.Bookmark);
                }
                else
                {
                    ICSharpCode.SharpDevelop.Bookmarks.BookmarkManager.RemoveMark(node.Bookmark);
                }
                WorkbenchSingleton.MainForm.Refresh();
            }
        }
コード例 #5
0
        public void AddMark(SDBookmark mark)
        {
            int index = -1;

            for (int i = 0; i < marks.Count; ++i)
            {
                if (mark.LineNumber < marks[i].LineNumber)
                {
                    index = i;
                    break;
                }
            }
            if (index < 0)
            {
                marks.Add(mark);
            }
            else
            {
                marks.Insert(index, mark);
            }

            if (isInitialized)
            {
                BookmarkNode newNode = new BookmarkNode(mark);
                if (index < 0)
                {
                    Nodes.Add(newNode);
                }
                else
                {
                    Nodes.Insert(index, newNode);
                }
                newNode.EnsureVisible();
            }
            SetText();
        }
コード例 #6
0
		public void AddMark(SDBookmark mark)
		{
			int index = -1;
			for (int i = 0; i < marks.Count; ++i) {
				if (mark.LineNumber < marks[i].LineNumber) {
					index = i;
					break;
				}
			}
			if (index < 0)
				marks.Add(mark);
			else
				marks.Insert(index, mark);
			
			if (isInitialized) {
				BookmarkNode newNode = new BookmarkNode(mark);
				if (index < 0)
					Nodes.Add(newNode);
				else
					Nodes.Insert(index, newNode);
				newNode.EnsureVisible();
			}
			SetText();
		}
コード例 #7
0
		protected override void Initialize()
		{
			Nodes.Clear();
			if (marks.Count > 0) {
//				IDocument document = marks[0].Document;
//				if (document != null && document.HighlightingStrategy == null) {
//					document.HighlightingStrategy = HighlightingStrategyFactory.CreateHighlightingStrategyForFile(fileName);
//				}
				foreach (SDBookmark mark in marks) {
					TreeNode newResult = new BookmarkNode(mark);
					Nodes.Add(newResult);
				}
			}
		}
コード例 #8
0
		protected void deleteBookMark (BookmarkNode node) {
			ICSharpCode.SharpDevelop.Bookmarks.BookmarkManager.RemoveMark(node.Bookmark);
		}