Home · All Classes · Grouped Classes · Annotated · Functions

ScreenClick Class Reference

The ScreenClick class enables an audible clicking sound whenever the stylus is used. More...

    #include <ScreenClick>

Inherits QObject and QtopiaServerApplication::QWSEventFilter.

Public Functions

Protected Functions

Additional Inherited Members


Detailed Description

The ScreenClick class enables an audible clicking sound whenever the stylus is used.

The ScreenClick class is not a true task. Instead, a real task should derive from the ScreenClick baseclass and implement the ScreenClick::screenClick() virtual method.

For example, an implementation may look like this:

    class MyScreenClick : public ScreenClick
    {
    protected:
        virtual void screenClick(bool pressed)
        {
            // Make click noise
        }
    };
    QTOPIA_TASK(MyScreenClick, MyScreenClick);

Screen clicking will only occur when the Trolltech/Sound/System/Touch configuration variable is true, otherwise ScreenClick::screenClick() will not be called. Creating this class automatically enables the "AudibleScreenClick" QtopiaFeature.

See also KeyClick.


Member Function Documentation

ScreenClick::ScreenClick ()

Construct a new ScreenClick instance.

ScreenClick::~ScreenClick ()   [virtual]

Destroys the ScreenClick instance.

void ScreenClick::screenClick ( bool pressed )   [pure virtual protected]

Called whenever the user taps or releases the screen. pressed will be true when the user taps the screen, and false when they release.


Copyright © 2007 Trolltech Trademarks
Qtopia 4.2.5