from _typeshed import Incomplete
from android.content import Context as Context, DialogInterface
from android.graphics.drawable import Drawable as Drawable
from android.view import View as View
from java import Override as Override
from org.telegram.ui.ActionBar import AlertDialog, Theme
from typing import Callable

class _ButtonClickListenerProxy(Incomplete):
    def __init__(self, py_callable: Callable[[AlertDialogBuilder, int], None], builder_instance: AlertDialogBuilder) -> None: ...
    def onClick(self, dialog_java_instance: AlertDialog, which: int): ...

class _ItemsClickListenerProxy(Incomplete):
    def __init__(self, py_callable: Callable[[AlertDialogBuilder, int], None], builder_instance: AlertDialogBuilder) -> None: ...
    def onClick(self, dialog_java_instance: DialogInterface, which: int): ...

class _DismissListenerProxy(Incomplete):
    def __init__(self, py_callable: Callable[[AlertDialogBuilder], None], builder_instance: AlertDialogBuilder) -> None: ...
    def onDismiss(self, dialog_java_instance: DialogInterface): ...

class _CancelListenerProxy(Incomplete):
    def __init__(self, py_callable: Callable[[AlertDialogBuilder], None], builder_instance: AlertDialogBuilder) -> None: ...
    def onCancel(self, dialog_java_instance: DialogInterface): ...

class AlertDialogBuilder:
    ALERT_TYPE_MESSAGE: int
    ALERT_TYPE_LOADING: int
    ALERT_TYPE_SPINNER: int
    BUTTON_POSITIVE: int
    BUTTON_NEGATIVE: int
    BUTTON_NEUTRAL: int
    def __init__(self, context: Context, progress_style: int = ..., resources_provider: Theme.ResourcesProvider | None = None) -> None: ...
    def get_context(self) -> Context: ...
    def set_title(self, title: str) -> AlertDialogBuilder: ...
    def set_message(self, message: str) -> AlertDialogBuilder: ...
    def set_message_text_view_clickable(self, clickable: bool) -> AlertDialogBuilder: ...
    def set_positive_button(self, text: str, listener: Callable[[AlertDialogBuilder, int], None] | None = None) -> AlertDialogBuilder: ...
    def set_negative_button(self, text: str, listener: Callable[[AlertDialogBuilder, int], None] | None = None) -> AlertDialogBuilder: ...
    def set_neutral_button(self, text: str, listener: Callable[[AlertDialogBuilder, int], None] | None = None) -> AlertDialogBuilder: ...
    def make_button_red(self, button_type: int) -> AlertDialogBuilder: ...
    def set_on_back_button_listener(self, listener: Callable[[AlertDialogBuilder, int], None] | None = None) -> AlertDialogBuilder: ...
    def set_view(self, view: View, height: int = -2) -> AlertDialogBuilder: ...
    def set_items(self, items: list[str], listener: Callable[[AlertDialogBuilder, int], None] | None = None, icons: list[int] | None = None) -> AlertDialogBuilder: ...
    def set_on_dismiss_listener(self, listener: Callable[[AlertDialogBuilder], None] | None = None) -> AlertDialogBuilder: ...
    def set_on_cancel_listener(self, listener: Callable[[AlertDialogBuilder], None] | None = None) -> AlertDialogBuilder: ...
    def set_top_image(self, res_id: int, background_color: int) -> AlertDialogBuilder: ...
    def set_top_drawable(self, drawable: Drawable, background_color: int) -> AlertDialogBuilder: ...
    def set_top_animation(self, res_id: int, size: int, auto_repeat: bool, background_color: int, layer_colors: dict[str, int] | None = None) -> AlertDialogBuilder: ...
    def set_top_animation_is_new(self, is_new: bool) -> AlertDialogBuilder: ...
    def set_dim_enabled(self, enabled: bool) -> AlertDialogBuilder: ...
    def set_dialog_button_color_key(self, theme_key: int) -> AlertDialogBuilder: ...
    def set_blurred_background(self, blur: bool, blur_behind_if_possible: bool = True) -> AlertDialogBuilder: ...
    def create(self) -> AlertDialogBuilder: ...
    def show(self) -> AlertDialogBuilder: ...
    def dismiss(self) -> None: ...
    def get_dialog(self) -> AlertDialog | None: ...
    def get_button(self, button_type: int) -> View | None: ...
    def set_progress(self, progress: int): ...
    def set_cancelable(self, cancelable: bool): ...
    def set_canceled_on_touch_outside(self, cancel: bool): ...
