pylav.extension.red.ui.menus package#

Submodules#

pylav.extension.red.ui.menus.equalizer module#

pylav.extension.red.ui.menus.generic module#

class pylav.extension.red.ui.menus.generic.BaseMenu(cog, bot, source, *, delete_after_timeout=True, timeout=120, message=None, starting_page=0, **kwargs)[source]#

Bases: View

async get_page(page_num)[source]#
async interaction_check(interaction)[source]#

Just extends the default reaction_check to use owner_ids

async on_error(error, item, interaction)[source]#

A callback that is called when an item’s callback or interaction_check() fails with an error.

The default implementation logs to the library logger.

Parameters:
  • interaction (Interaction) – The interaction that led to the failure.

  • error (Exception) – The exception that was raised.

  • item (Item) – The item that failed the dispatch.

async on_timeout()[source]#

A callback that is called when a view’s timeout elapses without being explicitly stopped.

async prepare()[source]#
async send_initial_message(ctx)[source]#
async show_checked_page(page_number, interaction)[source]#
async show_page(page_number, interaction)[source]#
property source#
class pylav.extension.red.ui.menus.generic.EntryPickerMenu(cog, bot, source, selector_text, selector_cls, original_author, *, clear_buttons_after=False, delete_after_timeout=True, timeout=120, message=None, starting_page=0, **kwargs)[source]#

Bases: BaseMenu

async prepare()[source]#
result#
async show_page(page_number, interaction)[source]#
property source#
async start(ctx)[source]#
async wait_for_response()[source]#
class pylav.extension.red.ui.menus.generic.PaginatingMenu(cog, bot, source, original_author, *, clear_buttons_after=True, delete_after_timeout=False, timeout=120, message=None, starting_page=0, **kwargs)[source]#

Bases: BaseMenu

async prepare()[source]#
async start(ctx)[source]#
class pylav.extension.red.ui.menus.generic.PromptYesOrNo(cog, initial_message, *, timeout=120)[source]#

Bases: View

author#
ctx#
message#
async on_timeout()[source]#

A callback that is called when a view’s timeout elapses without being explicitly stopped.

response#
async send_initial_message(ctx)[source]#
async start(ctx)[source]#
stop()[source]#

Stops listening to interaction events from this view.

This operation cannot be undone.

async wait_for_yes_no(wait_for=None)[source]#

pylav.extension.red.ui.menus.nodes module#

class pylav.extension.red.ui.menus.nodes.AddNodeFlow(cog, original_author)[source]#

Bases: View

author#
ctx#
async interaction_check(interaction)[source]#

Just extends the default reaction_check to use owner_ids

message#
async on_timeout()[source]#

A callback that is called when a view’s timeout elapses without being explicitly stopped.

async prompt_host(interaction)[source]#
async prompt_name(interaction)[source]#
async prompt_password(interaction)[source]#
async prompt_port(interaction)[source]#
async prompt_resume_timeout(interaction)[source]#
async send_initial_message(ctx, description=None, title=None)[source]#
async start(ctx, description=None, title=None)[source]#
stop()[source]#

Stops listening to interaction events from this view.

This operation cannot be undone.

async wait_until_complete()[source]#
class pylav.extension.red.ui.menus.nodes.NodeManagerMenu(cog, bot, source, original_author, *, delete_after_timeout=True, timeout=120, message=None, starting_page=0, **kwargs)[source]#

Bases: BaseMenu

async interaction_check(interaction)[source]#

Just extends the default reaction_check to use owner_ids

async on_timeout()[source]#

A callback that is called when a view’s timeout elapses without being explicitly stopped.

async prepare()[source]#
async prompt_host(interaction)[source]#
async prompt_name(interaction)[source]#
async prompt_password(interaction)[source]#
async prompt_port(interaction)[source]#
async prompt_resume_timeout(interaction)[source]#
async send_initial_message(ctx, description=None, title=None)[source]#
property source#
async start(ctx, description=None, title=None)[source]#
stop()[source]#

Stops listening to interaction events from this view.

This operation cannot be undone.

async wait_until_complete()[source]#
class pylav.extension.red.ui.menus.nodes.NodePickerMenu(cog, bot, source, selector_text, selector_cls, original_author, *, clear_buttons_after=False, delete_after_timeout=True, timeout=120, message=None, starting_page=0, **kwargs)[source]#

Bases: BaseMenu

async prepare()[source]#
result#
async show_page(page_number, interaction)[source]#
property source#
async start(ctx)[source]#
async wait_for_response()[source]#

pylav.extension.red.ui.menus.player module#

class pylav.extension.red.ui.menus.player.StatsMenu(cog, bot, source, original_author, *, clear_buttons_after=False, delete_after_timeout=True, timeout=600, message=None, starting_page=0, **kwargs)[source]#

Bases: BaseMenu

async get_page(page_num)[source]#
async prepare()[source]#
property source#
async start(ctx)[source]#

pylav.extension.red.ui.menus.playlist module#

class pylav.extension.red.ui.menus.playlist.PlaylistCreationFlow(cog, original_author, *, timeout=120)[source]#

Bases: View

author#
ctx#
async interaction_check(interaction)[source]#

Just extends the default reaction_check to use owner_ids

message#
name_prompt#
async on_timeout()[source]#

A callback that is called when a view’s timeout elapses without being explicitly stopped.

async prompt_name(interaction)[source]#
async prompt_scope(interaction)[source]#
async prompt_url(interaction)[source]#
scope_prompt#
async send_initial_message(ctx, description=None, title=None)[source]#
async start(ctx, description=None, title=None)[source]#
stop()[source]#

Stops listening to interaction events from this view.

This operation cannot be undone.

url_prompt#
class pylav.extension.red.ui.menus.playlist.PlaylistManageFlow(cog, original_author, playlist, *, timeout=120, manageable=True)[source]#

Bases: View

author#
ctx#
async interaction_check(interaction)[source]#

Just extends the default reaction_check to use owner_ids

message#
name_prompt#
async on_timeout()[source]#

A callback that is called when a view’s timeout elapses without being explicitly stopped.

async prompt_add_tracks(interaction)[source]#
async prompt_name(interaction)[source]#
async prompt_remove_tracks(interaction)[source]#
async prompt_scope(interaction)[source]#
async prompt_url(interaction)[source]#
scope_prompt#
async send_initial_message(ctx, description=None, title=None)[source]#
async start(ctx, description=None, title=None)[source]#
stop()[source]#

Stops listening to interaction events from this view.

This operation cannot be undone.

url_prompt#
class pylav.extension.red.ui.menus.playlist.PlaylistPickerMenu(cog, bot, source, selector_text, selector_cls, original_author, *, clear_buttons_after=False, delete_after_timeout=True, timeout=120, message=None, starting_page=0, **kwargs)[source]#

Bases: BaseMenu

async prepare()[source]#
result#
async show_page(page_number, interaction)[source]#
property source#
async start(ctx)[source]#
async wait_for_response()[source]#

pylav.extension.red.ui.menus.queue module#

class pylav.extension.red.ui.menus.queue.QueueMenu(cog, bot, source, original_author, *, delete_after_timeout=True, timeout=600, message=None, starting_page=0, history=False, **kwargs)[source]#

Bases: BaseMenu

async prepare()[source]#
property source#
async start(ctx)[source]#
class pylav.extension.red.ui.menus.queue.QueuePickerMenu(cog, bot, source, original_author, *, delete_after_timeout=True, timeout=120, message=None, starting_page=0, menu_type, **kwargs)[source]#

Bases: BaseMenu

async prepare()[source]#
async send_initial_message(ctx)[source]#
async show_page(page_number, interaction)[source]#
property source#
async start(ctx)[source]#

Module contents#