YUI recommends YUI 3.

YUI 2 has been deprecated since 2011. This site acts as an archive for files and documentation.

Yahoo! UI Library

paginator  2.9.0

Yahoo! UI Library > paginator > YAHOO.widget.Paginator.ui.LastPageLink
Search:
 
Filters

Class YAHOO.widget.Paginator.ui.LastPageLink

ui Component to generate the link to jump to the last page.

Constructor

YAHOO.widget.Paginator.ui.LastPageLink ( p )
Parameters:
p <Pagintor> Paginator instance to attach to

Properties

current - private HTMLElement

Currently placed HTMLElement node

link - private HTMLElement

Link HTMLElement node

na - private HTMLElement

Empty place holder node for when the last page link is inappropriate to display in any form (unlimited paging).

span - private HTMLElement

Span node (inactive link)

Methods

destroy

private void destroy ( )
Removes the link/span node and clears event listeners

init

static void init ( paginator )
Decorates Paginator instances with new attributes. Called during Paginator instantiation.
Parameters:
paginator <Paginator> Paginator instance to decorate

onClick

void onClick ( e )
Listener for the link's onclick event. Passes to setPage method.
Parameters:
e <DOMEvent> The click event

render

HTMLElement render ( id_base )
Generate the nodes and return the appropriate node given the current pagination state.
Parameters:
id_base <string> used to create unique ids for generated nodes

update

void update ( e )
Swap the link, span, and na nodes if appropriate.
Parameters:
e <CustomEvent> The calling change event (ignored)

Events

beforeLastPageLinkClassChange

beforeLastPageLinkClassChange ( event )
Fires before the value for the configuration attribute 'lastPageLinkClass' changes. Return false to cancel the attribute change.
Parameters:
event <{oldValue: any, newValue: any}> An object containing the previous attribute value and the new value.

beforeLastPageLinkLabelChange

beforeLastPageLinkLabelChange ( event )
Fires before the value for the configuration attribute 'lastPageLinkLabel' changes. Return false to cancel the attribute change.
Parameters:
event <{oldValue: any, newValue: any}> An object containing the previous attribute value and the new value.

beforeLastPageLinkTitleChange

beforeLastPageLinkTitleChange ( event )
Fires before the value for the configuration attribute 'lastPageLinkTitle' changes. Return false to cancel the attribute change.
Parameters:
event <{oldValue: any, newValue: any}> An object containing the previous attribute value and the new value.

lastPageLinkClassChange

lastPageLinkClassChange ( event )
Fires when the value for the configuration attribute 'lastPageLinkClass' changes.
Parameters:
event <{oldValue: any, newValue: any}> An object containing the previous attribute value and the new value.

lastPageLinkLabelChange

lastPageLinkLabelChange ( event )
Fires when the value for the configuration attribute 'lastPageLinkLabel' changes.
Parameters:
event <{oldValue: any, newValue: any}> An object containing the previous attribute value and the new value.

lastPageLinkTitleChange

lastPageLinkTitleChange ( event )
Fires when the value for the configuration attribute 'lastPageLinkTitle' changes.
Parameters:
event <{oldValue: any, newValue: any}> An object containing the previous attribute value and the new value.

Configuration Attributes

lastPageLinkClass - object

CSS class assigned to the link/span
Default Value: 'yui-pg-last'

lastPageLinkLabel - object

Used as innerHTML for the last page link/span.
Default Value: 'last >>'

lastPageLinkTitle - object

Used as title for the last page link.
Default Value: 'Last Page'


Copyright © 2011 Yahoo! Inc. All rights reserved.