summaryrefslogtreecommitdiffstats
path: root/mojo
Commit message (Collapse)AuthorAgeFilesLines
* Build view manager lib & tests as part of mojo target.ben@chromium.org2014-05-071-0/+2
| | | | | | | | | TBR=sky@chromium.org BUG= Review URL: https://codereview.chromium.org/269183007 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@268837 0039d316-1c4b-4281-b951-d872f2087c98
* fixed memory leak from mojo_public_bindings_unittests FixedBufferTest.Leakzhaoqin@google.com2014-05-071-1/+1
| | | | | | | | | | | | - remove the buf_ptr declaration in the block BUG=370569 R=darin@chromium.org, viettrungluu@chromium.org TEST=manual Review URL: https://codereview.chromium.org/266043006 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@268776 0039d316-1c4b-4281-b951-d872f2087c98
* Mojo: Make embedder::PlatformChannelRecvmsg() able to append handles to an ↵viettrungluu@chromium.org2014-05-073-9/+60
| | | | | | | | | | | | existing vector. (It'll still allocate a vector if necessary.) R=yzshen@chromium.org Review URL: https://codereview.chromium.org/264823005 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@268768 0039d316-1c4b-4281-b951-d872f2087c98
* Add handles to data structure passed between c++ and JS unittest.tsepez@chromium.org2014-05-072-8/+44
| | | | | | | | | | Also tidy up some JS coding style while we're at it. R=viettrungluu@chromium.org Review URL: https://codereview.chromium.org/268143008 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@268697 0039d316-1c4b-4281-b951-d872f2087c98
* Makes thread created by test helper follow general thread namingsky@chromium.org2014-05-061-1/+1
| | | | | | | | | | | | | | It appears threads are typically named in unix_hacker_style. Renames to match that. BUG=none TEST=none R=davemoore@chromium.org TBR=davemoore@chromium.org Review URL: https://codereview.chromium.org/261753021 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@268631 0039d316-1c4b-4281-b951-d872f2087c98
* Shuffles around some filessky@chromium.org2014-05-0618-230/+222
| | | | | | | | | | | | | I'm moving these files into a more common location so that they can be used by the view manager. BUG=365012 TEST=none R=ben@chromium.org Review URL: https://codereview.chromium.org/262093008 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@268627 0039d316-1c4b-4281-b951-d872f2087c98
* Block ViewManager construction on connection establishment.ben@chromium.org2014-05-065-31/+42
| | | | | | | | | | | | | | | | | This allows us to assume globally unique ids are available locally as soon as ViewManager's ctor completes. This greatly simplifies use of the view manager client lib. Future improvements include: - targeted blocking based on reading the connection established message rather than running a nested run loop - the ability to provide a callback so the user can decide not to block and just not touch the node tree until the callback executes. R=sky@chromium.org http://crbug.com/365012 Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=268556 Review URL: https://codereview.chromium.org/267013003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@268585 0039d316-1c4b-4281-b951-d872f2087c98
* Make sure that ScratchBuffer::Allocate() always return 8-byte aligned addresses.yzshen@chromium.org2014-05-064-6/+38
| | | | | | | | | | | BUG=None TEST=None Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=268405 Review URL: https://codereview.chromium.org/265403003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@268567 0039d316-1c4b-4281-b951-d872f2087c98
* Revert 268556 "Block ViewManager construction on connection esta..."dalecurtis@google.com2014-05-065-43/+30
| | | | | | | | | | | | | | | | | | | | | | | | Broke compile: http://build.chromium.org/p/chromium.linux/builders/Linux%20Clang%20%28dbg%29/builds/59139 > Block ViewManager construction on connection establishment. > > This allows us to assume globally unique ids are available locally as soon as ViewManager's ctor completes. This greatly simplifies use of the view manager client lib. > > Future improvements include: > - targeted blocking based on reading the connection established message rather than running a nested run loop > - the ability to provide a callback so the user can decide not to block and just not touch the node tree until the callback executes. > > R=sky@chromium.org > http://crbug.com/365012 > > Review URL: https://codereview.chromium.org/267013003 TBR=ben@chromium.org Review URL: https://codereview.chromium.org/265413004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@268561 0039d316-1c4b-4281-b951-d872f2087c98
* Block ViewManager construction on connection establishment.ben@chromium.org2014-05-065-30/+43
| | | | | | | | | | | | | | | This allows us to assume globally unique ids are available locally as soon as ViewManager's ctor completes. This greatly simplifies use of the view manager client lib. Future improvements include: - targeted blocking based on reading the connection established message rather than running a nested run loop - the ability to provide a callback so the user can decide not to block and just not touch the node tree until the callback executes. R=sky@chromium.org http://crbug.com/365012 Review URL: https://codereview.chromium.org/267013003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@268556 0039d316-1c4b-4281-b951-d872f2087c98
* Rearrange GLImage API to create them with a usage typealexst@chromium.org2014-05-062-0/+2
| | | | | | | | | | instead of using usage type while mapping the buffer. BUG= Review URL: https://codereview.chromium.org/255713008 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@268548 0039d316-1c4b-4281-b951-d872f2087c98
* Adds ability to load services on background threadsky@chromium.org2014-05-066-3/+170
| | | | | | | | | | | | | | | | | | And enables this for the native viewport. Currently the native viewport implementation can end up synchronously waiting for messages. This means if the viewmanager (which uses the native viewport) and native viewport end up on the same thread they can easily deadlock. For now I'm moving native viewport to its own thread. Long term native viewport should live in its own process (according to piman). BUG=365012 TEST=none R=davemoore@chromium.org Review URL: https://codereview.chromium.org/263163005 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@268471 0039d316-1c4b-4281-b951-d872f2087c98
* Rename some PPB_VideoDecoder_Dev implementation types.bbudge@chromium.org2014-05-062-2/+2
| | | | | | | | | | | Adds a "_Dev" suffix to some types that would collide with upcoming public VideoDecoder API. BUG=281689 Review URL: https://codereview.chromium.org/263893005 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@268450 0039d316-1c4b-4281-b951-d872f2087c98
* Use ignore_result instead of MOJO_ALLOW_UNUSED.mpcomplete@chromium.org2014-05-061-1/+1
| | | | | | Review URL: https://codereview.chromium.org/264163003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@268436 0039d316-1c4b-4281-b951-d872f2087c98
* Revert 268405 "Make sure that ScratchBuffer::Allocate() always r..."yzshen@chromium.org2014-05-062-21/+3
| | | | | | | | | | | | | | | > Make sure that ScratchBuffer::Allocate() always return 8-byte aligned addresses. > > BUG=None > TEST=None > > Review URL: https://codereview.chromium.org/265403003 TBR=yzshen@chromium.org Review URL: https://codereview.chromium.org/265823012 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@268434 0039d316-1c4b-4281-b951-d872f2087c98
* Mojo: Add POSIX utils for sending FDs (across a "platform channel pair").viettrungluu@chromium.org2014-05-063-3/+218
| | | | | | | | R=yzshen@chromium.org Review URL: https://codereview.chromium.org/264973018 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@268422 0039d316-1c4b-4281-b951-d872f2087c98
* Make sure that ScratchBuffer::Allocate() always return 8-byte aligned addresses.yzshen@chromium.org2014-05-062-3/+21
| | | | | | | | | BUG=None TEST=None Review URL: https://codereview.chromium.org/265403003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@268405 0039d316-1c4b-4281-b951-d872f2087c98
* The set_enforce_errors_from_incoming_receiver() method is needed for testingtsepez@chromium.org2014-05-065-7/+28
| | | | | | | | | | | | only. It allows fuzzing tests to continue to execute after the first error is encountered on a connector. R=darin@chromium.org BUG=366797 Review URL: https://codereview.chromium.org/270023003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@268402 0039d316-1c4b-4281-b951-d872f2087c98
* Add destruction logic to CommandBufferImplsky@chromium.org2014-05-061-1/+7
| | | | | | | | | | | | | Without this I get DCHECKs when trying to shutdown CommandBufferImpl in unit tests. BUG=none TEST=none R=piman@chromium.org Review URL: https://codereview.chromium.org/268133002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@268346 0039d316-1c4b-4281-b951-d872f2087c98
* Mojo: Initialize MessageInTransit::Header::unused.viettrungluu@chromium.org2014-05-052-0/+3
| | | | | | | | | | | | (This avoids an uninitialized read (e.g., in sending the message), which potentially leaks data.) R=yzshen@chromium.org BUG=370145 Review URL: https://codereview.chromium.org/264093006 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@268326 0039d316-1c4b-4281-b951-d872f2087c98
* [PPAPI] Add media stream video track output APIronghuawu@chromium.org2014-05-052-0/+8
| | | | | | | | | | Implemented the pepper host for the output mode. R=bbudge@chromium.org, dmichael@chromium.org, jschuh@chromium.org, yzshen@chromium.org Review URL: https://codereview.chromium.org/145263008 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@268318 0039d316-1c4b-4281-b951-d872f2087c98
* Remove command_buffer/common/types.h.thakis@chromium.org2014-05-051-32/+39
| | | | | | | | | | | | Make its current clients use base/macros.h and stdint.h instead. No behavior change. BUG=138542 NOTRY=true Review URL: https://codereview.chromium.org/268063002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@268315 0039d316-1c4b-4281-b951-d872f2087c98
* This gets mojo_launcher.so a little further along toward running.aa@chromium.org2014-05-054-3/+10
| | | | | | | | | | It still doesn't run though. R=ben@chromium.org Review URL: https://codereview.chromium.org/265053005 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@268261 0039d316-1c4b-4281-b951-d872f2087c98
* Add support for mapping node tree on the client.ben@chromium.org2014-05-0514-70/+398
| | | | | | | | | | | R=sky@chromium.org http://crbug.com/365012 Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=268218 Review URL: https://codereview.chromium.org/260863008 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@268252 0039d316-1c4b-4281-b951-d872f2087c98
* Revert 268218 "Add support for mapping node tree on the client."ben@chromium.org2014-05-0513-367/+70
| | | | | | | | | | | | | | | > Add support for mapping node tree on the client. > > R=sky@chromium.org > http://crbug.com/365012 > > Review URL: https://codereview.chromium.org/260863008 TBR=ben@chromium.org Review URL: https://codereview.chromium.org/269973002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@268225 0039d316-1c4b-4281-b951-d872f2087c98
* Add support for mapping node tree on the client.ben@chromium.org2014-05-0513-70/+367
| | | | | | | | | R=sky@chromium.org http://crbug.com/365012 Review URL: https://codereview.chromium.org/260863008 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@268218 0039d316-1c4b-4281-b951-d872f2087c98
* Mojo: Add/use |typedef std::vector<scoped_refptr<Dispatcher> > DispatcherVector.viettrungluu@chromium.org2014-05-0519-95/+82
| | | | | | | | R=darin@chromium.org Review URL: https://codereview.chromium.org/262093003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@268204 0039d316-1c4b-4281-b951-d872f2087c98
* Adding attributes to module and struct in mojom.qsr@chromium.org2014-05-0510-8/+24
| | | | | | | | | | Struct already had attributes, but were discarding the result. Module attributes will be used by the java generator to set the java package. R=darin@chromium.org Review URL: https://codereview.chromium.org/262633005 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@268177 0039d316-1c4b-4281-b951-d872f2087c98
* Mojo: Use ./<(RULE_INPUT_DIRNAME) in mojom_bindings_generator.gypi.sammc@chromium.org2014-05-051-1/+1
| | | | | | | | | RULE_INPUT_DIRNAME is empty for input files in the same directory as the gyp file. Review URL: https://codereview.chromium.org/267743008 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@268149 0039d316-1c4b-4281-b951-d872f2087c98
* Makes PlatformEventSource creation in Env conditionalsky@chromium.org2014-05-052-2/+2
| | | | | | | | | | | | | | | | | | | | Currently mojo runs all services in the same process. We have separate services that manage the display and one that runs aura. The display one needs to create PlatformEventSource (as it gets events). The service running aura doesn't need a PlatformEventSource as it gets events from the display one. This means I need the ability to create aura::Env without a PlatformEventSource. I believe the long term plan is to move some services out of process. When this happens this boolean shouldn't be needed. BUG=365012 TEST=none R=sadrul@chromium.org Review URL: https://codereview.chromium.org/262883011 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@268148 0039d316-1c4b-4281-b951-d872f2087c98
* Fix leak in RemotePtr::operator=().yzshen@chromium.org2014-05-051-0/+1
| | | | | | | | | BUG=None TEST=None Review URL: https://codereview.chromium.org/269893003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@268134 0039d316-1c4b-4281-b951-d872f2087c98
* mojo: Use static_assert for MOJO_COMPILE_ASSERT in C++11 mode, like in base/.thakis@chromium.org2014-05-041-1/+3
| | | | | | | | | BUG=321833 NOTRY=true Review URL: https://codereview.chromium.org/267963003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@268098 0039d316-1c4b-4281-b951-d872f2087c98
* Mojo: Factor MessageInTransit secondary buffer stuff out into a separate class.viettrungluu@chromium.org2014-05-0311-361/+502
| | | | | | | | | | Also write a big comment explaining what I'm going to do. R=darin@chromium.org Review URL: https://codereview.chromium.org/265753006 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@268032 0039d316-1c4b-4281-b951-d872f2087c98
* Mojo: Force folks to handle the return value of ↵darin@chromium.org2014-05-032-5/+10
| | | | | | | | MessageReceiver::Accept{WithResponder} Review URL: https://codereview.chromium.org/267803008 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@268013 0039d316-1c4b-4281-b951-d872f2087c98
* Mojo: Fix Router::HandleIncomingMessage().viettrungluu@chromium.org2014-05-021-1/+2
| | | | | | | | R=darin@chromium.org Review URL: https://codereview.chromium.org/265133002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@267944 0039d316-1c4b-4281-b951-d872f2087c98
* Test sending corrupt mojo messages back from javascript.tsepez@chromium.org2014-05-023-56/+153
| | | | | | | | | | | | | | | | | | | | | | This CL adds hooks to allow an outgoing message to be re-written just before it is handed off to C++ for transmission. I then build a simple bit-flipping test based upon this to see how the C++ side stands up to this (under ASAN). Another small change is to pass the number of iterations from the C++ side so that there no longer is a need to keep two constants in sync with each other. Another small change is to pull some of repeated code dealing with isolated testing into its own function to avoid duplication. The test is currently disabled pending the associated bug. This does not fix the bug but introduces a realiable repro for it. BUG=366797 Review URL: https://codereview.chromium.org/250713003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@267925 0039d316-1c4b-4281-b951-d872f2087c98
* Mojo: Add simple test utils to run the mojom parser and translater.viettrungluu@chromium.org2014-05-024-71/+106
| | | | | | | | | | | (I previously broke the ability to run parser.py directly, due to the relative imports.) R=yzshen@chromium.org Review URL: https://codereview.chromium.org/265893004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@267853 0039d316-1c4b-4281-b951-d872f2087c98
* Fix dependency issue in mojo_view_manager_unittestsben@chromium.org2014-05-021-0/+1
| | | | | | | | | TBR=sky@chromium.org http://crbug.com/369374 Review URL: https://codereview.chromium.org/269543011 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@267817 0039d316-1c4b-4281-b951-d872f2087c98
* Adds typedefs for view manager typessky@chromium.org2014-05-028-112/+166
| | | | | | | | | | BUG=365012 TEST=covered by tests R=ben@chromium.org Review URL: https://codereview.chromium.org/257383007 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@267809 0039d316-1c4b-4281-b951-d872f2087c98
* gpu: Separate GpuControlService from GpuControlboliu@chromium.org2014-05-022-6/+2
| | | | | | | | | | | | | | | | | | | | | | | | | Orignal goal of this CL is to make InProcessCommandBuffer::CreateGpuMemoryBuffer and DestroyGpuMemoryBuffer thread safe. Before this, Create runs on the client thread and Destroy runs on the service thread without any kind of synchronization. This change makes the division closer to the cross-process implementation, moving parts of the implementation from GpuControlService to GpuControl/InProcessViewRenderer. As a result, GpuControlService no longer needs to inherit GpuControl. And GLES2Decoder has enough information to decide on all gpu::Capabilities. Need to implement the bare minimum client GpuControl for gl_tests and gles2_conform_test. This currently involves some boilerplate and duplication. BUG=362346 Review URL: https://codereview.chromium.org/235563002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@267753 0039d316-1c4b-4281-b951-d872f2087c98
* Move existing Mojo JS <--> CPP tests out of webui test harness.tsepez@chromium.org2014-05-024-75/+272
| | | | | | | | | | | | | | | | | The mojo webui test in content_browsertests was not the proper place to perform bindings-related fuzzing (though it was initially convenient). As a first step, move the existing tests to the new "framework" sky added in https://src.chromium.org/viewvc/chrome?revision=267208&view=revision This also restores the webui code to something near its original purpose, although I've kept a few of the hooks that may be useful as real webui tests are added. R=sky@chromium.org Review URL: https://codereview.chromium.org/268593002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@267703 0039d316-1c4b-4281-b951-d872f2087c98
* Generalize DBus-Mojo bootstrapping codecmasone@chromium.org2014-05-018-115/+216
| | | | | | | | | | | | | | Most of the code to bootstrap a Mojo service over DBus is moved into a templated class under mojo/dbus. Simply implement your Mojo service and then specialize DBusExternalService with your service implementation. TBR=darin@chromium.org BUG=chromium:367816 TEST=run mojo_dbus_echo_service in one shell, and then ./out/Debug/mojo_shell --origin=http://127.0.0.1:4444 --disable-cache mojo:mojo_dbus_echo in the other. Review URL: https://codereview.chromium.org/245253004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@267662 0039d316-1c4b-4281-b951-d872f2087c98
* Validate MessageHeader before usingdarin@chromium.org2014-05-0119-6/+395
| | | | | | | | | | On validation error, mimic a MessageReceiver returning false. Make that trigger the error state of Connector. BUG=357885 Review URL: https://codereview.chromium.org/229683005 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@267588 0039d316-1c4b-4281-b951-d872f2087c98
* Fixs style nits in mojo_runner_delegatesky@chromium.org2014-05-011-3/+3
| | | | | | | | | | | BUG=none TEST=none R=tsepez@chromium.org TBR=tsepez@chromium.org Review URL: https://codereview.chromium.org/263723002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@267577 0039d316-1c4b-4281-b951-d872f2087c98
* Mojo: Small fixes/cleanup to MessageInTransit, before I factor out the ↵viettrungluu@chromium.org2014-05-012-46/+48
| | | | | | | | | | | | | | | | | | | secondary buffer. I'm making these changes as I write the factored-out secondary buffer in parallel, but it's probably to review these changes now rather than as a part of the move/refactor. Notable changes: * Use the actual size for the secondary buffer, rather than the estimated size. (Probably this makes no difference now.) * Discard the dispatchers earlier (in SerializeAndCloseDispatchers()). R=darin@chromium.org Review URL: https://codereview.chromium.org/260823002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@267542 0039d316-1c4b-4281-b951-d872f2087c98
* Mojo: Embedder API: Properly handle Channel creation/startup failures.viettrungluu@chromium.org2014-05-011-24/+62
| | | | | | | | | | | [I'll try reenabling UserAddingScreenTest.AddingSeveralUsers separately.] R=darin@chromium.org BUG=368621 Review URL: https://codereview.chromium.org/267613002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@267536 0039d316-1c4b-4281-b951-d872f2087c98
* Adding an invalid handle in the public API.qsr@chromium.org2014-05-015-47/+270
| | | | | | | | | | | | Also cleanup of the implementation by removing the unused CoreSingleton class. R=bulach@chromium.org,viettrungluu@chromium.org BUG= Review URL: https://codereview.chromium.org/260623006 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@267516 0039d316-1c4b-4281-b951-d872f2087c98
* mojo::TypeConverter: support inherting implicit conversion settings from ↵yzshen@chromium.org2014-05-014-50/+28
| | | | | | | | | | | | | another TypeConverter. This CL also makes TypeConverter<Array<X>, std::vector<Y> > inherit settings from TypeConverter<X, Y>. BUG=None TEST=None Review URL: https://codereview.chromium.org/264823002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@267510 0039d316-1c4b-4281-b951-d872f2087c98
* Add module reference in struct, interface and enums.qsr@chromium.org2014-05-014-28/+32
| | | | | | | | | | | | In java, to get the fully qualified name of an object, we will need to have access to the module that declare this object. This CL ensure that object keeps a reference to their module. R=viettrungluu@chromium.org Review URL: https://codereview.chromium.org/253273003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@267485 0039d316-1c4b-4281-b951-d872f2087c98
* First step at synchronizing client model changes with service.ben@chromium.org2014-05-0115-78/+522
| | | | | | | | | | | | | | | R=sky@chromium.org http://crbug.com/365012 Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=266940 Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=267293 Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=267311 Review URL: https://codereview.chromium.org/258623005 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@267424 0039d316-1c4b-4281-b951-d872f2087c98