}
long taskStart = getTask().getStart();
start = Math.max(start,getStop()); //only shift remaining
start = Math.max(start,taskStart); // dont shift before task start of course
long startOffset = cal.compare(start,taskStart,false);
long endOffset = cal.compare(end,taskStart,false);
if (getResume() != 0 && start >= getResume()) {
long splitDuration = detail.getSplitDuration();
startOffset -= splitDuration;
endOffset -= splitDuration;