Commit graph

38 commits

Author SHA1 Message Date
xster 1ad4a088f1 Create template splash screens for Android and iOS (#11505)
* Add iOS template

* Android

* Let the engine reset the theme without the activity knowing

* Small tweak

* Replace assets with different vectors

* Let the template hookup have no actual image assets

* Add back placeholder assets with 1px transparent pngs

* Fix drawable xml

* clean up an extraneous line in the storyboard xml
2017-08-14 17:20:36 -07:00
Mikkel Nygaard Ravn 10f6483003 Add Swift and Kotlin templates (#10259) 2017-05-24 08:22:50 +02:00
Collin Jackson f5f0895990 Comment out use_frameworks by default so that codelab users don't have to. (#10205) 2017-05-19 10:45:35 -07:00
Mikkel Nygaard Ravn bae5a5cdf3 Simplify flutter create AppDelegate template (#10139) 2017-05-18 10:01:05 +02:00
Collin Jackson 00214fa7bd Fix call to unimplemented application:openURL:options: in iOS template (#10107)
Fixes #10106
2017-05-16 09:31:35 -07:00
Mikkel Nygaard Ravn c1feee93d3 iOS plugin registry (#9818) 2017-05-09 12:00:07 +02:00
xster 837f101056 Let (almost) all flutter create CocoaPods references be dynamically generated later (#9791)
* Remove all initial cocoapod traces from flutter create except Podfile

* Make updateXcodeGeneratedProperties parameters named

* review notes
2017-05-04 12:26:58 -07:00
Michael Thomsen c313984409 Exclude generated PluginRegistry files from git (#9555) 2017-04-24 15:23:18 +02:00
Michael Thomsen 7a57d37195 Add Pods cache dir to ios/.gitignore (#9464)
* Add Pods cache dir to ios/.gitngnore

* Add missing ending newlines
2017-04-21 13:18:05 +02:00
Jakob Andersen 7ffa82aaf0 Inject plugin registration. (#9216)
Added a PluginRegistry to the new project template. The registry files will be automatically updated at build time to register the native plugins.

Fixes #7814.
2017-04-10 15:44:19 +02:00
Collin Jackson 244a7a02b5 rename initWithFlutterView to initWithController (#9208) 2017-04-05 08:21:36 -07:00
Jakob Andersen f34f8a3197 Add template for plugin projects. (#9076)
Plugin projects are created by running `flutter create --plugin <name>`.

An example app is also created in the plugin project, using the normal 'create' template, which has been modified to allow for conditional plugin code.

Modified the android package name to match package naming conventions (all lower-case, and must match the directory name).
2017-03-30 12:39:21 +02:00
Jakob Andersen b61e169011 Automatically wire dependencies for native plugins (#8891)
Go through all packages brought in by pub, and write the name and path of every one that is a flutter plugin into .flutter-plugins.

In android/settings.gradle and ios/Podfile, read in .flutter-plugins, if that file exists. The Android / iOS code from the plugins is automatically added as dependencies of the native code of the app.
2017-03-23 14:59:12 +01:00
Chris Bracken 0ee3f57a10 Build Flutter app as a framework on iOS (#8971)
**THIS IS A BREAKING CHANGE.** See below for migration steps for
existing projects.

Previously, Flutter app code was built as a raw dylib on iOS.  Dynamic
libraries outside of a framework bundle are not supported on iOS, except
for the system Swift libraries provided by Xcode.

See:
https://developer.apple.com/library/content/technotes/tn2435/_index.html#//apple_ref/doc/uid/DTS40017543-CH1-TROUBLESHOOTING_BUNDLE_ERRORS-EMBEDDED__DYLIB_FILES

* Migrates Xcode build from app.dylib to App.framework
* Migrates flutter create template
* Migrates example projects

Migration steps for existing projects
=====================================

The following steps should be taken from the root of your Flutter
project:

1. Edit `ios/.gitignore`: add `/Flutter/App.framework` on a new line.
2. In the Xcode project navigator, remove `app.dylib` from the Flutter
   folder. Delete this file from the `ios/Flutter` directory in your project.
3. Run a build to generate `ios/Flutter/App.framework`. From the command
   line, run `flutter build ios`. If you have not configured app signing
   in Xcode, an alternative method is to open the simulator, then run
   `flutter run -d iP`.
4. In the Xcode project navigator, select the `Runner` project. In the
   project settings that are displayed in the main view, ensure that the
   `Runner` target is selected. You can verify this by exposing the
   sidebar using the [| ] icon in the upper-left corner of the main
   view.
5. Select the *General* tab in the project settings. Under the
   *Embedded Binaries* section, click '+' to add `App.framework`. In the
   sheet that drops down, click the *Add Other...* button. Navigate to
   the `ios/Flutter` directory and select `App.framework`. Click *Open*.
   In the sheet that drops down, select *Create folder references*, then
   click *Finish*.
6. In the project settings, verify that `App.framework` has been added to the
   *Embedded Binaries* and *Linked Frameworks and Libraries* lists.
7. In the Xcode project navigator, drag `App.framework` under the
   Flutter folder.
8. In the Xcode project navigator, select `Flutter` then from the
   *File* menu, select *Add Files to "Runner"...*. Navigate to the
   `ios/Flutter` directory, select `AppFrameworkInfo.plist` and click
   the *Add* button.
9. From the command line, in your project directory, run
   `flutter build clean`, then `flutter run`.

At this point your project should be fully migrated.
2017-03-22 17:41:49 -07:00
Chris Bracken a4125f3b0e Declare Xcode 8.3.x compatibility in project files (#8622)
Update templates and example Xcode project files to indicate they've
been tested for Xcode 8.3 compatibility.
2017-03-07 13:11:41 -08:00
Chris Bracken bd3aac7043 Use default iOS SDK for CocoaPods project (#8603)
This matches the default for Runner.xcodeproj and fixes a linker warning
when the two projects use different values.
2017-03-06 17:31:51 -08:00
Chris Bracken 752ca59dff Update iOS template icon assets (#8601)
Add 20x20 notification icons.
Remove unused 76x76 (3x scale) icon.
Fixes warnings for missing/unused icon assets in Xcode 8.2.x
2017-03-06 17:05:27 -08:00
Chris Bracken d32dc9254b Update Xcode projects to 8.2.x (#8596)
This prevents project re-validation on initial Xcode launch.
2017-03-06 14:50:41 -08:00
Chris Bracken 5e672cbe64 Update Xcode project templates to handle paths with spaces (#8034) 2017-02-09 13:25:29 -08:00
Chris Bracken 1926d11188 Thin iOS app frameworks to the target architecture (#7913)
* Support thinning iOS frameworks to supported architectures

When building against frameworks that are distributed as
multi-architecture fat binaries, we want to strip the frameworks we
distribute down to only the architectures specified in $ARCHS.

This patch adds:
* The ability to specify commands to xcode_backend.sh (if none is
  specified, run BuildApp for backward compatibility).
* A 'thin' command that invokes lipo to thin down the distributed as
  described above.

* Add framework thinning step to iOS build

Invokes xcode_backend.sh thin on the build application.

* Limit architectures to arm64 in Xcode template

Flutter does not yet support armv7 iOS devices. Limit the $ARCHS build
variable to arm64 until then.
2017-02-07 12:04:36 -08:00
Chris Bracken aaff608d05 Use FlutterAppDelegate in iOS create template (#7845)
On iOS, generate a FlutterAppDelegate subclass for the application
delegate. This avoids touchesBegan:withEvent boilerplate to handle
status bar taps.
2017-02-02 18:03:56 -08:00
Chris Bracken 2bbc028313 Add touchesBegan handler to iOS AppDelegate template (#7822)
By default, pass status bar taps to the root view controller in
generated Flutter apps. Developers should customise as necesary if they
later create one or more alternate FlutterViewControllers that they'd
like to forward these to.
2017-02-02 12:50:01 -08:00
Chris Bracken d01c55d289 Eliminate calls to deprecated FlutterInit() (#7770) 2017-01-31 17:39:29 -08:00
Collin Jackson 9f3c3fd2dc Fix #7029 nested .gitignore breaks ios projects (#7045) 2016-11-28 10:02:00 -08:00
Chris Bracken c2386fb725 Update iOS template to Xcode 8 recommended settings 2016-09-26 15:04:07 -07:00
Seth Ladd f28cf64127 ios launcher icons with more padding, optimized (#5470) 2016-08-18 10:16:10 -07:00
Collin Jackson 5f67aeb05c Fix #5398 flutter run hangs on project made with flutter create (#5432) 2016-08-16 14:00:00 -07:00
Collin Jackson facd3e238f Fix #5384 by checking in iOS pod manifest (#5388) 2016-08-15 09:35:38 -07:00
Devon Carew e3f6d1539c update the icons for the create template (#5286) 2016-08-08 11:14:40 -07:00
Chinmay Garde 21ee4b92f1 Specify the IPHONEOS_DEPLOYMENT_TARGET to 8.0. (#5268)
* Update examples to lower the deployment target on iOS.
2016-08-05 14:56:07 -07:00
Eric Seidel 5a0589c781 Remove stray PRODUCT_BUNDLE_IDENTIFIER (#5242)
* Remove stray PRODUCT_BUNDLE_IDENTIFIER

This was erroneously added and overrides
the bundle for the gallery causing signing
to fail in my setup.

@chinmaygarde

* Remove PRODUCT_BUNDLE_IDENTIFIER from all Runner pbxproj's
2016-08-05 10:00:50 -07:00
Collin Jackson d2b3976110 Alter iOS template project to be CocoaPods enabled (#4893) 2016-08-05 09:17:13 -07:00
Adam Barth 46ccd879c2 Actually build the AppDelegate (#4925)
Previously it wasn't included in the Runner target.
2016-07-14 17:37:57 -07:00
Collin Jackson f82b62096d Simplify iOS template project 2016-07-12 18:34:01 -07:00
Collin Jackson 0d1752241f Remove dependency on FlutterAppDelegate so devs can more easily add SDKs. 2016-07-12 13:56:07 -07:00
Adam Barth a33fc49659 Remove dangling reference to ViewController (#4841)
We want to use the FlutterViewController in this new project template.

Fixes #4840
2016-07-07 10:45:58 -07:00
Adam Barth 151750baa8 Update the ios projects for examples to HelloServices model (#4822)
We now use a different approach for ios projects where the developer controls
the Xcode project file. This patch removes the old ".generated" approach in
favor of the new approach.
2016-07-06 14:13:21 -07:00
Adam Barth 8d56fae557 Finish integrating HelloServices model on iOS (#4820)
This patch changes the default `flutter create` command to generate a
HelloServices-style app on iOS. As a consequence, the Atom integration now
fully works with HelloServices.
2016-07-06 13:13:28 -07:00