Youtube fixes

git-svn-id: http://vkopt.googlecode.com/svn/trunk@519 abbab872-c1ea-7929-a236-346daee65547
git-svn-id: http://vkopt.googlecode.com/svn/trunk@520 abbab872-c1ea-7929-a236-346daee65547
feat(build): integrate with Travis

- link "npm test" to "gulp test"
- add basic .travis.yml file
feat(build): run "dist" task after testing on Travis

This ensures that not only source is correct, but build process is also
working.
docs(build): add "Build status" section to gulpfile.litcoffee

This finally closes #73.
style(injection): rename makeAjaxRequest() to handleOldAjax()

In meta/*/helpers.litcoffee rename makeAjaxRequest() to
handleOldAjax() to make it clear what it does and to distinguish
from the upcoming new ajax interface.
refactor(chromium background ajax): replace interface with new one

- remove meta tests as they were dumb
- remove chromium/helpers.litcoffee
- add SuperAgent to Bower background dependencies
- copy SuperAgent to chromium/helpers.js during build process
- use SuperAgent to handle ajax requests
refactor(vk_lib): AjGet, AjPost, AjCrossAttachJS - adapters for app.ajax

Use app.ajax in these functions.
fix(chromium background ajax): multiple fixes (I'm sorry)

- "request" > "superagent" (that's what SuperAgent exports)
- "inject.licoffee" > "inject.template.litcoffee", since we use
"<%= name %>"
- manually copy safe properties from response to data as there
other ones that can't be stringified
refactor(vk_ext_api): use app.ajax

- remove vk_ext_api.get(), .head() and .post() as there's only one
use case for each one. Use app.ajax directly in those cases.
- remove vk_ext_api.req() and throw an error when it is called.
This is done to see where it is used
fix(ajax): return response.text instead of response.body

Currently all the code expects raw response text here.
style(chromium background ajax): fix newlines in inject.litcoffee
refactor(firefox background ajax): replace interface with new one

- remove firefox/chrome/content/helpers.litcoffee
- copy SuperAgent to firefox/.../helpers.js during build process
- use SuperAgent to handle ajax requests
refactor(maxthon background ajax): replace interface with new one

- remove maxthon/helpers.litcoffee
- copy SuperAgent to maxthon/helpers.js during build process
- use SuperAgent to handle ajax requests
refactor(opera background ajax): replace interface with new one

- remove opera/helpers.litcoffee
- copy SuperAgent to opera/helpers.js during build process
- use SuperAgent to handle ajax requests
feat(ajax): allow to specify custom request headers

Provide "headers" option in app.ajax.* methods.
feat(injection): allow vk_lib.js to run in frames

- move all old source/*.js files to source/run-in-top/
- copy source/run-in-top/vk_lib.js to source/run-in-frames/
- inject new *.litcoffee files and run-in-top/* to top windows only
- inject new *.litcoffee files and run-in-frames/* to frames only
- run source/*.* and source/run-in-top/*.* before tests

This doesn't fix VKDAPI app authorization (see #59) but is related
to it.
fix(chromium injection): allow to run on *.vk.com
style(source): rename source/run-in-frames/23_vk_lib.js to vk_lib.js
git-svn-id: http://vkopt.googlecode.com/svn/trunk@521 abbab872-c1ea-7929-a236-346daee65547