/***********************************************************************
**
**   cumulusqpeapplication.h
**
**   This file is part of Cumulus
**
************************************************************************
**
**   Copyright (c):  2005 by Axel Pauli (axel@kflog.org)
**
**   This program is free software; you can redistribute it and/or modify
**   it under the terms of the GNU General Public License as published by
**   the Free Software Foundation; either version 2 of the License, or
**   (at your option) any later version.
**
**   $Id: cumulusqpeapplication.h,v 1.2 2005/02/18 19:06:33 axel Exp $
**
**   Description:
**
**   This class overwrites the buggy method qwsEventFilter from
**   QPEApplication in a simple kind. It makes always a return false,
**   so that the event is forwarded to the QT classes, which has
**   subscribed. Two problems were solved by this handling.
**
**   a) routing of hardware key events to QApplication under Opie
**   b) routing of focus key events to QApplication, which sometimes
**      have caused a deadlock
**
***********************************************************************/

#ifndef CUMULUS_QPE_APPLICATION_H
#define CUMULUS_QPE_APPLICATION_H

#include <qpe/qpeapplication.h>

class QWSEvent;

class CumulusQPEApplication : public QPEApplication
{
  Q_OBJECT

 public:

    CumulusQPEApplication( int& argc, char **argv );
    virtual ~CumulusQPEApplication();

 protected:

    // We will overwrite the buggy method qwsEventFilter of
    // QPEApplication
    virtual bool qwsEventFilter( QWSEvent *e );

    // We are forced to implement this too
    virtual void polish( QWidget * ) {};
};

#endif // CUMULUS_QPE_APPLICATION_H
