sceneGetter.vwf.yaml 1.1 KB

123456789101112131415161718192021222324252627282930313233
  1. # Copyright 2014 Lockheed Martin Corporation
  2. #
  3. # Licensed under the Apache License, Version 2.0 (the "License"); you may
  4. # not use this file except in compliance with the License. You may obtain
  5. # a copy of the License at
  6. #
  7. # http://www.apache.org/licenses/LICENSE-2.0
  8. #
  9. # Unless required by applicable law or agreed to in writing, software
  10. # distributed under the License is distributed on an "AS IS" BASIS,
  11. # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  12. # See the License for the specific language governing permissions and
  13. # limitations under the License.
  14. ---
  15. properties:
  16. scene:
  17. get: |
  18. if ( !this.scene ) {
  19. this.scene = this.find( this.scenePath || "/" )[ 0 ];
  20. }
  21. return this.scene;
  22. //@ sourceURL=sceneGetter.scene.get
  23. scenePath:
  24. set: |
  25. if ( value === this.scenePath ) {
  26. return;
  27. }
  28. this.scenePath = value;
  29. // Nullify the current scene so that next time it is gotten, it will find it from the new path
  30. this.scene = null;
  31. //@ sourceURL=sceneGetter.scenePath.set