public void CheckIfObjectIsScheduled(ProjectObject projectObject) { if (projectObject.activities.Count > 0) { if (!Activities.instance.userIsGC) { List <string> activities = projectObject.activities.FindAll(activity => Activities.instance.permittedActivities.Contains(activity)); bool scheduled = true; for (int i = 0; i < activities.Count; i++) { if (!projectObject.scheduledActivities.Contains(activities[i])) { scheduled = false; break; } } if (scheduled) { projectObject.Fade(); projectObject.isScheduled = true; } else { projectObject.UnFade(); projectObject.isScheduled = false; } } else { if (projectObject.scheduledActivities.Count >= projectObject.activities.Count) { projectObject.Fade(); projectObject.isScheduled = true; } else { projectObject.UnFade(); projectObject.isScheduled = false; } } } if (projectObject.loaded) { if (projectObject.isScheduled) { projectObject.SetLayer("Scheduled"); } else { projectObject.SetLayer("Unscheduled"); } } }
public void SetObjectToCircular(ProjectObject projectObject) { projectObject.SetLayer("Circular"); }
// public void SetUpUidsForSelection(){ // foreach (ProjectObject projectObject in projectObjects) { // //projectObject.interactiveSelect.pointerActivatesUseAction = true; // } // } // // public void SetUpUidsForNavigation(){ // foreach (ProjectObject projectObject in projectObjects) { // //projectObject.interactiveSelect.pointerActivatesUseAction = false; // } // } // // public void SetUpScheduledObjects(){ // foreach (ProjectStep projectStep in ProjectSteps.instance.projectSteps) { // foreach (string objectId in projectStep.objectIds) { // ProjectObject projectObject = GetObjectById(objectId); // SetUidToScheduled (projectObject); // MaterialManager.instance.FadeProjectObject (projectObject); // } // } // } public void SetObjectToUnscheduled(ProjectObject projectObject) { projectObject.SetLayer("Unscheduled"); }