sbIMediaPage Interface Reference

A generic interface for UI that renders a media list view. More...

import"sbIMediaPage.idl";

Inheritance diagram for sbIMediaPage:
[legend]
Collaboration diagram for sbIMediaPage:
[legend]

Public Member Functions

PRBool highlightItem (in unsigned long aViewIndex)
 Tell the page to make the MediaItem at the given index visible and highlighted. More...
 
PRBool canDrop (in nsIDOMEvent aEvent, in nsIDragSession aSession)
 Called when something is dragged over the tabbrowser tab for this page. More...
 
PRBool onDrop (in nsIDOMEvent aEvent, in nsIDragSession aSession)
 Called when something is dropped on the tabbrowser tab for this page. More...
 

Public Attributes

attribute sbIMediaListView mediaListView
 A filtered, sorted view of the media list that the page is supposed to render. More...
 
readonly attribute PRBool isOnlyView
 Should be true if the media page is the only allowed view for the data. More...
 

Detailed Description

A generic interface for UI that renders a media list view.

Pages that display libraries or other media lists must supply this interface in order for browser history, playback, find current track, and other external functionality to work as expected.

The primary purpose of the interface is to facilitate setting the sbIMediaListView that the page is to display.

For sample code and more information, see http://developer.songbirdnest.com/add-on-api/

See Also
sbIMediaListView, sbIMediaList, playlistPage.xul

Definition at line 49 of file sbIMediaPage.idl.

Member Function Documentation

PRBool sbIMediaPage::canDrop ( in nsIDOMEvent  aEvent,
in nsIDragSession  aSession 
)

Called when something is dragged over the tabbrowser tab for this page.

Parameters
aEventThe draggedover event
aSessionThe items to be dropped
Returns
True if the drop can proceed
PRBool sbIMediaPage::highlightItem ( in unsigned long  aViewIndex)

Tell the page to make the MediaItem at the given index visible and highlighted.

Parameters
aViewIndexIndex into the MediaListView (needed, since MediaItems may appear multiple times in a list)
Returns
True if the page is able to show the corresponding item
PRBool sbIMediaPage::onDrop ( in nsIDOMEvent  aEvent,
in nsIDragSession  aSession 
)

Called when something is dropped on the tabbrowser tab for this page.

Parameters
aEventThe drop event
aSessionThe items to be dropped
Returns
True if the drop succeeded

Member Data Documentation

readonly attribute PRBool sbIMediaPage::isOnlyView

Should be true if the media page is the only allowed view for the data.

Definition at line 68 of file sbIMediaPage.idl.

attribute sbIMediaListView sbIMediaPage::mediaListView

A filtered, sorted view of the media list that the page is supposed to render.

The mediaListView will be set by the browser during the capturing phase of the window load event, meaning that it should be available by standard onLoad time.

Note that the mediaListView should not be set again after load.

Definition at line 62 of file sbIMediaPage.idl.


The documentation for this interface was generated from the following file: