File tree Expand file tree Collapse file tree 2 files changed +6
-1
lines changed
Expand file tree Collapse file tree 2 files changed +6
-1
lines changed Original file line number Diff line number Diff line change @@ -134,6 +134,10 @@ class _CallScreenState extends State<CallScreen> {
134134 body: StreamCallContainer (
135135 call: widget.call,
136136 callConnectOptions: widget.connectOptions,
137+ onCancelCallTap: () async {
138+ await widget.call.reject ();
139+ await widget.call.leave ();
140+ },
137141 callContentBuilder: (
138142 BuildContext context,
139143 Call call,
Original file line number Diff line number Diff line change @@ -41,7 +41,8 @@ class _HomeScreenState extends State<HomeScreen> {
4141 onButtonClick: (call, type, serviceType) async {
4242 switch (serviceType) {
4343 case ServiceType .call:
44- call.end ();
44+ call.reject ();
45+ call.leave ();
4546 case ServiceType .screenSharing:
4647 StreamVideoFlutterBackground .stopService (ServiceType .screenSharing);
4748 call.setScreenShareEnabled (enabled: false );
You can’t perform that action at this time.
0 commit comments