Lines Matching refs:node

69      * to a single node representing that Animator, not create a new Node
219 for (Node node : mNodes) {
220 childList.add(node.animation);
234 for (Node node : mNodes) {
235 Animator animation = node.animation;
335 for (Node node : mSortedNodes) {
336 node.animation.cancel();
361 for (Node node : mSortedNodes) {
365 node.animation.addListener(mSetListener);
372 for (Node node : mSortedNodes) {
373 node.animation.end();
394 for (Node node : mNodes) {
395 if (node.animation.isRunning()) {
465 for (Node node : mNodes) {
466 node.animation.setupStartValues();
472 for (Node node : mNodes) {
473 node.animation.setupEndValues();
485 for (Node node : mNodes) {
486 node.animation.pause();
500 for (Node node : mNodes) {
501 node.animation.resume();
521 for (Node node : mNodes) {
522 node.animation.setAllowRunningAsynchronously(false);
527 for (Node node : mNodes) {
530 node.animation.setDuration(mDuration);
534 for (Node node : mNodes) {
535 node.animation.setInterpolator(mInterpolator);
544 Node node = mSortedNodes.get(i);
546 ArrayList<AnimatorListener> oldListeners = node.animation.getListeners();
554 node.animation.removeListener(listener);
566 Node node = mSortedNodes.get(i);
570 if (node.dependencies == null || node.dependencies.size() == 0) {
571 nodesToStart.add(node);
573 int numDependencies = node.dependencies.size();
575 Dependency dependency = node.dependencies.get(j);
576 dependency.node.animation.addListener(
577 new DependencyListener(this, node, dependency.rule));
579 node.tmpDependencies = (ArrayList<Dependency>) node.dependencies.clone();
581 node.animation.addListener(mSetListener);
585 for (Node node : nodesToStart) {
586 node.animation.start();
587 mPlayingSet.add(node.animation);
601 Node node = nodesToStart.get(i);
602 node.animation.start();
603 mPlayingSet.add(node.animation);
656 // Walk through the old nodes list, cloning each node and adding it to the new nodemap.
657 // One problem is that the old node dependencies point to nodes in the old AnimatorSet.
661 final Node node = mNodes.get(n);
662 Node nodeClone = node.clone();
663 node.mTmpClone = nodeClone;
687 final Node node = mNodes.get(n);
688 final Node clone = node.mTmpClone;
689 if (node.dependencies != null) {
690 clone.dependencies = new ArrayList<Dependency>(node.dependencies.size());
691 final int depSize = node.dependencies.size();
693 final Dependency dependency = node.dependencies.get(i);
694 Dependency cloneDependency = new Dependency(dependency.node.mTmpClone,
699 if (node.nodeDependents != null) {
700 clone.nodeDependents = new ArrayList<Node>(node.nodeDependents.size());
701 for (Node dep : node.nodeDependents) {
705 if (node.nodeDependencies != null) {
706 clone.nodeDependencies = new ArrayList<Node>(node.nodeDependencies.size());
707 for (Node dep : node.nodeDependencies) {
727 // The node upon which the dependency is based.
731 // the node
734 public DependencyListener(AnimatorSet animatorSet, Node node, int rule) {
736 this.mNode = node;
773 * Check whether the event received is one that the node was waiting for.
788 dependency.node.animation == dependencyAnimation) {
881 * - remove r as a dependency from any other node
890 Node node = mNodes.get(i);
891 if (node.dependencies == null || node.dependencies.size() == 0) {
892 roots.add(node);
904 Node node = root.nodeDependents.get(j);
905 node.nodeDependencies.remove(root);
906 if (node.nodeDependencies.size() == 0) {
907 tmpRoots.add(node);
927 Node node = mNodes.get(i);
928 if (node.dependencies != null && node.dependencies.size() > 0) {
929 int numDependencies = node.dependencies.size();
931 Dependency dependency = node.dependencies.get(j);
932 if (node.nodeDependencies == null) {
933 node.nodeDependencies = new ArrayList<Node>();
935 if (!node.nodeDependencies.contains(dependency.node)) {
936 node.nodeDependencies.add(dependency.node);
942 node.done = false;
956 for (Node node : mNodes) {
957 if (!node.animation.canReverse() || node.animation.getStartDelay() > 0) {
970 for (Node node : mNodes) {
971 node.animation.reverse();
982 for (Node node : mSortedNodes) {
983 returnVal += "\n " + node.animation.toString();
989 * Dependency holds information about the node that some other node is
994 static final int WITH = 0; // dependent node must start with this dependency node
995 static final int AFTER = 1; // dependent node must start when this dependency node finishes
997 // The node that the other node with this Dependency is dependent upon
998 public Node node;
1003 public Dependency(Node node, int rule) {
1004 this.node = node;
1019 * These are the dependencies that this node's animation has on other
1020 * nodes. For example, if this node's animation should begin with some
1021 * other animation ends, then there will be an item in this node's
1022 * dependencies list for that other animation's node.
1039 * This information is used in sortNodes(), to determine when a node is a root.
1044 * nodeDepdendents is the list of nodes that have this node as a dependency. This
1045 * is a utility field used in sortNodes to facilitate removing this node as a
1046 * dependency when it is a root node.
1051 * Flag indicating whether the animation in this node is finished. This flag
1075 * node that this node is dependency upon and the nature of the dependency.
1084 if (!nodeDependencies.contains(dependency.node)) {
1085 nodeDependencies.add(dependency.node);
1087 Node dependencyNode = dependency.node;
1097 Node node = (Node) super.clone();
1098 node.animation = animation.clone();
1099 node.done = false;
1100 return node;
1162 * This tracks the current node being processed. It is supplied to the play() method
1191 Node node = mNodeMap.get(anim);
1192 if (node == null) {
1193 node = new Node(anim);
1194 mNodeMap.put(anim, node);
1195 mNodes.add(node);
1198 node.addDependency(dependency);
1212 Node node = mNodeMap.get(anim);
1213 if (node == null) {
1214 node = new Node(anim);
1215 mNodeMap.put(anim, node);
1216 mNodes.add(node);
1219 node.addDependency(dependency);
1233 Node node = mNodeMap.get(anim);
1234 if (node == null) {
1235 node = new Node(anim);
1236 mNodeMap.put(anim, node);
1237 mNodes.add(node);
1239 Dependency dependency = new Dependency(node, Dependency.AFTER);