Qtopia Home - Classes - Hierachy - Annotated - Functions - Qt Embedded

Action Class Reference

The Action class is used by the plugins to define certain menu/toolbar actions. More...

#include <common/action.h>

List of all member functions.

Public Members


Detailed Description

The Action class is used by the plugins to define certain menu/toolbar actions.

The Action class is a convenience class derived from QAction and used to dynamically embed certain actions into the Menu and Toolbar of Qtopia desktop when the plugin is shown. The placing of actions in menu and toolbars is defined by an xml string that Qtopia Desktop can query from the PluginInterface.

Actions need a unique id to be able to be able to identify them in the xml description.

The parent of the action should always be the QMainWindow passed to the plugin interface.

See the QAction and Qt documentation for a more detailed discussion of the concept of actions.

See also Qtopia Desktop Classes.


Member Function Documentation

Action::Action ( const QString & id, QObject * parent, const char * name = 0, bool toggle = FALSE )

Constructs an action with the given id.

parent, name, and toggle are passed on to QAction.

Action::Action ( const QString & id, const QString & text, const QIconSet & icon, const QString & menuText, int accel, QObject * parent, const char * name = 0, bool toggle = FALSE )

Constructs an action with the given id.

text, icon, menuText, accel, parent, name, and toggle are passed on to QAction.

Action::Action ( const QString & id, const QString & text, const QString & menuText, int accel, QObject * parent, const char * name = 0, bool toggle = FALSE )

Constructs an action with the given id.

text, menuText, accel, parent, name, and toggle are passed on to QAction.

int Action::numAddedTo () const

Returns the number of widgets to which this Action has been added.


This file is part of the Qtopia platform, copyright © 1995-2005 Trolltech, all rights reserved.


Copyright © 2005 Trolltech Trademarks
Qtopia version 2.1.2