101 Commits

Author SHA1 Message Date
Adam Barth
95b5d5dfa8 Update uses of Mojo to new interfaces 2016-03-02 14:14:55 -08:00
Chinmay Garde
8b89ad7dce Merge pull request #2435 from chinmaygarde/master
Allow specification of the FLX bundle (containing no Dart snapshot) outside the iOS/Mac application bundle.
2016-02-29 13:17:25 -08:00
Chinmay Garde
f9281a1edf Allow specification of the FLX bundle (containing no Dart snapshot) outside the iOS/Mac application bundle.
Allows launching of apps without having any Xcodebuild step in the simulator.
2016-02-29 13:16:01 -08:00
Matt Perry
34fb968705 Remove unused UpdateService. 2016-02-29 15:11:33 -05:00
Adam Barth
cf4c62ca1d Remove unneeded symbol from main_ios.mm
We don't appear to need this hack anymore.
2016-02-24 20:33:57 -08:00
Adam Barth
09e87f5865 Enable background compilation by default
We've been enabling it in the flutter tool for a while. This patch enables by
default in general.
2016-02-24 14:55:58 -08:00
Adam Barth
24eb9b3c19 Flutter.mojo should support multiple views
Each view gets its own Dart isolate. Unfortunately, the ShellPtr is a unique
resource, which means we need to proxy an implementation of Shell to each view.
In the future, we should probably switch dart to expect an ApplicationConnector
rather than a Shell.
2016-02-18 16:22:39 -08:00
Adam Barth
8111a77f73 Remove ServiceRegistry
We don't need this anymore now that we have Mozart.
2016-02-18 16:09:58 -08:00
Adam Barth
9e1e1fba54 Fix Android build 2016-02-13 00:09:32 -08:00
Adam Barth
b09cd543bd Add an off-by-default flag for background compilation 2016-02-12 16:01:18 -08:00
Jason Simmons
f4542c9152 Use Engine::RunFromBundle and the ZipAssetBundle on all platforms 2016-02-12 11:50:00 -08:00
Adam Barth
ab14d642fb Merge pull request #2386 from abarth/improve_mojo
Polish Mojo platform implementation
2016-02-11 14:31:00 -08:00
Adam Barth
d3dbc1cda4 Polish Mojo platform implementation
* Use Node::Combinator::PRUNE, which stops the Mozart launcher from showing red
  when we're loading child views. Instead of blocking the whole app, we'll now
  just prune away the children that aren't ready. Eventually we'll want
  to let authors control these operations.

* Grab the service registry in AcceptConnection rather than CreateView. The
  CreateView comes from the Mozart launcher, which isn't where we want to get
  the service registry. Now we get the service registry from the first app to
  connect, which isn't right either but at least works while we sort out what
  we really want.
2016-02-11 12:43:37 -08:00
Chinmay Garde
b8c6a97d81 Add error logging when a dynamic service fails to load
This happens once per service
2016-02-10 16:03:39 -08:00
Jason Simmons
ae517c2fee Add a way to override the snapshot when running an FLX bundle 2016-02-09 10:08:26 -08:00
Hixie
920e411493 Accessibility fixes
- Correctly enable accessibility on startup if it's already enabled.
- Avoid using deprecated APIs.
- Map FORWARD/BACKWARD scrolling actions to up/down even when left/right
  is also possible.
- Clear the accessibility focus when removing a focused semantics node.
- Unregister listeners when view goes away.
- Call setWillNotDraw(false) if accessibility is enabled.
- Clean the handling of hover events.
- Work around an Android bug where the system focus rect isn't drawn
  the first time.
2016-02-08 10:35:40 -08:00
Chinmay Garde
59781e9315 Merge pull request #2358 from chinmaygarde/master
Add a dynamic services target with a variant for the embedder and dylib each
2016-02-08 10:12:51 -08:00
Chinmay Garde
fcc9e95f3c Add a dynamic services target with a variant for the embedder and dylib each
* The embedder depends on dynamic:embedder
* The dylib depends on dynamic:dylib
* The embedder calls OnLoad and OnUnload callbacks that setup and teardown the dylib environment
* The dylib contains a thin library that services OnLoad, OnUnload and OnInvoke so that vendors dont have to do it themselves (and potentially mess it up)
* The vendor only has to implement the `FlutterServicePerform` method that takes a fully scoped handle
* This patch is a WIP till we get a stable Flutter ABI. The stuff in mojo/public is *NOT* stable
2016-02-08 10:11:09 -08:00
Hixie
d0e17e679a Track whether accessibility is enabled.
If we send accessibility events when accessibility is disabled, we crash.
2016-02-05 10:05:57 -08:00
Ian Hickson
380d5353cb Merge pull request #2353 from Hixie/actions
Make AccessibilityNodeInfos interactive.
2016-02-05 07:47:34 -08:00
Hixie
707ff9b4e2 Implement hover touch exploration mode on Android. 2016-02-04 16:56:07 -08:00
Chinmay Garde
800de4b122 Service vendors no longer specify the service entry point
Instead, the entry point is well known. The service name is passed as an argument to the service.
2016-02-04 16:55:17 -08:00
Hixie
0fa8524288 Android accessibility focus support
This lets you focus and unfocus a node.

Still doesn't seem to be enough to actually have the node exposed in
TalkBack. We probably need hover for that (that's next).

(Also fixes a leak for when a subtree has been disconnected; previously
we were only forgetting the top node of the subtree, not the
descendants. Thanks @krisgiesing for catching that.)
2016-02-04 15:53:17 -08:00
Hixie
17806fdb76 Tell Android when the accessibility tree changes
Hard to say if this actually works. We'll find out once we've filled
this out enough that you can walk the tree in Android's Talkback UI.
2016-02-04 14:53:22 -08:00
Hixie
cb789edc94 Make AccessibilityNodeInfos interactive.
This exposes the actions on AccessibilityNodeInfo nodes.
It also tries to make the code that handles reloads more correct.
2016-02-04 14:53:22 -08:00
Hixie
adbb587ab1 Flutter<->Android accessibility bridge
This is another step towards enabling accessibility for Flutter on
Android. It exposes the semantics tree to Android's accessibility API
when accessibility is enabled.

It does not yet:
 - allow one to actually interact with the application via the
   accessibility API
 - expose the accessibility tree to touch exploration
 - implement the accessibility focus API

However, you can see the tree if you run uiautomatorviewer. It is there,
and it matches the UI. At least in Stocks. I didn't test anything else.
2016-02-04 09:15:07 -08:00
Adam Barth
447f7fc14f Merge pull request #2348 from abarth/view_host
Pass the Mozart ViewHost into Dart
2016-02-04 08:59:33 -08:00
Jason Simmons
6c35840837 Merge pull request #2344 from jason-simmons/sound_file_cleanup
Change services to create temporary files that will be deleted by the…
2016-02-03 15:15:58 -08:00
Chinmay Garde
42019c43da Update service handler in dylib use the Mojo C API only 2016-02-03 15:00:17 -08:00
Adam Barth
aec7d422e7 Pass the Mozart ViewHost into Dart
Dart needs access to the ViewHost in order to create child views.
2016-02-03 14:39:45 -08:00
Chinmay Garde
c40b3d808d Install Mojo system thunks in dylib loaded for dynamic service resolution 2016-02-03 13:45:20 -08:00
Jason Simmons
1782b8f280 Change services to create temporary files that will be deleted by the ResourceCleaner
If the Sky shell process does not have an orderly shutdown, then temporary
files created by services may never be cleaned up.

The ResourceCleaner task will run at the next startup and clean up any files
that match the prefix used by Chromium's temporary file API.  Services will
now use the same prefix for their files.
2016-02-03 11:50:09 -08:00
Adam Barth
94dac511f6 Fix the mac build 2016-02-03 09:58:47 -08:00
Jason Simmons
2dd834fd45 Merge pull request #2339 from jason-simmons/platform_activity_services
Implementation of platform services for Android
2016-02-02 17:02:59 -08:00
Chinmay Garde
a7349a1142 Allow dynamic service resolution in the iOS shell 2016-02-02 16:55:35 -08:00
Jason Simmons
7730a0c123 Implementation of platform services for Android 2016-02-02 16:10:22 -08:00
Devon Carew
7204fc0663 Merge pull request #2335 from devoncarew/start_paused
some work towards a --start-paused flag
2016-02-02 12:20:43 -08:00
Devon Carew
3c83f895ed some work towards a --start-paused flag 2016-02-02 11:44:01 -08:00
Chinmay Garde
7fe880d89f iOS: Implement service providers for flutter.platform 2016-02-02 11:37:18 -08:00
Adam Barth
bdacb56cdd Improve IME interface
Instead of providing a stream of mutations, we now provide a the client with
the complete state of the editing control to prevent the two from getting out
of sync.

As a side-effect, we can now move the cursor around when editing a text field.
2016-02-01 20:41:48 -08:00
Chinmay Garde
7cc0e03ba5 Remove the mojo::Close call because the desctructor will automatically be called when the handle goes out of scope 2016-02-01 13:14:34 -08:00
Chinmay Garde
2854f56be1 Add an assertion in debug if the application requests an unknown service 2016-02-01 12:56:02 -08:00
Adam Barth
7bce54b79e Fix build 2016-01-30 13:42:35 -08:00
Adam Barth
0a7fae7c0a Merge pull request #2295 from abarth/ios_avoid_keyboard
Teach flutter how to avoid the iOS keyboard
2016-01-30 13:32:13 -08:00
Adam Barth
411c6bfa4b Port flutter.mojo to Mozart
Everything should work except the keyboard.
2016-01-28 16:04:19 -08:00
Adam Barth
707a18cde6 Teach flutter how to avoid the iOS keyboard
In the future, we'll probably want to plumb through the keyboard animation
parameters, but for now we match the behavior on Android where we move the
widgets out of the way of the keyboard without animation.
2016-01-28 15:29:24 -08:00
Jason Simmons
8d7a4bb3f8 Merge pull request #2313 from jason-simmons/view_reset_isolate
Create a new pipe to the ServiceProvider when PlatformViewAndroid sta…
2016-01-28 12:48:16 -08:00
Jason Simmons
35e3e94e25 Create a new pipe to the ServiceProvider when PlatformViewAndroid starts a Dart isolate
Previously PlatformViewAndroid would create a pipe and hand it off to the
SkyEngine, which would give it to the isolate's DartState.  If a second
isolate is created, the SkyEngine would no longer hold a valid proxy to a
ServicesProvider, and the new isolate's Dart code can not obtain the
servicesProvidedByEmbedder.
2016-01-28 11:13:46 -08:00
Chinmay Garde
611ea9cc31 iOS: Respect view controller visibility notifications and wire in Engine::OnAppLifecycleStateChanged 2016-01-28 11:00:29 -08:00
Chinmay Garde
0d446703bf iOS: Implementation of ::activity::Activity from activity.mojom 2016-01-27 15:01:53 -08:00