from patshared import PortMode, PortType, BoxPos, BoxLayoutMode


class ProtoCallbacker:
    '''manage actions coming from patchcanvas.'''
    def group_info(self, group_id: int):...
    def group_rename(
            self, group_id: int, pretty_name: str, save_in_jack: bool):...
    def group_pos_modified(self, group_id: int):...
    def group_splitted(self, group_id: int):...
    def group_joined(self, group_id: int):...
    def group_move(
            self, group_id: int, port_mode: PortMode, x: int, y: int):...
    def boxes_moved(self, *pos_tuples: tuple[int, PortMode, int, int]):...
    def group_box_pos_changed(
            self, group_id: int, port_mode: PortMode, box_pos: BoxPos):...
    def group_wrap(
            self, group_id: int, splitted_mode: PortMode, yesno: bool):...
    def group_layout_change(self, group_id: int, port_mode: PortMode,
                            layout_mode: BoxLayoutMode):...
    def group_selected(self, group_id: int, port_mode: PortMode):...
    def group_hide_box(self, group_id: int, port_mode: PortMode):...
    def group_menu_call(self, group_id: int, port_mode: PortMode):...
    def portgroup_add(self, group_id: int, port_mode: PortMode,
                      port_type: PortType, port_ids: tuple[int, ...]):...
    def portgroup_remove(self, group_id: int, portgroup_id: int):...
    def port_info(self, group_id: int, port_id: int):...
    def port_rename(self, group_id: int, port_id: int,
                    pretty_name: str, save_in_jack: bool):...
    def ports_connect(self, group_out_id: int, port_out_id: int,
                      group_in_id: int, port_in_id: int):...
    def ports_disconnect(self, connection_id: int):...
    def port_menu_call(self, group_id: int, port_id: int, connect_only: bool,
                       x: int, y: int):...
    def portgroup_menu_call(self, group_id: int, portgrp_id: int, connect_only: bool,
                             x: int, y: int):...
    def plugin_clone(self, plugin_id: int):...
    def plugin_edit(self, plugin_id: int):...
    def plugin_rename(self, plugin_id: int):...
    def plugin_replace(self, plugin_id: int):...
    def plugin_remove(self, plugin_id: int):...
    def plugin_show_ui(self, plugin_id: int):...
    def inline_display(self, plugin_id: int, width: int, height: int):...
    def bg_right_click(
            self, x: int, y: int, scene_x: float, scene_y: float,
            selected_boxes: dict[int, PortMode]):...
    def bg_double_click(self):...
    def client_show_gui(self, group_id: int, visible: int):...
    def theme_changed(self, theme_ref: str):...
    def animation_finished(self):...