Skip to content

[widgets/raw_menu_anchor.dart] Remove final class modifier on MenuController #174082

@davidhicks980

Description

@davidhicks980

Steps to reproduce

  1. Extend MenuController()

As noted in #167806 (comment):

Making the MenuController final just broke our code, we were extending the MenuController to add some animation functionality. Was this breaking change really intended?

Expected results

MenuController should be extensible.

Actual results

MenuController is not extensible because MenuController is final. An invalid_use_of_type_outside_library error is shown.

Code sample

Code sample
import 'package:flutter/material.dart';

class ExtendedMenuController extends MenuController {
  ExtendedMenuController();
}

Screenshots or Video

Screenshots / Video demonstration

[Upload media here]

Logs

Logs
[Paste your logs here]

Flutter Doctor output

Doctor output
[✓] Flutter (Channel master, 3.33.0-1.0.pre-1480, on macOS 15.5 24F74 darwin-arm64, locale en-US) [1,428ms]
    • Flutter version 3.33.0-1.0.pre-1480 on channel master at /Users/davidhicks/fvm/versions/master
    • Upstream repository https://github.com/flutter/flutter.git
    • Framework revision 8d937c05b1 (45 minutes ago), 2025-08-19 17:49:10 -0400
    • Engine revision 3fb62e6450
    • Dart version 3.10.0 (build 3.10.0-110.0.dev)
    • DevTools version 2.49.0
    • Feature flags: enable-web, enable-linux-desktop, enable-macos-desktop, enable-windows-desktop, enable-android, enable-ios, cli-animations, enable-native-assets, omit-legacy-version-file,
      enable-lldb-debugging

[!] Android toolchain - develop for Android devices (Android SDK version 35.0.0) [1,390ms]
    • Android SDK at /Users/davidhicks/Library/Android/sdk
    • Emulator version 35.4.9.0 (build_id 13025442) (CL:N/A)
    • Platform android-36, build-tools 35.0.0
    • ANDROID_HOME = /Users/davidhicks/Library/Android/sdk
    • Java binary at: /Library/Java/JavaVirtualMachines/jdk-17.0.2.jdk/Contents/Home/bin/java
      This JDK is specified in your Flutter configuration.
      To change the current JDK, run: `flutter config --jdk-dir="path/to/jdk"`.
    • Java version Java(TM) SE Runtime Environment (build 17.0.2+8-LTS-86)
    ! Some Android licenses not accepted. To resolve this, run: flutter doctor --android-licenses

[✓] Xcode - develop for iOS and macOS (Xcode 16.4) [1,120ms]
    • Xcode at /Applications/Xcode.app/Contents/Developer
    • Build 16F6
    • CocoaPods version 1.16.2

[✓] Chrome - develop for the web [9ms]
    • Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome

[✓] Connected device (2 available) [6.0s]
    • macOS (desktop) • macos  • darwin-arm64   • macOS 15.5 24F74 darwin-arm64
    • Chrome (web)    • chrome • web-javascript • Google Chrome 139.0.7258.128
    ! Error: Browsing on the local area network for David’s iPhone. Ensure the device is unlocked and attached with a cable or associated with the same local area network as this Mac.
      The device must be opted into Developer Mode to connect wirelessly. (code -27)

[✓] Network resources [206ms]
    • All expected network resources are available.

! Doctor found issues in 1 category.

Metadata

Metadata

Assignees

Labels

frameworkflutter/packages/flutter repository. See also f: labels.r: fixedIssue is closed as already fixed in a newer versionteam-frameworkOwned by Framework team

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions