Skip to content

Instantly share code, notes, and snippets.

View ralfschimmel's full-sized avatar
:octocat:

Ralf Schimmel ralfschimmel

:octocat:
  • Gynzy
  • Nijmegen, the Netherlands
View GitHub Profile
@ralfschimmel
ralfschimmel / gist:1080339
Created July 13, 2011 13:59
Make a scrollview draggable to left and right
/*globals App */
App.DragView = SC.ScrollView.extend({
backgroundColor: 'black',
touchStart: function(touch) {
var f = this.get("frame");
this._touch = {
start: {
x: touch.pageX,
@ralfschimmel
ralfschimmel / collection_view_should_respond_to_test_event.js
Created November 24, 2011 11:39
Failtest sproutcore childview in collectionview
require('sproutcore');
require('sproutcore-touch');
var set = SC.set, get = SC.get;
var tapEndWasCalled = true;
module("Touching handlebars tests", {
setup: function() {
console.group(' - Setup for new test');
@ralfschimmel
ralfschimmel / addActor.js
Created November 28, 2011 10:05
saving newly created nested records to a relation
addActor: function() {
........
var actor = this.actorNestedStore.createRecord(Bw.AssignmentActor, {});
this.newActors.pushObject(actor);
............
}
{{#view Luh.Ui.TabMainView currentView="pane1"}}
{{#view Luh.Ui.TabPaneView id="pane1" class="content" viewName="pane1"}}
{{/view}}
{{#view Luh.Ui.TabPaneView id="pane2" class="content" viewName="pane2"}}
{{/view}}
@ralfschimmel
ralfschimmel / carousel_view.js
Created January 16, 2012 16:10 — forked from ppcano/carousel_view.js
Ember Touch ScrollView without iScroll, and using movejs for transfomations.
@ralfschimmel
ralfschimmel / gist:1783247
Created February 9, 2012 21:10
Buildfile Thoth-client
config :all, :required => [:sproutcore,"sproutcore/animation", "sproutcore/datastore", :ThothSC]
proxy "/thoth",
:to => "fungi.no.de:9090",
# :secure => true, # Use https
:timeout => 25 # Longer timeout for polling transports
@ralfschimmel
ralfschimmel / gist:1783252
Created February 9, 2012 21:11
datasource
Bw.ThothDataSourceStaging = ThothSC.DataSource.extend({
connectUsing: ThothSC.SOCKETIO,
ThothHost: 'fungi.no.de',
ThothPort: '9090',
sendComputedProperties: false,
sendProperties : true,
sendRelations: true,
combineReturnCalls: true,
logTraffic:false
});
@ralfschimmel
ralfschimmel / Assetfile
Created February 23, 2012 20:33
ember-skeleton QUnit
#Add this to you asset file
match 'tests/**/*.js' do
filter LoaderFilter,
:module_id_generator => proc { |input|
input.path.sub(/^lib\//, "#{APPNAME}/").sub(/\.js$/, '')
}
concat 'yourlib-tests.js'
end
@ralfschimmel
ralfschimmel / gist:1901495
Created February 24, 2012 15:05
Ember double each4
{{#each rows}}
<tr style="background-color: red;">
{{#each this}}
<td>{{this}}</td>
{{/each}}
</tr>
{{/each}}
@ralfschimmel
ralfschimmel / a.a
Last active December 16, 2015 17:08 — forked from d3noob/.block
Test scholen
a