213 Commits

Author SHA1 Message Date
Chris Bracken
f0f09665d3 Clamp iOS selection to 0 < pos < length (flutter/engine#3636) 2017-04-27 16:04:30 -07:00
Mikkel Nygaard Ravn
a20aac4525 Fix corner case errors in platform channels (flutter/engine#3631) 2017-04-27 07:52:56 +02:00
P.Y. Laligand
47e891cc1d Don't build the full FlutterTester bundle on Fuchsia. (flutter/engine#3629)
The flutter_tester executable works just fine.
2017-04-26 10:37:28 -07:00
Chinmay Garde
b313dac389 Call SkGraphics::Init on shell initialization. (flutter/engine#3628)
This ensures SkOpts are initialized before we start using Skia.
2017-04-25 21:47:09 -07:00
P.Y. Laligand
8e74a31abd Allow Flutter shell to build for a Mac Fuchsia host. (flutter/engine#3625) 2017-04-25 07:38:08 -07:00
P.Y. Laligand
3e74263ff6 Fix -Wmissing-field-initializer warning on Fuchsia. (flutter/engine#3624) 2017-04-24 14:06:37 -07:00
Chinmay Garde
b1c35cc789 Remove fml::ThreadChecker and use the one in ftl. (flutter/engine#3623) 2017-04-24 12:22:10 -07:00
Mikkel Nygaard Ravn
9d88b0af24 Add hasArgument convenience to MethodCall (flutter/engine#3612) 2017-04-22 14:04:03 +02:00
xster
7900afc2fa Keep resident runner connected on iOS when screen locks in debug mode (flutter/engine#3610)
* Add debug mode background

* Review notes
2017-04-19 18:00:06 -07:00
Mikkel Nygaard Ravn
ffa3154595 Clarify semantics of channel-related errors (flutter/engine#3607)
Mainly improvements to javadoc and error logging. A bit of refactoring.
2017-04-19 21:53:46 +02:00
Chinmay Garde
18bfdff87e Fix Android Vulkan build. (flutter/engine#3606) 2017-04-18 16:26:37 -07:00
Mikkel Nygaard Ravn
4c457165be Make naming consistent across channel APIs (flutter/engine#3574) 2017-04-18 14:30:31 +02:00
Chinmay Garde
926c6c3794 Update Skia to 30229ac6282981c28ced8f513c8d09684d9d0581 and fix build. (flutter/engine#3602)
* Update Skia to 30229ac6282981c28ced8f513c8d09684d9d0581 and fix build.
* Update licenses.
2017-04-17 17:27:26 -07:00
Chinmay Garde
54d846b871 Only log about resource context setup failures on debug builds. (flutter/engine#3601)
We were unnecessarily alarming users when they used the software backend. Fixes https://github.com/flutter/flutter/issues/9394
2017-04-17 14:26:51 -07:00
Chinmay Garde
97af2def3e Add support for scaling the GPUSurfaceSoftware. (flutter/engine#3600) 2017-04-17 14:07:22 -07:00
Chinmay Garde
6ca8610bc4 Avoid creating a CGContextRef when generating a CGImageRef from a Skia pixmap. (flutter/engine#3599)
Also, adds trace events so profiling the software backend is easier.
2017-04-17 13:00:58 -07:00
Chris Bracken
cb02ed2518 Correct handling for composed character ranges at text.length (flutter/engine#3590)
Ensure that both self.text and self.selectedTextRange are updated before
triggering textDidChange: or selectionDidChange: on the input delegate
(which then re-computes positions). This prevents inconsistencies in
selection vs text position/offset lookups triggered by didChange
notifications.

Ensure that rangeOfComposedCharacterSequenceAtIndex: is only ever called
for index values > 0 && < self.text.length. This prevents such calls for
position with index == self.text.length.

Also reduces unnecessary textDidChange/selectionDidChange notifications:
replaceRange:withText: and setMarkedText:selectedRange: are only ever
called by UIKit and methods called by UIKit (insertText,
deleteBackward), so notification is unnecessary.
2017-04-13 11:48:59 -07:00
Chris Bracken
fc2bbd7124 Eliminate UITextInput.textContentType (flutter/engine#3587)
textContentType was added in iOS 10, and we target iOS 8. Either way the
framework doesn't (yet) include support for this; keyboard type covers
most bases.
2017-04-12 11:37:54 -07:00
Chris Bracken
e0d4f1305b Initial implementation of UITextInput protocol (flutter/engine#3586)
Supports:
* autocorrect, suggestions view/selection.
* Support for Chinese, Japanese, Korean and other languages using
  multi-stage input with candidate selection.
* styling the composing (mark) region for multi-stage input
* key-repeat when backspace held down
* physical and soft keyboard support for arrow key cursor movement and
  selection.
* improved third-party keyboard support

Does not yet support:
* force-touch drag cursor positioning
* auto-positioning the candidates view for multi-stage input methods
  when used with a physical keyboard (e.g., iPad Pro) currently
  positioned at 0,0.
* voice dictation
2017-04-12 11:04:26 -07:00
Chris Bracken
409824cedc Update Objective-C column limit to 100 (flutter/engine#3585)
The Google style guide specifies a limit of 100 columns.
https://google.github.io/styleguide/objcguide.xml?showone=Line_Length#Line_Length

The Chromium style guide specifies 80.
https://chromium.googlesource.com/chromium/src/+/master/styleguide/objective-c/objective-c.md
2017-04-11 15:14:00 -07:00
Ryan Macnak
32cd986649 AOT for Fuchsia. (flutter/engine#3570) 2017-04-11 14:53:14 -07:00
Ryan Macnak
ec2be075b2 Adjust GN for removal of libdart, take two. (flutter/engine#3584)
Update targets only included in host_debug_unopt.
2017-04-11 09:52:54 -07:00
Ryan Macnak
e869784502 Revert "Adjust GN for removal of libdart. (#3583)"
This reverts commit bb091fd4558c3807e86fe518d036504ebc37bb72.
2017-04-10 17:07:28 -07:00
Ryan Macnak
bb091fd455 Adjust GN for removal of libdart. (flutter/engine#3583) 2017-04-10 16:42:27 -07:00
Chinmay Garde
d73e56bff3 Package test fonts on the debug runtime mode. (flutter/engine#3582) 2017-04-10 15:41:09 -07:00
Mikkel Nygaard Ravn
f3459f540e Add convenience accessors to get arguments from MethodCall w/o unchecked warnings (flutter/engine#3559) 2017-04-09 17:36:05 +02:00
Mikkel Nygaard Ravn
eb4cc7f8e9 Update unit test to also handle null and zero-byte message differently (flutter/engine#3579) 2017-04-09 00:34:43 +02:00
Mikkel Nygaard Ravn
12745a7b02 Distinguish between null platform message and one with zero-byte payload (flutter/engine#3577) 2017-04-09 00:07:28 +02:00
Chris Bracken
250cd40ba9 Use Foundation MIN,MAX in place of C++ std::min,max (flutter/engine#3578)
Maintains consistency with other Objective-C code in the engine and
allows us to eliminate a #include.
2017-04-08 12:58:27 -07:00
Jason Simmons
b3ce239c83 Backport JSONObject.wrap in order to support Jellybean (flutter/engine#3566) 2017-04-06 10:15:06 -07:00
Jakob Andersen
b352804f69 Copy Flutter.podspec to engine out directory. (flutter/engine#3560)
So `flutter run --local-engine=...` will work out of the box.

Fixes flutter/flutter#9154.
2017-04-05 09:16:53 +02:00
Chris Bracken
71806383c1 Update selection base when deleting surrogates (flutter/engine#3558)
Ensure selection base is updated when deleting surrogates

This fixes a bug in which the selection base was not updated when
deleting at index of the trailing char of a Unicode surrogate,
introduced in d3149a5875404a4dacc7e4dde9c96045e2cbe6e5.

Minor refactor to consolidate logic around NSRange.
2017-04-03 23:12:02 -07:00
Chris Bracken
1d0e7a6a9a Handle Unicode surrogates in FlutterTextInputView (flutter/engine#3557)
* Handle Unicode surrogates in FlutterTextInputView

Fixes a bug introduced in d3149a5875404a4dacc7e4dde9c96045e2cbe6e5.
2017-04-03 21:49:30 -07:00
Chris Bracken
d3149a5875 Maintain FlutterTextInputView text in NSMutableString (flutter/engine#3554)
* Maintain FlutterTextInputView text in NSMutableString

We were converting from/to NSString at the interface of
FlutterTextInputView; instead use NSMutableString to maintain the
internal buffer.

Eliminates nsstring_utils.{h,mm} which no longer has any users.
2017-04-03 17:23:07 -07:00
Chinmay Garde
e0fed1432c Remove deprecated FlutterInit. (flutter/engine#3550) 2017-04-03 11:51:38 -07:00
Jason Simmons
fc666c4b62 Remove dart:jni (flutter/engine#3546)
Fixes https://github.com/flutter/flutter/issues/9129
2017-03-31 13:07:52 -07:00
Collin Jackson
732e118f07 Revert "Make FlutterActivity extend from FragmentActivity (#3529)" (flutter/engine#3545)
This reverts commit 41ced5aabc9dca1d27d9a1c9af2dd23f0a10916c.
2017-03-31 09:06:07 -07:00
Mikkel Nygaard Ravn
4a56788ec5 Ensure platform msg completer is invoked on ios even if no handler has been registered (flutter/engine#3544) 2017-03-30 12:49:09 +02:00
Chinmay Garde
000807898d Cleanup timeline markers. (flutter/engine#3540)
* Name the platform thread in the timeline. This does not affect (nor is it affected by) the pthread name set by the embedder.
* Make it easier in the timeline to see not only when the frame was request, but also when that frame request was fulfilled.
* Trace message loop wakes.
2017-03-29 13:04:25 -07:00
Mikkel Nygaard Ravn
4fcad872a8 Platform channel API cleanup (retake) (flutter/engine#3539) 2017-03-29 13:43:54 +02:00
Mikkel Nygaard Ravn
f57fbee942 Revert "Flutter channel API cleanup (#3532)" (flutter/engine#3538)
This reverts commit 00319038594b85b1b26a12d0769cea9b2d7ff05d.
2017-03-29 12:08:39 +02:00
Mikkel Nygaard Ravn
0031903859 Flutter channel API cleanup (flutter/engine#3532) 2017-03-29 11:38:14 +02:00
Jason Simmons
9961a50959 Copy platform message buffers into byte arrays passed via JNI (flutter/engine#3536)
The Java message object may be held by user-provided message handlers beyond
the lifetime of the raw blink::PlatformMessage and its data buffer
2017-03-28 17:15:01 -07:00
Jason Simmons
616d1c9b1e Release JNI references to ByteBuffers passed from native to Java (flutter/engine#3535) 2017-03-28 13:58:42 -07:00
Jason Simmons
945b6048da Package the stripped build of libflutter.so inside flutter.jar (flutter/engine#3531) 2017-03-27 17:52:12 -07:00
Collin Jackson
41ced5aabc Make FlutterActivity extend from FragmentActivity (flutter/engine#3529)
FragmentActivity is required for plugins that use auto managed Google APIs, such as Google Sign-In. Requires flutter/flutter#9036 to land so that gradle builds include FragmentActivity.
2017-03-27 16:53:09 -07:00
Chinmay Garde
becbe8fcc8 Remove dependency on FontConfig. (flutter/engine#3530) 2017-03-27 16:11:57 -07:00
Chinmay Garde
6b31213bc7 Rename sky_shell to flutter_tester. (flutter/engine#3521) 2017-03-27 13:09:36 -07:00
Jason Simmons
3cf3a20d3d Fix Javadoc on FlutterMethodChannel (flutter/engine#3522) 2017-03-24 18:23:51 -07:00
Chinmay Garde
7beff03713 Remove libsky_shell.so to libflutter.so. (flutter/engine#3517) 2017-03-24 16:25:33 -07:00