summaryrefslogtreecommitdiffstats
path: root/mojo
Commit message (Collapse)AuthorAgeFilesLines
* Run aura_demo as a mojo app.ben@chromium.org2014-01-0713-2/+860
| | | | | | | | | | http://crbug.com/330416 R=sky@chromium.org Review URL: https://codereview.chromium.org/120503003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@243393 0039d316-1c4b-4281-b951-d872f2087c98
* Mojo: Remove unused hello_world_service codedarin@chromium.org2014-01-075-99/+0
| | | | | | Review URL: https://codereview.chromium.org/125773002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@243364 0039d316-1c4b-4281-b951-d872f2087c98
* Add support for enums within structs and interfaces to mojom.mpcomplete@google.com2014-01-0716-50/+105
| | | | | | | | | BUG=320090 R=abarth@chromium.org, davemoore@chromium.org Review URL: https://codereview.chromium.org/99623010 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@243341 0039d316-1c4b-4281-b951-d872f2087c98
* Mojo: DataPipe: Write some docs and rationalize some return values.viettrungluu@chromium.org2014-01-072-12/+130
| | | | | | | | | | | | | | | | | | In "all or none" mode, return "out of range" if the required amount of space/data isn't available, unless the other end isn't open (in which case return "failed precondition"). Don't return "should wait", since you can't wait for a specified amount of space/data to be available. (Only return "should wait" when waiting would actually solve your problem.) Note: Still have to write docs for the two-phase DataPipe APIs (but I want to fully test/hash out their semantics first). R=darin@chromium.org Review URL: https://codereview.chromium.org/118873004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@243327 0039d316-1c4b-4281-b951-d872f2087c98
* Gin: Fix console module to be varargs again.aa@chromium.org2014-01-062-5/+4
| | | | | | | | 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
* Mojo: DataPipe: Implement "may discard" mode for simple writes.viettrungluu@chromium.org2014-01-063-9/+131
| | | | | | | | | | (Still need to implement for two-phase writes.) R=darin@chromium.org Review URL: https://codereview.chromium.org/98013005 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@243176 0039d316-1c4b-4281-b951-d872f2087c98
* Mojo: Change use of "not found" to more explicit "should wait".viettrungluu@chromium.org2014-01-0414-43/+41
| | | | | | | | | | (Add a "should wait" error code.) R=darin@chromium.org Review URL: https://codereview.chromium.org/122983004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@242976 0039d316-1c4b-4281-b951-d872f2087c98
* Add test for ServiceManagerdavemoore@chromium.org2014-01-0311-140/+366
| | | | | | | | | | | I also separated out the dynamic service loader from the ServiceManager file, to remove the dependency of the ServiceManager on the shell's context. This made testing cleaner. BUG=None R=viettrungluu@chromium.org, viettrungluu Review URL: https://codereview.chromium.org/122173004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@242952 0039d316-1c4b-4281-b951-d872f2087c98
* Mojo: More DataPipe edge case handling and testing.viettrungluu@chromium.org2014-01-036-23/+244
| | | | | | | | | | | | | Define/test behavior of two-phase writes/reads if they cross (or attempt to cross) close boundaries. Also define/test behavior for a producer writing after the consumer is closed and a consumer reading/discarding after the producer is closed. R=davemoore@chromium.org Review URL: https://codereview.chromium.org/119473006 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@242932 0039d316-1c4b-4281-b951-d872f2087c98
* Mojo: Proper implementations of WriteData/ReadData.viettrungluu@chromium.org2014-01-022-34/+148
| | | | | | | | | | | These no longer use the two-phase versions, and thus write/read as much as possible (not merely as much as possible in a single memcpy). R=davemoore@chromium.org Review URL: https://codereview.chromium.org/122583005 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@242830 0039d316-1c4b-4281-b951-d872f2087c98
* Mojo: Fix DCHECK failure in test.viettrungluu@chromium.org2014-01-021-2/+2
| | | | | | | | | | | ~DataPipe doesn't take the lock (and doesn't have to), which causes lock assertions to fail. TBR=davemoore@chromium.org Review URL: https://codereview.chromium.org/122723003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@242780 0039d316-1c4b-4281-b951-d872f2087c98
* Mojo: Some DataPipe cleanup/simplification.viettrungluu@chromium.org2014-01-024-32/+57
| | | | | | | | | | | | Merge some state (as indicated by the now-deleted FIXME): - two_phase_max_num_bytes_written_ with producer_in_two_phase_write_ - two_phase_max_num_bytes_read_ with consumer_in_two_phase_read_ R=davemoore@chromium.org, davemoore Review URL: https://codereview.chromium.org/114763005 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@242779 0039d316-1c4b-4281-b951-d872f2087c98
* Mojo: Add MessagePipe to core_cpp.h for conveniencedarin@chromium.org2013-12-258-91/+83
| | | | | | Review URL: https://codereview.chromium.org/119563003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@242484 0039d316-1c4b-4281-b951-d872f2087c98
* Make mojo_shell work on Mac OS X againabarth@chromium.org2013-12-231-0/+2
| | | | | | | | R=darin@chromium.org Review URL: https://codereview.chromium.org/120153003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@242345 0039d316-1c4b-4281-b951-d872f2087c98
* Add a simple one shot and repeating timer API for Mojo.js.aa@chromium.org2013-12-2110-18/+18
| | | | | | | | 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
* Mojo: Fix some incorrect DCHECKSdavemoore@chromium.org2013-12-212-2/+3
| | | | | | | | | BUG=None R=ben@chromium.org Review URL: https://codereview.chromium.org/107873003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@242273 0039d316-1c4b-4281-b951-d872f2087c98
* Mojo: Fix android builddavemoore@chromium.org2013-12-2115-199/+35
| | | | | | | | | | | | | - revert abarth's change to make gles2 go through a vtbl - Make NativeViewportService be a component library (static on Android) - Wait to create gles until there's a non empty surface (on android) BUG=None R=abarth Review URL: https://codereview.chromium.org/115563004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@242269 0039d316-1c4b-4281-b951-d872f2087c98
* Sample mojo app using the compositorjamesr@chromium.org2013-12-218-1/+447
| | | | | | | | | | This shows how to use cc from a mojo app. The GLES2 bindings are very sketchy since we don't yet have an implementation of the command buffer support on top of mojo pipes, but the rest is fairly reasonable. Review URL: https://codereview.chromium.org/108853007 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@242261 0039d316-1c4b-4281-b951-d872f2087c98
* Implement more of the JavaScript GL API.aa@chromium.org2013-12-219-147/+315
| | | | | | | | | | 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
* Mojo: Add support for speciying handle<data_pipe_{consumer,producer}> in a ↵darin@chromium.org2013-12-2010-46/+170
| | | | | | | | | | | | | .mojom file. Fix support for arrays of handles. BUG=329648,329647 R=davemoore@chromium.org Review URL: https://codereview.chromium.org/98333007 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@242201 0039d316-1c4b-4281-b951-d872f2087c98
* Remove direct dependency of mojo_shell_lib on mojo_native_viewport_servicedavemoore@chromium.org2013-12-201-6/+4
| | | | | | | | | BUG=None R=abarth@chromium.org Review URL: https://codereview.chromium.org/120083002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@242171 0039d316-1c4b-4281-b951-d872f2087c98
* Fix accidental double import in mojom_bindings_generator.py.mpcomplete@chromium.org2013-12-201-1/+0
| | | | | | | | | BUG=329008 TBR=abarth@chromium.org Review URL: https://codereview.chromium.org/116893005 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@241992 0039d316-1c4b-4281-b951-d872f2087c98
* MessageLoop(TYPE_UI) -> MessageLoopForUIsky@chromium.org2013-12-192-3/+2
| | | | | | | | | | | | | | | Converts creation of MessageLoopForUI from MessageLoop(TYPE_UI) to MessageLoopForUI. This is a step in the direction of moving type out of MessageLoop. BUG=none TEST=none R=darin@chromium.org Review URL: https://codereview.chromium.org/108713004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@241917 0039d316-1c4b-4281-b951-d872f2087c98
* Remove mojom cpp and JS generators and turn on the jinja generator for both.mpcomplete@chromium.org2013-12-1927-1284/+184
| | | | | | | | BUG=329008 Review URL: https://codereview.chromium.org/104503013 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@241793 0039d316-1c4b-4281-b951-d872f2087c98
* Add support for wrapping classes indirectly inherited from gin::Wrappable<T>aa@chromium.org2013-12-192-12/+12
| | | | | | | | 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
* Mojo: Test data pipes from the CoreImpl level.viettrungluu@chromium.org2013-12-191-1/+240
| | | | | | | | | | | | | | Test basic data pipe functionality and also passing data pipe consumer and producer handles over data pipes. From here, confidence that data pipes mostly work (modulo known bugs, and also some unknown) is much higher. R=sky@chromium.org Review URL: https://codereview.chromium.org/118693003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@241713 0039d316-1c4b-4281-b951-d872f2087c98
* Mojo: More data pipe testing.viettrungluu@chromium.org2013-12-181-10/+226
| | | | | | | | | | Test waiting quite thoroughly. R=sky@chromium.org Review URL: https://codereview.chromium.org/108193016 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@241695 0039d316-1c4b-4281-b951-d872f2087c98
* Move geometric types to a separate, more lightweight target.ben@chromium.org2013-12-183-0/+4
| | | | | | | | | R=sky@chromium.org http://crbug.com/327489 Review URL: https://codereview.chromium.org/109433013 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@241649 0039d316-1c4b-4281-b951-d872f2087c98
* Mojo: Add more data pipe tests, fix waiting bug.viettrungluu@chromium.org2013-12-183-8/+104
| | | | | | | | | | Oops, I forgot to wake up waiters on read/write. R=sky@chromium.org Review URL: https://codereview.chromium.org/118443003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@241637 0039d316-1c4b-4281-b951-d872f2087c98
* Mojo: Beginnings of (local) data pipe tests + more refactoring.viettrungluu@chromium.org2013-12-188-93/+273
| | | | | | | | | | | | | | Make the DataPipe methods not take |flags|, to make it more obvious that dealing with/validating |flags| is the responsibility of the caller. Also split ConsumerReadData into three methods (read/discard/query), which parallels what the implementation subclass already had. R=sky@chromium.org Review URL: https://codereview.chromium.org/117763003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@241585 0039d316-1c4b-4281-b951-d872f2087c98
* Pull struct and interface definitions out of module.js.tmpl into their own ↵mpcomplete@chromium.org2013-12-184-104/+108
| | | | | | | | files. Review URL: https://codereview.chromium.org/117673002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@241488 0039d316-1c4b-4281-b951-d872f2087c98
* Add mojom_jinja_generator and jinja templates for the C++ bindings.mpcomplete@chromium.org2013-12-1819-0/+804
| | | | | | | | | | | I believe it's feature compatible with the cpp generator. We still use the old cpp generator currently. I plan on switching in a future CL for simplicity. BUG=329008 Review URL: https://codereview.chromium.org/116793003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@241456 0039d316-1c4b-4281-b951-d872f2087c98
* Implement ServiceManagerdavemoore@chromium.org2013-12-1828-488/+690
| | | | | | | | | BUG=None R=abarth@chromium.org, abarth Review URL: https://codereview.chromium.org/93793009 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@241446 0039d316-1c4b-4281-b951-d872f2087c98
* Mojo: Basic C++ wrappers for the (still-untested) data pipes.viettrungluu@chromium.org2013-12-172-18/+116
| | | | | | | | | | I'd write tests, but I want to start from the "bottom up". R=sky@chromium.org Review URL: https://codereview.chromium.org/114813007 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@241419 0039d316-1c4b-4281-b951-d872f2087c98
* Mojo: Refactor (local) data pipe creation/initialization.viettrungluu@chromium.org2013-12-179-87/+396
| | | | | | | | | | | | | | | | | | | | | - Separate out the validation of options. - Remove |Init()|. Now you can create the LocalDataPipe with your validated options. - Once created, the LocalDataPipe has to be shut down correctly. (This was true before, but broken -- if you ran out of handles in MojoCreateDataPipe(), DCHECKs would fire.) - Add tests for the new |DataPipe::ValidateOptions()|. - Also add a minimal test for LocalDataPipe creation (which led to the discovery of the above bug, and consequently the above refactoring). - Change the struct_size field of options to a |uint32_t|. This makes it much easier to reason about the size of the struct, which we need to be careful about. R=sky@chromium.org Review URL: https://codereview.chromium.org/116573010 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@241393 0039d316-1c4b-4281-b951-d872f2087c98
* [gin] Introduce Wrappable::GetObjectTemplatejochen@chromium.org2013-12-178-54/+13
| | | | | | | | | | | | | 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
* Mojo: Change data pipe API to take # bytes instead of # elements.viettrungluu@chromium.org2013-12-1716-308/+356
| | | | | | | | | | | | | | | | | I discovered a whole bunch of bugs in the existing (totally untested) code. I also noted some refactoring that I want to do urgently (some of which help with those bugs). I noted them with "TODO" and "FIXME" (the latter so that it's easy for me to grep) as things to be fixed ASAP. I wanted to keep this change to (nearly) only the straightforward conversion of the API. The only bugs fixed are that the checks to handle all-or-none mode in two-phase write/read were backwards. R=sky@chromium.org, darin@chromium.org Review URL: https://codereview.chromium.org/107663010 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@241321 0039d316-1c4b-4281-b951-d872f2087c98
* Have jni_generator.gypi specify include_dirs to dependent targets.blundell@chromium.org2013-12-171-5/+0
| | | | | | | | | | | | Rather than each dependent target of a target that generates jni headers having to specify the appropriate include_dir manually, jni_generator.gypi can do it via direct_dependent_settings. TBR=darin@chromium.org Review URL: https://codereview.chromium.org/111493006 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@241216 0039d316-1c4b-4281-b951-d872f2087c98
* Mojo: rename limits.h to constants.h.viettrungluu@chromium.org2013-12-1610-14/+12
| | | | | | | | | | (As suggested by darin in a code review.) R=sky@chromium.org Review URL: https://codereview.chromium.org/103593004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@241022 0039d316-1c4b-4281-b951-d872f2087c98
* Mojo: "Finish" local (in-process) implementation of data pipes.viettrungluu@chromium.org2013-12-168-18/+446
| | | | | | | | | | | | | Still to do: - Write tests. - Fix bug in MojoReadData()/MojoWriteData() (see data_pipe.cc). - Write comments in core.h. R=darin@chromium.org Review URL: https://codereview.chromium.org/113603003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@241015 0039d316-1c4b-4281-b951-d872f2087c98
* Add switch to control app cachingdavemoore@chromium.org2013-12-163-0/+9
| | | | | | | | | BUG=None R=abarth@chromium.org, abarth Review URL: https://codereview.chromium.org/110493003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@240923 0039d316-1c4b-4281-b951-d872f2087c98
* Add missing mojo_utility_unittests target to mojob.shtfarina@chromium.org2013-12-141-3/+4
| | | | | | | | | | | | | | | Also sort the unit tests in alphabetical order so it is easier to add new targets. BUG=None TEST=./mojo/tools/mojob.sh test, verifies it also runs mojo_utility_unittests TBR=darin@chromium.org,viettrungluu@chromium.org NOTRY=true Review URL: https://codereview.chromium.org/115573003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@240813 0039d316-1c4b-4281-b951-d872f2087c98
* Mojo: More data pipe work -- consumer-side dispatcher.viettrungluu@chromium.org2013-12-147-7/+303
| | | | | | | | | | | Define/implement DataPipeConsumerDispatcher, and the parts of the DataPipe base class that it interacts with. R=sky@chromium.org Review URL: https://codereview.chromium.org/101623013 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@240809 0039d316-1c4b-4281-b951-d872f2087c98
* Beginning of JS Mojo API to GL.aa@chromium.org2013-12-1311-11/+327
| | | | | | | | R=abarth@chromium.org Review URL: https://codereview.chromium.org/111083005 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@240807 0039d316-1c4b-4281-b951-d872f2087c98
* Mojo: More data pipe implementation.viettrungluu@chromium.org2013-12-1316-24/+455
| | | | | | | | | | | | | | | | | | | Implement the dispatcher for the producer side (DataPipeProducerDispatcher); the consumer side will be similar. Implement most of the base class for the connecting part (DataPipe). Subclasses will provide implementations for the various cases (both local, local producer/remote consumer, remote producer/local consumer). The setup is similar to that for MessagePipe, but factored a bit differently since the sides aren't symmetric (hence no gain in factoring out the endpoint code). R=sky@chromium.org Review URL: https://codereview.chromium.org/103533008 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@240774 0039d316-1c4b-4281-b951-d872f2087c98
* Add simple support for top-level enums to mojom.mpcomplete@google.com2013-12-1313-3/+137
| | | | | | | | | | | | | Still missing: - expressions as enum values (e.g. VALUE = OTHER_VALUE + 1) - enum names as types (right now I'm using uint32 for enums) BUG=320090 R=darin@chromium.org, davemoore@chromium.org Review URL: https://codereview.chromium.org/110583005 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@240738 0039d316-1c4b-4281-b951-d872f2087c98
* Mojo: data pipe boilerplate testing (and hooking up).viettrungluu@chromium.org2013-12-124-19/+171
| | | | | | | | | | | | I implemented the stupid boilerplate tests ... which then promptly failed, pointing out that I had forgotten to hook up my boilerplate. Oops. R=sky@chromium.org Review URL: https://codereview.chromium.org/99173008 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@240473 0039d316-1c4b-4281-b951-d872f2087c98
* Mojo: More stubs/boilerplate for data pipes.viettrungluu@chromium.org2013-12-123-21/+220
| | | | | | | | R=sky@chromium.org Review URL: https://codereview.chromium.org/103723004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@240446 0039d316-1c4b-4281-b951-d872f2087c98
* [gin] Turn gin into a componentjochen@chromium.org2013-12-121-0/+1
| | | | | | | | | | | | This will allow for using gin from content and blink at the same time in a component build BUG=321631 R=abarth@chromium.org,aa@chromium.org Review URL: https://codereview.chromium.org/101583004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@240425 0039d316-1c4b-4281-b951-d872f2087c98
* mojo: Cleanup: Forward declare Context in run.htfarina@chromium.org2013-12-123-4/+7
| | | | | | | | | | | | | | We are passing it as a pointer to Run(), so a forward declaration is enough. Then we add the necessary include to mojo_main.cc to keep things building. BUG=None TEST=None R=darin@chromium.org, abarth@chromium.org Review URL: https://codereview.chromium.org/112993003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@240411 0039d316-1c4b-4281-b951-d872f2087c98