pub trait RequestDispatch<Ctx> {
    type Error;
    type DestroyFut<'a>: Future<Output = Result<(), Self::Error>> + 'a
       where Ctx: 'a;
    type CreatePositionerFut<'a>: Future<Output = Result<(), Self::Error>> + 'a
       where Ctx: 'a;
    type GetXdgSurfaceFut<'a>: Future<Output = Result<(), Self::Error>> + 'a
       where Ctx: 'a;
    type PongFut<'a>: Future<Output = Result<(), Self::Error>> + 'a
       where Ctx: 'a;

    // Required methods
    fn destroy<'a>(ctx: &'a mut Ctx, object_id: u32) -> Self::DestroyFut<'a>;
    fn create_positioner<'a>(
        ctx: &'a mut Ctx,
        object_id: u32,
        id: NewId
    ) -> Self::CreatePositionerFut<'a>;
    fn get_xdg_surface<'a>(
        ctx: &'a mut Ctx,
        object_id: u32,
        id: NewId,
        surface: Object
    ) -> Self::GetXdgSurfaceFut<'a>;
    fn pong<'a>(
        ctx: &'a mut Ctx,
        object_id: u32,
        serial: u32
    ) -> Self::PongFut<'a>;
}

Required Associated Types§

source

type Error

source

type DestroyFut<'a>: Future<Output = Result<(), Self::Error>> + 'a where Ctx: 'a

Type of future returned by destroy

source

type CreatePositionerFut<'a>: Future<Output = Result<(), Self::Error>> + 'a where Ctx: 'a

Type of future returned by create_positioner

source

type GetXdgSurfaceFut<'a>: Future<Output = Result<(), Self::Error>> + 'a where Ctx: 'a

Type of future returned by get_xdg_surface

source

type PongFut<'a>: Future<Output = Result<(), Self::Error>> + 'a where Ctx: 'a

Type of future returned by pong

Required Methods§

source

fn destroy<'a>(ctx: &'a mut Ctx, object_id: u32) -> Self::DestroyFut<'a>

destroy xdg_shell

Destroy this xdg_shell object.

Destroying a bound xdg_shell object while there are surfaces still alive created by this xdg_shell object instance is illegal and will result in a protocol error.

source

fn create_positioner<'a>( ctx: &'a mut Ctx, object_id: u32, id: NewId ) -> Self::CreatePositionerFut<'a>

create a positioner object

Create a positioner object. A positioner object is used to position surfaces relative to some parent surface. See the interface description and xdg_surface.get_popup for details.

source

fn get_xdg_surface<'a>( ctx: &'a mut Ctx, object_id: u32, id: NewId, surface: Object ) -> Self::GetXdgSurfaceFut<'a>

create a shell surface from a surface

This creates an xdg_surface for the given surface. While xdg_surface itself is not a role, the corresponding surface may only be assigned a role extending xdg_surface, such as xdg_toplevel or xdg_popup.

This creates an xdg_surface for the given surface. An xdg_surface is used as basis to define a role to a given surface, such as xdg_toplevel or xdg_popup. It also manages functionality shared between xdg_surface based surface roles.

See the documentation of xdg_surface for more details about what an xdg_surface is and how it is used.

source

fn pong<'a>(ctx: &'a mut Ctx, object_id: u32, serial: u32) -> Self::PongFut<'a>

respond to a ping event

A client must respond to a ping event with a pong request or the client may be deemed unresponsive. See xdg_shell.ping.

Implementors§