This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| class JTTrueSizeSurface | |
| @DEFAULT_OPTIONS = {} | |
| JTTrueSizeSurface.prototype = Object.create(Surface.prototype) | |
| JTTrueSizeSurface.prototype.constructor = JTTrueSizeSurface | |
| constructor: (id) -> | |
| @id = id | |
| Surface.apply(this, arguments) | |
| @size = this.getSize() |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var scrollToPosition = function (finalPos, transition) { | |
| var lastPos = scroller.getPosition(); | |
| var transitionable = new Transitionable(lastPos); | |
| var prerender = function () { | |
| scroller.setVelocity(0); | |
| scroller.setPosition(transitionable.get()); | |
| }; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var Engine = require("famous/core/Engine"); | |
| var Surface = require("famous/core/Surface"); | |
| var Scrollview = require("famous/views/Scrollview"); | |
| var ContainerSurface = require('famous/surfaces/ContainerSurface'); | |
| var mainContext = Engine.createContext(); | |
| var scrollview = new Scrollview(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var Engine = require("famous/core/Engine"); | |
| var Surface = require("famous/core/Surface"); | |
| var Scrollview = require("famous/views/Scrollview"); | |
| var Transform = require("famous/core/Transform"); | |
| var ContainerSurface = require('famous/surfaces/ContainerSurface'); | |
| var mainContext = Engine.createContext(); | |
| var scrollview = new Scrollview({ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Note: Edit to Force.js | |
| // The Engine sends applyForce a list of bodies, even when a single body is attached | |
| // eg.. | |
| // engine.attach(gravity,body) | |
| // DOES NOT WORK | |
| // applyForce to work with the current physics engine must be defined as follows: | |
| // | |
| // Force.prototype.applyForce = function applyForce(bodies) { | |
| // for (var i = 0; i < bodies.length; i++) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /*global module:false*/ | |
| /*Generated initially from grunt-init, heavily inspired by yo webapp*/ | |
| module.exports = function(grunt) { | |
| 'use strict'; | |
| // Load grunt tasks automatically | |
| require('load-grunt-tasks')(grunt); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var Engine = require("famous/core/Engine"); | |
| var Surface = require("famous/core/Surface"); | |
| var mainContext = Engine.createContext(); | |
| content = document.createElement('p') | |
| content.innerHTML = "Hello" | |
| content.onclick = function(){console.log("Hello!")} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Engine = require 'famous/core/Engine' | |
| Surface = require 'famous/core/Surface' | |
| View = require 'famous/core/View' | |
| Transform = require 'famous/core/Transform' | |
| RenderNode = require 'famous/core/RenderNode' | |
| StateModifier = require 'famous/modifiers/StateModifier' | |
| Easing = require 'famous/transitions/Easing' | |
| Transitionable = require 'famous/transitions/Transitionable' | |
| SpringTransition = require 'famous/transitions/SpringTransition' | |
| WallTransition = require 'famous/transitions/WallTransition' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| define(function(require, exports, module) { | |
| var Engine = require('famous/core/Engine'); | |
| var Surface = require('famous/core/Surface'); | |
| var Scrollview = require('famous/views/Scrollview'); | |
| var SequentialLayout = require('famous/views/SequentialLayout'); | |
| var context = Engine.createContext(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var Engine = require("famous/core/Engine"); | |
| var Surface = require("famous/core/Surface"); | |
| var Modifier = require('famous/core/Modifier'); | |
| var Transform = require('famous/core/Transform'); | |
| var Easing = require('famous/transitions/Easing'); | |
| var Transitionable = require('famous/transitions/Transitionable'); | |
| var mainContext = Engine.createContext(); |
OlderNewer