Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Namespace Members | Class Members | File Members | Related Pages

ServerInterface Class Reference

The ServerInterface class provides an interface for Qtopia custom launchers. More...

#include </home/clem/local/src/opie/core/launcher/serverinterface.h>

Inheritance diagram for ServerInterface:

Inheritance graph
[legend]
List of all members.

Public Types

enum  ApplicationState { Launching, Running, Terminated }
enum  DockArea { Top, Bottom, Left, Right }

Public Member Functions

virtual ~ServerInterface ()
virtual void createGUI ()=0
virtual void destroyGUI ()=0
virtual void typeAdded (const QString &type, const QString &name, const QPixmap &pixmap, const QPixmap &bgPixmap)=0
virtual void typeRemoved (const QString &type)=0
virtual void applicationAdded (const QString &type, const AppLnk &doc)=0
virtual void applicationRemoved (const QString &type, const AppLnk &doc)=0
virtual void allApplicationsRemoved ()=0
virtual void applicationStateChanged (const QString &name, ApplicationState state)=0
virtual void aboutToAddBegin ()
virtual void aboutToAddEnd ()
virtual void documentAdded (const DocLnk &doc)=0
virtual void documentRemoved (const DocLnk &doc)=0
virtual void allDocumentsRemoved ()=0
virtual void documentChanged (const DocLnk &oldDoc, const DocLnk &newDoc)=0
virtual void storageChanged (const QList< FileSystem > &)=0
virtual void applicationScanningProgress (int percent)=0
virtual void documentScanningProgress (int percent)=0
virtual bool requiresApplications () const =0
virtual bool requiresDocuments () const =0

Static Public Member Functions

static const AppLnkSetappLnks ()
static void dockWidget (QWidget *w, DockArea placement)

Detailed Description

The ServerInterface class provides an interface for Qtopia custom launchers.

The ServerInterface allows the user interface of the launcher to be customized to suit the device. For a PDA style device, the default launcher is strongly recommended, however specialist devices may choose to provide a launcher better suited to the application.

The launcher is fixed for any particular device and is not loaded as a plugin. Launcher interfaces must be compilied into the server by editing server.pro and server.cpp.

Definition at line 31 of file serverinterface.h.


Member Enumeration Documentation

enum ServerInterface::ApplicationState
 

The ApplicationState enum type specifies the state of an application. The possible values are:

  • Launching - the application has been requested, but is not yet running.
  • Running - the application is running.
  • Terminated - the application has been terminated.
Enumeration values:
Launching 
Running 
Terminated 

Definition at line 48 of file serverinterface.h.

enum ServerInterface::DockArea
 

The DockArea enum type defines the areas where widgets can be docked:

  • Top - the top of the screen.
  • Bottom - the Bottom of the screen.
  • Left - the Left of the screen.
  • Right - the Right of the screen.
Enumeration values:
Top 
Bottom 
Left 
Right 

Definition at line 69 of file serverinterface.h.


Constructor & Destructor Documentation

ServerInterface::~ServerInterface  )  [virtual]
 

Definition at line 354 of file serverinterface.cpp.


Member Function Documentation

virtual void ServerInterface::aboutToAddBegin  )  [inline, virtual]
 

Reimplemented in Launcher.

Definition at line 53 of file serverinterface.h.

Referenced by DocumentList::timerEvent().

virtual void ServerInterface::aboutToAddEnd  )  [inline, virtual]
 

Reimplemented in Launcher.

Definition at line 54 of file serverinterface.h.

Referenced by DocumentList::timerEvent().

ServerInterface::allApplicationsRemoved  )  [pure virtual]
 

Remove all applications from the launcher.

Implemented in Launcher.

Referenced by DocumentList::reloadAppLnks().

ServerInterface::allDocumentsRemoved  )  [pure virtual]
 

Remove all documents from the launcher.

Implemented in Launcher.

Referenced by DocumentList::reloadDocLnks().

ServerInterface::applicationAdded const QString type,
const AppLnk app
[pure virtual]
 

Add an application app of type type to the launcher.

See also:
applicationRemoved()

Implemented in Launcher.

Referenced by DocumentList::DiffAppLnks(), and DocumentList::reloadAppLnks().

ServerInterface::applicationRemoved const QString type,
const AppLnk app
[pure virtual]
 

Remove an application app of type type from the launcher.

See also:
applicationAdded()

Implemented in Launcher.

Referenced by DocumentList::DiffAppLnks().

ServerInterface::applicationScanningProgress int  percent  )  [pure virtual]
 

The system is scanning for installed applications. percent provides the percentage of the filesystems scanned. This function will always be called with percent equal to zero when scanning starts, and with percent equal to 100 when scanning is complete.

Implemented in Launcher.

Referenced by DocumentList::reloadAppLnks().

ServerInterface::applicationStateChanged const QString name,
ApplicationState  state
[pure virtual]
 

The application name has changed state to state. This can be used to show launch notification and update a list of running applications.

Implemented in Launcher.

Referenced by Server::applicationConnected(), Server::applicationLaunched(), and Server::applicationTerminated().

const AppLnkSet & ServerInterface::appLnks  )  [static]
 

Returns the current set of available applications.

Definition at line 368 of file serverinterface.cpp.

References DocumentList::appLnkSet.

Referenced by RunningAppBar::applicationLaunched(), RunningAppBar::applicationTerminated(), and RunningAppBar::received().

ServerInterface::createGUI  )  [pure virtual]
 

Implement this function to create the custom launcher UI.

Implemented in Launcher.

Referenced by Server::Server().

ServerInterface::destroyGUI  )  [pure virtual]
 

Implement this function to destroy the custom launcher UI. All resources allocated by createGUI() must be released.

Implemented in Launcher.

Referenced by Server::~Server().

void ServerInterface::dockWidget QWidget *  w,
DockArea  placement
[static]
 

Docks a top-level widget w on a side of the screen specified by placement. The widget is placed according to the order that it was docked, its sizeHint() and whether previously docked widgets are visible. The desktop area available to QWidget::showMaximized() will exclude any visible docked widgets.

For example, if a widget is docked at the bottom of the screen, its sizeHint() will define its height and it will use the full width of the screen. If a widget is then docked to the right, its sizeHint() will define its width and it will be as high as possible without covering the widget docked at the bottom.

This function is useful for reserving system areas such as taskbars and input methods that should not be covered by applications.

Definition at line 358 of file serverinterface.cpp.

References LayoutManager::addDocked().

Referenced by Launcher::createGUI().

ServerInterface::documentAdded const DocLnk doc  )  [pure virtual]
 

Add a document doc to the launcher.

See also:
documentRemoved()

Implemented in Launcher.

Referenced by DocumentList::add().

ServerInterface::documentChanged const DocLnk oldDoc,
const DocLnk newDoc
[pure virtual]
 

Change document properties of existing document oldDoc to newDoc.

Implemented in Launcher.

Referenced by DocumentList::linkChanged().

ServerInterface::documentRemoved const DocLnk doc  )  [pure virtual]
 

Remove a document doc to the launcher.

See also:
documentAdded()

Implemented in Launcher.

Referenced by DocumentList::linkChanged().

ServerInterface::documentScanningProgress int  percent  )  [pure virtual]
 

The system is scanning for documents. percent provides the percentage of the filesystems scanned. This function will always be called with percent equal to zero when scanning starts, and with percent equal to 100 when scanning is complete.

Implemented in Launcher.

Referenced by DocumentListPrivate::estimatedPercentScanned(), DocumentListPrivate::iterate(), DocumentList::reloadDocLnks(), and DocumentList::timerEvent().

bool ServerInterface::requiresApplications  )  const [pure virtual]
 

Return TRUE if the custom launcher requires the server to scan for applications.

Implemented in Launcher.

Referenced by DocumentListPrivate::DocumentListPrivate().

bool ServerInterface::requiresDocuments  )  const [pure virtual]
 

Return TRUE if the custom launcher requires the server to scan for documents.

Implemented in Launcher.

Referenced by DocumentListPrivate::DocumentListPrivate().

ServerInterface::storageChanged const QList< FileSystem > &   )  [pure virtual]
 

A filesystem has been added or removed.

Implemented in Launcher.

Referenced by Server::storageChanged().

ServerInterface::typeAdded const QString type,
const QString name,
const QPixmap &  pixmap,
const QPixmap &  bgPixmap
[pure virtual]
 

An application category type has been added, for example "Games". name is the translated name of the category. pixmap and bgPixmap are small and large icons for the new type.

Types can be added or removed at any time, for example, when a storage card containing a non-standard category is inserted or removed.

See also:
typeRemoved()

Implemented in Launcher.

Referenced by DocumentList::DiffAppLnks(), and DocumentList::reloadAppLnks().

ServerInterface::typeRemoved const QString type  )  [pure virtual]
 

An application category type has been removed.

Types can be added or removed at any time, for example, when a storage card containing a non-standard category is inserted or removed.

See also:
typeAdded()

Implemented in Launcher.

Referenced by DocumentList::DiffAppLnks(), and DocumentList::reloadAppLnks().


The documentation for this class was generated from the following files:
Generated on Sat Nov 5 17:51:37 2005 for OPIE by  doxygen 1.4.2