Lines Matching refs:node

74      * to a single node representing that Animator, not create a new Node
248 Node node = mNodes.get(i);
249 if (node != mRootNode) {
250 childList.add(node.mAnimation);
267 Node node = mNodes.get(i);
268 Animator animation = node.mAnimation;
415 Node node = mNodeMap.get(anim);
416 if (node.mChildNodes != null) {
417 int childSize = node.mChildNodes.size();
419 Node child = node.mChildNodes.get(i);
420 if (child.mLatestParent != node) {
442 Node node = mNodes.get(i);
443 if (node != mRootNode && node.mAnimation.isStarted()) {
492 Node node = mNodes.get(i);
493 if (node == mRootNode) {
494 node.mEndTime = mStartDelay;
496 node.mStartTime = node.mStartTime == DURATION_INFINITE ?
497 DURATION_INFINITE : node.mStartTime + delta;
498 node.mEndTime = node.mEndTime == DURATION_INFINITE ?
499 DURATION_INFINITE : node.mEndTime + delta;
545 Node node = mNodes.get(i);
546 if (node != mRootNode) {
547 node.mAnimation.setupStartValues();
556 Node node = mNodes.get(i);
557 if (node != mRootNode) {
558 node.mAnimation.setupEndValues();
574 Node node = mNodes.get(i);
575 if (node != mRootNode) {
576 node.mAnimation.pause();
594 Node node = mNodes.get(i);
595 if (node != mRootNode) {
596 node.mAnimation.resume();
619 Node node = mNodes.get(i);
620 node.mEnded = false;
621 node.mAnimation.setAllowRunningAsynchronously(false);
626 Node node = mNodes.get(i);
627 node.mAnimation.setInterpolator(mInterpolator);
665 Node node = mNodes.get(i);
668 node.mAnimation.setDuration(mDuration);
674 void start(final Node node) {
675 final Animator anim = node.mAnimation;
701 // Walk through the old nodes list, cloning each node and adding it to the new nodemap.
702 // One problem is that the old node dependencies point to nodes in the old AnimatorSet.
706 final Node node = mNodes.get(n);
707 Node nodeClone = node.clone();
708 node.mTmpClone = nodeClone;
730 Node node = mNodes.get(i);
731 // Update dependencies for node's clone
732 node.mTmpClone.mLatestParent = node.mLatestParent == null ?
733 null : node.mLatestParent.mTmpClone;
734 int size = node.mChildNodes == null ? 0 : node.mChildNodes.size();
736 node.mTmpClone.mChildNodes.set(j, node.mChildNodes.get(j).mTmpClone);
738 size = node.mSiblings == null ? 0 : node.mSiblings.size();
740 node.mTmpClone.mSiblings.set(j, node.mSiblings.get(j).mTmpClone);
742 size = node.mParents == null ? 0 : node.mParents.size();
744 node.mTmpClone.mParents.set(j, node.mParents.get(j).mTmpClone);
813 // Traverse the tree and find if there's any unfinished node
851 Node node = mNodes.get(i);
852 if (!node.mAnimation.canReverse() || node.mAnimation.getStartDelay() > 0) {
867 Node node = mNodes.get(i);
868 node.mAnimation.reverse();
878 Node node = mNodes.get(i);
879 returnVal += "\n " + node.mAnimation.toString();
894 Node node = list.get(index);
896 if (node.mChildNodes != null) {
897 for (int i = 0; i < node.mChildNodes.size(); i++) {
898 Node child = node.mChildNodes.get(i);
899 if (child.mLatestParent == node) {
935 Node node = mNodes.get(i);
936 if (node.mParentsAdded) {
940 node.mParentsAdded = true;
941 if (node.mSiblings == null) {
946 findSiblings(node, node.mSiblings);
947 node.mSiblings.remove(node);
950 int siblingSize = node.mSiblings.size();
952 node.addParents(node.mSiblings.get(j).mParents);
957 Node sibling = node.mSiblings.get(j);
958 sibling.addParents(node.mParents);
964 Node node = mNodes.get(i);
965 if (node != mRootNode && node.mParents == null) {
966 node.addParent(mRootNode);
979 Node node = mNodes.get(i);
980 node.mTotalDuration = node.mAnimation.getTotalDuration();
981 if (node.mEndTime == DURATION_INFINITE) {
985 maxEndTime = node.mEndTime > maxEndTime ? node.mEndTime : maxEndTime;
1001 Node node = mNodes.get(i);
1002 if (node != mRootNode) {
1003 node.mStartTime = DURATION_INFINITE;
1004 node.mEndTime = DURATION_INFINITE;
1052 private void findSiblings(Node node, ArrayList<Node> siblings) {
1053 if (!siblings.contains(node)) {
1054 siblings.add(node);
1055 if (node.mSiblings == null) {
1058 for (int i = 0; i < node.mSiblings.size(); i++) {
1059 findSiblings(node.mSiblings.get(i), siblings);
1086 Node node = mNodeMap.get(anim);
1087 if (node == null) {
1088 node = new Node(anim);
1089 mNodeMap.put(anim, node);
1090 mNodes.add(node);
1092 return node;
1106 * after current node.
1116 * Flag indicating whether the animation in this node is finished. This flag
1124 * associated with this current node.
1129 * Parent nodes are the nodes with animations preceding current node's animation. Parent
1135 * Latest parent is the parent node associated with a animation that finishes after all
1159 Node node = (Node) super.clone();
1160 node.mAnimation = mAnimation.clone();
1162 node.mChildNodes = new ArrayList<>(mChildNodes);
1165 node.mSiblings = new ArrayList<>(mSiblings);
1168 node.mParents = new ArrayList<>(mParents);
1170 node.mEnded = false;
1171 return node;
1177 void addChild(Node node) {
1181 if (!mChildNodes.contains(node)) {
1182 mChildNodes.add(node);
1183 node.addParent(this);
1187 public void addSibling(Node node) {
1191 if (!mSiblings.contains(node)) {
1192 mSiblings.add(node);
1193 node.addSibling(this);
1197 public void addParent(Node node) {
1201 if (!mParents.contains(node)) {
1202 mParents.add(node);
1203 node.addChild(this);
1273 * This tracks the current node being processed. It is supplied to the play() method
1298 Node node = getNodeForAnimation(anim);
1299 mCurrentNode.addSibling(node);
1313 Node node = getNodeForAnimation(anim);
1314 mCurrentNode.addChild(node);
1328 Node node = getNodeForAnimation(anim);
1329 mCurrentNode.addParent(node);