예제 #1
0
        public VsProjectFileTracker(Project project, string fileName, DteWithEvents dteWithEvents, IVisualStudioTracer tracer, bool followTrackingAfterRename = false) :
            base(project, dteWithEvents, tracer)
        {
            this.followTrackingAfterRename = followTrackingAfterRename;
            this.fileName = fileName;

            SetLastChangeDate(VsxHelper.FindProjectItemByProjectRelativePath(project, fileName));

            SubscribeToDteEvents();
        }
예제 #2
0
        private void BuildEventsOnOnBuildDone(vsBuildScope scope, vsBuildAction action)
        {
            this.tracer.Trace("Build Done.", "VsProjectFileTracker");
            ProjectItem item          = VsxHelper.FindProjectItemByProjectRelativePath(project, fileName);
            var         newChangeDate = VsxHelper.GetLastChangeDate(item);

            if (newChangeDate != LastChangeDate)
            {
                OnFileChanged(item);
            }
        }
예제 #3
0
 public ProjectItem GetProjectItem()
 {
     return(VsxHelper.FindProjectItemByProjectRelativePath(project, fileName));
 }