Remove Cupertino chat cleanup leftovers

Keep chat and folder-picker UI on the Material path by removing obsolete Cupertino imports, icon metadata, flags, and alternate control handling while preserving existing behavior and focused test coverage.
This commit is contained in:
2026-11-11 20:06:37 +00:00
parent 3f05421e8b
commit 04ba81e0ea
18 changed files with 33 additions and 123 deletions
@@ -1,21 +1,12 @@
import '../../../../ui/adaptive/segmented_bar_overflow.dart';
import 'package:flutter/material.dart';
/// Which standard control family this screen renders.
enum ChatControlsStyle { material, cupertino }
/// Always Material: the app is Material-only, so no screen ever asks for the
/// Cupertino family. The parameter stays for callers.
ChatControlsStyle chatControlsStyleOf(BuildContext context) =>
ChatControlsStyle.material;
class ChatBarAction extends StatelessWidget implements SegmentedOverflowable {
const ChatBarAction({
super.key,
required this.label,
required this.onPressed,
required this.materialIcon,
required this.cupertinoIcon,
this.identifier,
});
@@ -23,8 +14,6 @@ class ChatBarAction extends StatelessWidget implements SegmentedOverflowable {
final VoidCallback onPressed;
final IconData materialIcon;
/// Kept for callers; the Material toolbar always draws [materialIcon].
final IconData cupertinoIcon;
final String? identifier;
/// A narrow bar moves it into its More menu, under the bar's host's icon.
@@ -4,7 +4,6 @@ import 'chat_machine_picker.dart';
import '../../../../ui/adaptive/segmented_bar.dart';
import 'dart:async';
import 'package:flutter/cupertino.dart';
import 'package:flutter/material.dart';
import '../../../../ui/layout/content_width.dart';
@@ -437,14 +436,12 @@ class _ChatSessionsScreenState extends State<ChatSessionsScreen> {
label: 'New chat',
onPressed: _newChat,
materialIcon: Icons.add,
cupertinoIcon: CupertinoIcons.add,
),
ChatBarAction(
key: const Key('chat-refresh'),
label: 'Refresh',
onPressed: _controller.refresh,
materialIcon: Icons.refresh,
cupertinoIcon: CupertinoIcons.refresh,
),
];
}