Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: flutter/flutter
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: 95be76ab7e3d
Choose a base ref
...
head repository: flutter/flutter
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: b0188cd18274
Choose a head ref
  • 10 commits
  • 53 files changed
  • 8 contributors

Commits on Jun 14, 2023

  1. Unpin flutter_plugin_android_lifecycle (#128898)

    Unpins flutter_plugin_android_lifecycle where it is pinned. I then 
    1. ran `flutter update-packages --force-upgrade` (but only committed the changes within `dev/integration_tests/gradle_deprecated_settings/`, which is where it had been pinned) 
    2. followed by `./gradlew :generateLockfiles` from `dev/integration_tests/gradle_deprecated_settings/android/` (the lockfile was what was causing the CI dependency resolution failure, so this second step is the fix for that).
    
    See the reason it was pinned: #121847 (comment) followed by the PR that pinned it: #122043
    
    Fixes #122039
    gmackall authored Jun 14, 2023
    Configuration menu
    Copy the full SHA
    944d6c8 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    d520b64 View commit details
    Browse the repository at this point in the history
  3. Remove temporary default case for PointerSignalKind (#128900)

    This PR cleans up some prep that was added as part of
    #120731 which was done to unblock
    flutter/engine#39637
    Since the work done in that PR was reverted, this should be removed.
    
    ## Pre-launch Checklist
    
    - [x] I read the [Contributor Guide] and followed the process outlined
    there for submitting PRs.
    - [x] I read the [Tree Hygiene] wiki page, which explains my
    responsibilities.
    - [x] I read and followed the [Flutter Style Guide], including [Features
    we expect every widget to implement].
    - [x] I signed the [CLA].
    - [x] I listed at least one issue that this PR fixes in the description
    above.
    - [x] I updated/added relevant documentation (doc comments with `///`).
    - [ ] I added new tests to check the change I am making, or this PR is
    [test-exempt].
    - [x] All existing and new tests are passing.
    LouiseHsu authored Jun 14, 2023
    Configuration menu
    Copy the full SHA
    4effd9c View commit details
    Browse the repository at this point in the history
  4. ContextAction.isEnabled needs a context (#127721)

    ...and lots of things that fall out from that
    Hixie authored Jun 14, 2023
    Configuration menu
    Copy the full SHA
    34f39a2 View commit details
    Browse the repository at this point in the history
  5. Improve the error message for non-normalized constraints (#127906)

    We probably added RenderBox.layout after this error was created and of course we weren't writing tests back then...
    Hixie authored Jun 14, 2023
    Configuration menu
    Copy the full SHA
    d64332a View commit details
    Browse the repository at this point in the history
  6. Configuration menu
    Copy the full SHA
    ed3d463 View commit details
    Browse the repository at this point in the history
  7. Configuration menu
    Copy the full SHA
    7d95086 View commit details
    Browse the repository at this point in the history
  8. Fix inconsistently suffixed macOS flavored bundle directory (#127997)

    The current implementation of macOS flavor support (#119564) assumes a bundle directory that differs from both the iOS implementation and the official documentation. The [documentation](https://docs.flutter.dev/deployment/flavors) instructs developers to suffix their Xcode build configurations with `-<flavor>`, but the implementation assumes a space:
    
    https://github.com/flutter/flutter/blob/5fd9ef4240d3fc239f042f49b8eb1ad24260091f/packages/flutter_tools/lib/src/macos/application_package.dart#L174-L178
    
    Whereas the iOS implementation, which is the reference for the docs, assumes a `-<flavor>` suffix:
    
    https://github.com/flutter/flutter/blob/a257efc2841ed7042322fbd043f0983e705d7da2/packages/flutter_tools/lib/src/ios/xcodeproj.dart#L482-L488
    
    This change replaces the empty space with the `-` character which is in line with the documentation and iOS implementation, as well as removing the sentence-casing applied to the flavor name; every bundle built with a flavor keeps the original flavor name in its filename.
    
    *List which issues are fixed by this PR. You must list at least one issue.*
    #122684.
    
    *If you had to change anything in the [flutter/tests] repo, include a link to the migration guide as per the [breaking change policy].*
    arnemolland authored Jun 14, 2023
    Configuration menu
    Copy the full SHA
    6d2b5ea View commit details
    Browse the repository at this point in the history

Commits on Jun 15, 2023

  1. [flutter_tools] cache flutter sdk version to disk (#124558)

    Fixes #112833
    
    Most of the actual changes here are in [packages/flutter_tools/lib/src/version.dart](https://github.com/flutter/flutter/pull/124558/files#diff-092e00109d9e1589fbc7c6de750e29a6ae512b2dd44e85d60028953561201605), while the rest is largely just addressing changes to the constructor of `FlutterVersion` which now has different dependencies.
    
    This change makes `FlutterVersion` an interface with two concrete implementations:
    
    1. `_FlutterVersionGit` which is mostly the previous implementation, and
    2. `_FlutterVersionFromFile` which will read a new `.version.json` file from the root of the repo
    
    The [`FlutterVersion` constructor](https://github.com/flutter/flutter/pull/124558/files#diff-092e00109d9e1589fbc7c6de750e29a6ae512b2dd44e85d60028953561201605R70) is now a factory that first checks if `.version.json` exists, and if so returns an instance of `_FlutterVersionFromGit` else it returns the fallback `_FlutterVersionGit` which will end up writing `.version.json` so that we don't need to re-calculate the version on the next invocation.
    
    `.version.json` will be deleted in the bash/batch entrypoints any time we need to rebuild he tool (this will usually be because the user did `flutter upgrade` or `flutter channel`, or manually changed the commit with git).
    christopherfujino authored Jun 15, 2023
    Configuration menu
    Copy the full SHA
    3246808 View commit details
    Browse the repository at this point in the history
  2. [web] Pass creation params to the platform view factory (#128146)

    This concludes step 1 of the `HtmlElementView` improvements. It's now possible to pass creation params to platform view factories directly from `HtmlElementView`.
    
    Here's a sample app using a single factory to render platform views in different colors:
    
    <details>
      <summary>Code sample</summary>
      
      ```dart
    import 'dart:js_interop';
    import 'dart:ui_web' as ui_web;
    import 'package:flutter/material.dart';
    import 'package:web/web.dart' as web;
    
    void main() {
      runApp(MyApp());
    }
    
    class MyApp extends StatelessWidget {
      @OverRide
      Widget build(BuildContext context) {
        return MaterialApp(
          title: 'Platform View Demo',
          home: Scaffold(
            appBar: AppBar(
              title: Text('Platform View Demo'),
            ),
            body: Center(
              child: Column(
                mainAxisAlignment: MainAxisAlignment.spaceEvenly,
                children: [
                  BoxWrapper('red'),
                  BoxWrapper(null),
                  BoxWrapper('blue'),
                ],
              ),
            ),
          ),
        );
      }
    }
    
    bool isRegistered = false;
    
    class BoxWrapper extends StatelessWidget {
      const BoxWrapper(this.cssColor);
    
      final String? cssColor;
    
      void register() {
        if (isRegistered) return;
        isRegistered = true;
    
        ui_web.platformViewRegistry.registerViewFactory('my-platform-view', (
          id, {
          Object? params,
        }) {
          params as String?;
    
          final element = web.document.createElement('div'.toJS) as web.HTMLElement;
          element.textContent = 'Platform View'.toJS;
          element.style
            ..lineHeight = '100px'.toJS
            ..fontSize = '24px'.toJS
            ..backgroundColor = (params ?? 'pink').toJS
            ..textAlign = 'center'.toJS;
          return element;
        });
      }
    
      @OverRide
      Widget build(BuildContext context) {
        register();
        return SizedBox(
          width: 200,
          height: 100,
          child: Card(
            child: HtmlElementView(
              viewType: 'my-platform-view',
              creationParams: cssColor,
            ),
          ),
        );
      }
    }
      ```
    </details>
    
    ![image](https://github.com/flutter/flutter/assets/1278212/4b62ed8b-2314-49d6-9b4a-5da849bf2a48)
    
    Depends on flutter/engine#42255
    
    Part of #127030
    mdebbar authored Jun 15, 2023
    Configuration menu
    Copy the full SHA
    b0188cd View commit details
    Browse the repository at this point in the history
Loading