Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 0e01ea41 authored by Bjorn Bringert's avatar Bjorn Bringert
Browse files

Deprecate DialogInterface methods in SearchManager

android.app.SearchManager implements
DialogInterface.OnDismissListener and DialogInterface.OnCancelListener
and thus exposes the methods onCancel(DialogInterface dialog) and
onDismiss(DialogInterface dialog). This was used by the SearchManager
to register itself as a listener on the search dialog, but is no
longer used.

This was an implementation detail that leaked into the public
API. Removing them would change the API, so they are deprecated instead.

Fixes http://b/issue?id=1962203
parent 4d2dbebf
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -23622,7 +23622,7 @@
 synchronized="false"
 static="false"
 final="false"
 deprecated="not deprecated"
 deprecated="deprecated"
 visibility="public"
>
<parameter name="dialog" type="android.content.DialogInterface">
@@ -23635,7 +23635,7 @@
 synchronized="false"
 static="false"
 final="false"
 deprecated="not deprecated"
 deprecated="deprecated"
 visibility="public"
>
<parameter name="dialog" type="android.content.DialogInterface">
+7 −2
Original line number Diff line number Diff line
@@ -1719,11 +1719,16 @@ public class SearchManager

    }

    // TODO: remove the DialogInterface interfaces from SearchManager.
    // This changes the public API, so I'll do it in a separate change.
    /**
     * @deprecated This method is an obsolete internal implementation detail. Do not use.
     */
    public void onCancel(DialogInterface dialog) {
        throw new UnsupportedOperationException();
    }

    /**
     * @deprecated This method is an obsolete internal implementation detail. Do not use.
     */
    public void onDismiss(DialogInterface dialog) {
        throw new UnsupportedOperationException();
    }