Home · All Namespaces · All Classes · Grouped Classes · Modules · Functions codeless banner

LauncherView Class Reference
[QtBaseModule]

The LauncherView class provides the base for any type of laucnher view used by Qtopia. More...

    #include <LauncherView>

Inherits QWidget.

Inherited by ApplicationLauncherView, ArchiveViewer, ContentSetLauncherView, DocumentLauncherView, and TaskManagerLauncherView.

Public Functions

Public Slots

Signals

Static Public Members

Protected Functions

Protected Slots

Additional Inherited Members


Detailed Description

The LauncherView class provides the base for any type of laucnher view used by Qtopia.

This class is part of the Qt Extended server and cannot be used by other Qt Extended applications.

See also ApplicationLauncherView and DocumentLauncherView.


Member Function Documentation

LauncherView::LauncherView ( QWidget * parent = 0, Qt::WFlags flags = 0 )

Create a LauncherView instance with the given parent and flags.

LauncherView::~LauncherView ()   [virtual]

Destroys the LauncherView.

void LauncherView::addItem ( QContent * app, bool resort = true )

Adds app to the view. resort is ignored at this stage.

See also removeItem().

void LauncherView::clearSelection ()

Clears the current selection.

void LauncherView::clicked ( QContent content )   [signal]

This signal is emitted whenever the user clickes on an item. The activated item is passed as content object.

LauncherView * LauncherView::createLauncherView ( const QByteArray & name, QWidget * parent = 0, Qt::WFlags flags = 0 )   [static]

Returns a new launcher view instance with the given parent and flags. name is the name of the LauncherView subclass to be created.

New launcher view subclasses can be registered via the UIFactory class and UIFACTORY_REGISTER_WIDGET().

    //customlauncherview.cpp
    #include "uifactory.h"
    #include "launcherview.h"

    class CustomLauncherView : public LauncherView {

    };

    UIFACTORY_REGISTER_WIDGET(CustomLauncherView);

    //code.cpp
    LauncherView *view = LauncherView::createLauncherView( "CustomLauncherView", parent, flags );

Launcher view instances should be created via this factory method whenever the caller doesn't intend to actually include the declaration for CustomLauncherView.

This function returns a null pointer if name doesn't exist.

void LauncherView::currentChanged ( const QModelIndex & current, const QModelIndex & previous )   [virtual protected slot]

This slot is called when a new item becomes the current item. The previous current item is specified by the previous index, and the new item by the current index.

QModelIndex LauncherView::currentIndex () const

Returns the index of the currently selected item.

const QContent LauncherView::currentItem () const

Returns the currently selected item.

QListView::Flow LauncherView::flow () const

Returns the direction the items layout should flows.

See also setFlow() and QListView::flow().

void LauncherView::handleItemClicked ( const QModelIndex & item, bool setCurrentIndex )   [virtual protected]

This event handler can be reimplemented in a subclass to react when a mouse button is clicked with the specified item. item will be selected if setCurrentIndex is true.

void LauncherView::handleItemPressed ( const QModelIndex & item )   [virtual protected]

This event handler can be reimplemented in a subclass to react when a mouse button is pressed with the specified item.

void LauncherView::handleReturnPressed ( const QModelIndex & item )   [virtual protected]

This event handler can be reimplemented in a subclass to react to Enter or Return key press on the current item. The default implementation emits the clicked() signal.

QSize LauncherView::listIconSize ( QWidget * widget )   [static]

Returns the size of icons the given widget should use if it is a launcher view in list mode. This can be used to make other list views look consistent with launcher views.

QContentSetModel * LauncherView::model () const

Returns the content model that the view is presenting.

See also setModel().

void LauncherView::removeAllItems ()

Removes all items from the view

void LauncherView::removeItem ( const QContent & app )

Removes app from the view.

See also addItem().

void LauncherView::resetSelection ()   [virtual]

This function can be reimplemented by subclasses to adjust the way how the view is reset. The default implementation selects the first item in the view.

void LauncherView::rightPressed ( QContent content )   [signal]

This signal is emitted when the user clciks on content with the right mouse button. This signal may be used in conjunction with a context menu.

void LauncherView::setAuxiliaryFilter ( const QContentFilter & filter )   [slot]

filter acts as an auxiliary filter besides the main filter.

void LauncherView::setBusy ( bool on )

Sets the busy state of the currently selected item to on. This indicates to the user that the current selection is processed.

void LauncherView::setColumns ( int columns )

Sets the number of columns. This value defaults to 1.

void LauncherView::setFilter ( const QContentFilter & filter )   [virtual]

The view will be adjusted according to filter.

void LauncherView::setFlow ( QListView::Flow flow )

Sets the direction the items layout should flow.

This property only affects the Icon view mode.

See also flow() and QListView::setFlow().

void LauncherView::setItemDelegate ( QAbstractItemDelegate * delegate )

Sets the item delegate for the contained view and its model to delegate. The old delegate is deleted in the process.

See also QAbstractItemView::setItemDelegate().

void LauncherView::setModel ( QContentSetModel * model )

Sets a new model for this view. Any existing model will be deleted.

See also model().

void LauncherView::setViewMode ( QListView::ViewMode m )

Sets the viewmode of the contained item view to m.

See also viewMode() and QListView::setViewMode().

void LauncherView::showCategory ( const QContentFilter & filter )   [slot]

Only items that are of category filter will be shown.

void LauncherView::showType ( const QContentFilter & filter )   [slot]

filter is applied in addition to the main filter.

See also setFilter().

QListView::ViewMode LauncherView::viewMode () const

Returns the used view mode.

See also setViewMode() and QListView::viewMode().


Copyright © 2009 Nokia Trademarks
Qt Extended 4.4.3