cz: arthurdebert: well I've fixed it, but I'm always up for ripping out features
arthurdebert
sjl cz I just think it's too much trouble for very little gain, but it's fine really
sjl
wow it's actually snowing quite a bit here
postage-stamp-sized flakes
cz
arthurdebert sjl: create a ticket for tearing out text-only uploads. CC Maggie in a comment and just make sure there's no concrete reason we shouldn't do it.
nicksergeant: i need to listen to mouse movement and typing on the new editor for session idling but i just can't find a good place for it. maybe onSubtitlesFetched?
fernandotakai: that's already setup for video keybindings. perfect place for the pausing stuff.
fernandotakai
nicksergeant: ok
nicksergeant
man I miss working in Angular
lol
unisub-jenkins-b has quit
unisub-jenkins-b joined the channel
cz
lol
fernandotakai
nicksergeant: another thing, i need two timers - one for regaining locks and one for timing out after 5min without action – is the directive a good place for that too?
nicksergeant
fernandotakai: yup, anything to do with binding / throwing events on DOM objects should be done in directives
fernandotakai: controllers = view logic, directives = DOM everything, services = data layer
fernandotakai
looking at angular then at closure code is just bizarre.
nicksergeant
fernandotakai: you may want to create a service if you have some wild logic going on with regaining locks and things like that
fernandotakai
nicksergeant: yeah, we need http requests for that
nicksergeant
especially if we need to auto save and stuff
yup throw that in a new service
you can look at the subtitlestorage service as an example
sjl hears http and locks
lol
sjl cringes
fernandotakai
closure == jee angular == anything that is not jee
nicksergeant
sjl: hey this is angular land, it's all cherries and gumdrops over here
sjl
lol
fernandotakai
you can replace jee with spring too
nicksergeant googles jee
even though angular has dependency injection just like spring
nicksergeant
i still don't get deps injection for angular
it hasn't clicked for me yet
is it just how you define dependencies by throwing them in the function args?
fernandotakai
more or less, you specify a param and then an object is automatically added there (via config or via convention)
nicksergeant
ah, gotcha
yeah that is pretty great
a little magical
but it's nice
fernandotakai
its magical in js because you just specify a name
maggie_s_ has quit
in java, you use interfaces + configs. then when you want to test, the configs change to inject a 'mock' object
in Clojure, you try to do as much work as possible in pure functions, so you can test each individually and they don't have any dependencies to mock
nicksergeant
the only thing I know about Java is that I barely passed it in college
sjl: yes, I like that ideal. We do the same in JS, I think. *horror warning* - In Node, it's nice because you can pass mock request objects to test things like user auth, etc
though that's more at the web layer than logic
so you still need to mock requests
sjl
Yeah, in Clojure the "request object" would just be a vanilla map
nicksergeant
yeah same as in Node when you're doing testing
sjl
so you don't really need to "mock" anything, you just create the map as normal
nicksergeant
it was refreshing to not have to use an HTTP layer to do testing