| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
binary messages. A simple gin file access module would simplify writing the tests:
file.getSourceRootDirectory() - return the path to the root src directory
file.getFilesInDirectory(path) - return an array of the filenames found in path. Do not return subdirectory names or links.
file.readFileToString(path) - return the contents of the file as a string.
BUG=397554
Review URL: https://codereview.chromium.org/419673004
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@286484 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
| |
The API calls are per Isolate, and therefore should be on the isolate.
Make it so.
BUG=397026
R=haraken@chromium.org
Review URL: https://codereview.chromium.org/425043002
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@286325 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
| |
Renamed gin_shell's local gin::ModuleRunnerDelegate subclass to since it was being overridden by the gin::ShellRunner base class.
BUG=397263
Review URL: https://codereview.chromium.org/413333002
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@285943 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
| |
BUG=328119
Review URL: https://codereview.chromium.org/401723002
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@285023 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
| |
It simply forwards the flag from v8::FunctionCallbackInfo and allows
the function handler that accept gin::Arguments argument to distinguish
between normal function invocation and call as an object construction.
BUG=
Review URL: https://codereview.chromium.org/401823002
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@284123 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
| |
BUG=391888
Review URL: https://codereview.chromium.org/373973003
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@281966 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
| |
The unittest also serves as an example how to use the interceptor API.
BUG=none
R=abarth@chromium.org,raymes@chromium.org
Review URL: https://codereview.chromium.org/352223008
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@280350 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This test was supposed to test that gin can cope with v8 throwing
exceptions during object construction, e.g. when we run out of stack
space.
There is, however, no reliable way to emulate "running out of stack" in
a unit test without risking to also crash because of OOM.
BUG=none
R=dcarney@chromium.org
Review URL: https://codereview.chromium.org/337883005
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@280336 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
| |
Implement webkit/common/gpu.
Minor fixes to the gin unit tests (it defines its own test runner so shouldn't depend on run_all_unittests -- GN found this because run_all_unittests in the GN build is a source_set instead of a static library and results in a duplicate definition).
R=jochen@chromium.org
Review URL: https://codereview.chromium.org/319583004
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@275233 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
| |
Clean up gin run all unittests file. I noticed some extra includes while searching for some code to copy.
BUG=
R=jochen@chromium.org
Review URL: https://codereview.chromium.org/318543002
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@274850 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
| |
TBR=aa@chromium.org
Review URL: https://codereview.chromium.org/294163002
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@272361 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
| |
Promises are now enabled by default
BUG=none
R=adamk@chromium.org
Review URL: https://codereview.chromium.org/290273004
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@271410 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
| |
Remove ArrayBuffer ctor that is not defined.
Add explicit assignment operator for ArrayBufferView.
BUG=none
R=dcarney@chromium.org,mnaganov@chromium.org
Review URL: https://codereview.chromium.org/289003007
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@271003 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
| |
BUG=368728
R=abarth@chromium.org
Review URL: https://codereview.chromium.org/261823009
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@267972 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
| |
This CL is basically revert of https://codereview.chromium.org/195893017/.
TEST=layout tests, gin_unittests
Review URL: https://codereview.chromium.org/236883002
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@264170 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
| |
BUG=none
R=dcarney@chromium.org
Review URL: https://codereview.chromium.org/230653003
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@263243 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
| |
We shouldn't use experimental features. Restrict usage to promises which
is actually used by mojo/js and about to launch.
BUG=360554
R=abarth@chromium.org
Review URL: https://codereview.chromium.org/228253002
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@262639 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
| |
- no longer try to use the default isolate (we want to remove it from v8)
- add the option to gin to manage an isolate in non-strict mode
BUG=359977
R=eroman@chromium.org,abarth@chromium.org
Review URL: https://codereview.chromium.org/227233006
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@262559 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
| |
This currently has no effect unless concurrent sweeping and job based
sweeping is turned on in v8.
BUG=v8:3015
R=abarth@chromium.org,dcarney@chromium.org
Review URL: https://codereview.chromium.org/225413004
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@261872 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
| |
collected, rather than a raw integer.
BUG=357785
Review URL: https://codereview.chromium.org/214183003
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@261479 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Now gin doesn't convert JavaScript double to an integer. This means that
gin::Arguments::GetNext() with a pointer of an integer fails when the
next arguments is double, and nothing is set to the vairable. IMO this
can cause bugs which are hard to understand. It is because on JavaScript
side we can't distinguish integer and double, and GetNext() with an
integer variable and JS number produces unstable results.
For example, In [1], EventSender's mouseMoveTo is called with arguments
which can be doubles, not integers, but EventSender::mouseToMove excepts
integers. Now EventSender is implemented by CppBoundClass and toInt32 is
used explicitly, but now EventSender is being moved to gin, and using
GetNext with integer vairables simply will fail.
[1] https://code.google.com/p/chromium/codesearch#chromium/src/third_party/WebKit/LayoutTests/fast/events/5056619.html&sq=package:chromium
BUG=331301
TEST=gin_unittests --gtest_filter=ConverterTest.Int32
Review URL: https://codereview.chromium.org/195893017
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@257105 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
| |
BUG=297480, 331301
TEST=all layout tests
Review URL: https://codereview.chromium.org/185263006
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@257079 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
| |
Script::Compile is the right way (see previous changes in
https://codereview.chromium.org/178663008 ).
R=jochen@chromium.org
BUG=
Review URL: https://codereview.chromium.org/196573003
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@256538 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
| |
This will allow for using gin as a drop-in replacement for NPObject.
BUG=347565
R=abarth@chromium.org,dcarney@chromium.org,aa@chromium.org
Review URL: https://codereview.chromium.org/194603003
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@256431 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
| |
This moves AppendFile, GetCurrentDirectory, and SetCurrentDirectory to the base namespace.
TBR=jam
Review URL: https://codereview.chromium.org/177923007
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@256309 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
| |
BUG=347565
R=dcarney@chromium.org
Review URL: https://codereview.chromium.org/192693002
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@255927 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This will be used to know when a module has been added so that I can
download needed modules.
BUG=none
TEST=none
R=abarth@chromium.org
Review URL: https://codereview.chromium.org/187653004
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@255291 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Verifies ModuleRegistry can be looked up from context and that it is
no longer available once ContextHolder is destroyed.
Similarly verifies PerContextData is available once a ContextHolder is
created and that it's context_holder() member points back to the
ContextHolder.
BUG=none
TEST=none
R=abarth@chromium.org
Review URL: https://codereview.chromium.org/182683005
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@254362 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
I need this as WebKit creates the ContextHolder and I need a handle to
it.
BUG=none
TEST=none
R=abarth@chromium.org
Review URL: https://codereview.chromium.org/184013002
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@254250 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This gives the same functionality and ownership model while making it
simpler to associate arbitrary data with a context.
BUG=none
TEST=none
R=abarth@chromium.org
Review URL: https://codereview.chromium.org/183433002
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@254126 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
In some extreme cases, ObjectTemplate::NewInstance might return an empty
handler. For example, the getter and setter
Object.prototype.constructor can be rewritten with a evil function which
can throw exceptions.
BUG=331301
TEST=gin_unittests --gtest_filter=WrappableTest.ErrorInObjectConstructorProperty
Review URL: https://codereview.chromium.org/184253004
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@254109 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
I forgot to change these when I renamed from DefaultRunner to
ShellRunner.
BUG=none
TEST=none
R=abarth@chromium.org
TBR=abarth@chromium.org
Review URL: https://codereview.chromium.org/179203005
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@253906 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Script::New creates a context-independent script. Using it only makes sense if
the resulting Script will be run in many different contexts. All these places
run the script right after creating it, and only in one context. So they should
have used Script::Compile, which creates a Script bound to the current
context. Context-bound scripts are more efficient than context-unbound scripts.
R=jochen@chromium.org
BUG=
Review URL: https://codereview.chromium.org/178663008
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@253884 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
. Runner no longer extends ContextHolder. It will still have a
ContextHolder, but not own it. This enables a couple of
things:
. Runner no longer need own a v8::Context.
. Runner can be lazily created after the ContextHolder.
. Runner becomes a (mostly) pure virtual interface. This enables an
implementation to execute through blink rather than v8 directly.
. What was Runner is now DefaultRunner (and
DefaultRunnerDelegate). I'm not a fan of these names, if you have
better ideas let me know. Maybe DirectRunner?
BUG=none
TEST=none
R=abarth@chromium.org
Review URL: https://codereview.chromium.org/179803007
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@253732 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
| |
BUG=none
R=abarth@chromium.org
Review URL: https://codereview.chromium.org/173843002
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@253089 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This approach won't let use share an array buffer with blink, however,
it's good enough for a mojo js app.
For gin::Wrappable objects that want to interact with blink APIs, they
need to provide a custom converter to and from WebArrayBuffer(View)
BUG=none
R=abarth@chromium.org, dslomov@chromium.org, sky@chromium.org
Review URL: https://codereview.chromium.org/172133002
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@252190 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
| |
Otherwise, the function template will keep the context alive it was
created in.
BUG=342272
R=dcarney@chromium.org,aa@chromium.org,haraken@chromium.org
Review URL: https://codereview.chromium.org/141143012
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@250412 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
| |
This is part of attempting to get rid of MessageLoop::Type enum.
BUG=none
TEST=none
R=darin@chromium.org
Review URL: https://codereview.chromium.org/136683004
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@244996 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
| |
Am having trouble coming up with a satisfactory way to test.
BUG=
Review URL: https://codereview.chromium.org/129633005
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@244062 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
| |
R=abarth@chromium.org
Review URL: https://codereview.chromium.org/126743002
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@243637 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
| |
Cleaned up a few of the existing tests.
BUG=
R=abarth@chromium.org
Review URL: https://codereview.chromium.org/100143006
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@243185 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
| |
R=abarth@chromium.org
Review URL: https://codereview.chromium.org/108723006
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@243183 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
| |
TBR=dcarney@chromium.org
BUG=none
Review URL: https://codereview.chromium.org/109563003
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@242884 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
| |
Review URL: https://codereview.chromium.org/116953003
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@242342 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
| |
Various further rework of bindings stuff to facilitate.
Review URL: https://codereview.chromium.org/120043008
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@242284 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
| |
Right now I am just translating as directly as possible from the C spinning cube demo -- once it all works I will circle back through and refine the JavaScript.
R=abarth@chromium.org
Review URL: https://codereview.chromium.org/114883003
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@242230 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
| |
R=jochen@chromium.org
BUG=324225
Review URL: https://codereview.chromium.org/119093004
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@241869 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
We first need to cast the void pointer to WrappableBase before we
can cast it to the derived class: initially a WrappableBase* is
stored as holder, so we can't directly cast it to the derived class.
To test this, I added a useless base class so the test object this
pointers don't align with the WrappableBase this pointer.
Also update the comments about how to use WrappableBase.
BUG=none
R=aa@chromium.org,dcarney@chromium.org
Review URL: https://codereview.chromium.org/119173002
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@241863 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
| |
This is needed for: https://codereview.chromium.org/116163008/
Review URL: https://codereview.chromium.org/118423004
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@241730 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Instead of explicitly registering object templates for all wrapper
infos, add a method on wrappable that returns the template when
needed.
BUG=none
R=aa@chromium.org,abarth@chromium.org
Review URL: https://codereview.chromium.org/113893005
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@241370 0039d316-1c4b-4281-b951-d872f2087c98
|