[auth] Move to ViewHolderToken
The ViewOwner callsites are dead code.
SCN-1018 #comment
SCN-1291 #comment
Change-Id: I18655e5c0e47bc2b1d2902f1c0ed9fc2474af8b3
diff --git a/bin/userpicker_base_shell/BUILD.gn b/bin/userpicker_base_shell/BUILD.gn
index e4b4125..2afd96c 100644
--- a/bin/userpicker_base_shell/BUILD.gn
+++ b/bin/userpicker_base_shell/BUILD.gn
@@ -58,7 +58,6 @@
"//topaz/lib/base_shell:lib.base_shell",
"//topaz/lib/settings:lib.settings",
"//topaz/public/dart/fuchsia_logger",
- "//topaz/public/dart/fidl",
"//topaz/public/dart/fuchsia_scenic_flutter",
"//topaz/public/dart/widgets:lib.widgets",
"//topaz/public/lib/device/dart",
diff --git a/bin/userpicker_base_shell/lib/authentication_ui_context_impl.dart b/bin/userpicker_base_shell/lib/authentication_ui_context_impl.dart
index 630f1c4..f806614 100644
--- a/bin/userpicker_base_shell/lib/authentication_ui_context_impl.dart
+++ b/bin/userpicker_base_shell/lib/authentication_ui_context_impl.dart
@@ -2,10 +2,8 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-import 'package:fidl/fidl.dart';
import 'package:fidl_fuchsia_auth/fidl_async.dart';
import 'package:fidl_fuchsia_ui_views/fidl_async.dart';
-import 'package:fidl_fuchsia_ui_viewsv1token/fidl_async.dart';
import 'package:flutter/widgets.dart';
import 'package:zircon/zircon.dart';
@@ -29,19 +27,14 @@
@override
// ignore: override_on_non_overriding_method
- Future<void> startOverlay(InterfaceHandle<ViewOwner> viewOwner) =>
- startOverlay2(EventPair(viewOwner?.passChannel()?.passHandle()));
+ Future<void> startOverlay(ViewHolderToken viewHolderToken) async =>
+ _onStartOverlay?.call(viewHolderToken);
@override
// ignore: override_on_non_overriding_method
- Future<void> startOverlay2(EventPair viewHolderToken) {
- _onStartOverlay?.call(ViewHolderToken(value: viewHolderToken));
- return null;
- }
+ Future<void> startOverlay2(EventPair viewHolderToken) async =>
+ await startOverlay(ViewHolderToken(value: viewHolderToken));
@override
- Future<void> stopOverlay() {
- _onStopOverlay?.call();
- return null;
- }
+ Future<void> stopOverlay() async => _onStopOverlay?.call();
}