Remove Cupertino settings branches
Keep the Material settings implementation while preserving public Cupertino parameters for later cleanup. Narrow settings tests to the Material-only behavior.
This commit is contained in:
@@ -4,15 +4,12 @@ import '../../ui/adaptive/segmented_bar.dart';
|
||||
import 'dart:async';
|
||||
import 'package:flutter/foundation.dart' show kIsWeb;
|
||||
|
||||
import 'package:flutter/cupertino.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
import '../../core/transport/pipelines_client.dart' as transport;
|
||||
import '../../shell/shell_bar.dart';
|
||||
import '../attention/notify/notification_controller.dart';
|
||||
import 'default_endpoint.dart';
|
||||
import 'settings_controller.dart';
|
||||
import 'settings_controls.dart';
|
||||
import 'settings_font_section.dart';
|
||||
import 'settings_animation_section.dart';
|
||||
import 'settings_scale_section.dart';
|
||||
@@ -44,7 +41,7 @@ import 'managed_connection_section.dart';
|
||||
part 'settings_topic_pages.dart';
|
||||
|
||||
/// The Settings destination: the server connection and the server-side
|
||||
/// workspace, in native Material (native platforms) or Cupertino (iOS) controls.
|
||||
/// workspace in native Material controls.
|
||||
///
|
||||
/// The shared [transport.PipelinesClient] is supplied by the shell. This screen
|
||||
/// subscribes to it, connects/disconnects it and pings it on connected, but it
|
||||
@@ -190,25 +187,7 @@ class _SettingsScreenState extends State<SettingsScreen> {
|
||||
pages: _topicPages(),
|
||||
navigationScope: widget.navigationScope,
|
||||
);
|
||||
if (widget.embedded) {
|
||||
// Under the shell's bar the Cupertino page is the grouped background
|
||||
// right up to the top edge: the bar's scrim takes the same colour, so
|
||||
// no white band or seam shows above the groups.
|
||||
if (usesCupertinoControls(context) && ShellBar.available(context)) {
|
||||
return ShellBar(
|
||||
backgroundColor: settingsCupertinoBackground,
|
||||
child: content,
|
||||
);
|
||||
}
|
||||
return content;
|
||||
}
|
||||
if (usesCupertinoControls(context)) {
|
||||
return CupertinoPageScaffold(
|
||||
backgroundColor: settingsCupertinoBackground,
|
||||
navigationBar: const SegmentedBar(cupertino: true, title: 'Settings'),
|
||||
child: content,
|
||||
);
|
||||
}
|
||||
if (widget.embedded) return content;
|
||||
return Scaffold(
|
||||
extendBodyBehindAppBar: true,
|
||||
appBar: const SegmentedBar(cupertino: false, title: 'Settings'),
|
||||
|
||||
Reference in New Issue
Block a user