Files
old-tfm/app/client/startup.js

17 lines
496 B
JavaScript
Raw Normal View History

2016-10-15 15:58:41 +02:00
Tracker.autorun(function() {
2016-03-06 09:20:36 +01:00
var id = Session.get('controller_id');
Session.set("orientation", new Date());
Session.set("resize", new Date());
2016-03-06 09:20:36 +01:00
if (id) {
Meteor.subscribe("sensor_data", id);
2016-10-08 16:02:59 +02:00
Meteor.subscribe("controller_state", id);
Meteor.subscribe('pictures', id);
2016-03-06 09:20:36 +01:00
}
2017-05-21 17:51:45 +02:00
window.addEventListener('orientationchange', function(){
Session.set("orientation", new Date());
});
window.addEventListener('resize', function(){
Session.set("resize", new Date());
2017-05-21 17:51:45 +02:00
});
2016-03-06 09:20:36 +01:00
});