1cac0f67c402d107cdb10971b95719e2ff9c7c76bSteve Block/*
2cac0f67c402d107cdb10971b95719e2ff9c7c76bSteve Block    Copyright (C) 2009 Nokia Corporation and/or its subsidiary(-ies)
3cac0f67c402d107cdb10971b95719e2ff9c7c76bSteve Block
4cac0f67c402d107cdb10971b95719e2ff9c7c76bSteve Block    This library is free software; you can redistribute it and/or
5cac0f67c402d107cdb10971b95719e2ff9c7c76bSteve Block    modify it under the terms of the GNU Library General Public
6cac0f67c402d107cdb10971b95719e2ff9c7c76bSteve Block    License as published by the Free Software Foundation; either
7cac0f67c402d107cdb10971b95719e2ff9c7c76bSteve Block    version 2 of the License, or (at your option) any later version.
8cac0f67c402d107cdb10971b95719e2ff9c7c76bSteve Block
9cac0f67c402d107cdb10971b95719e2ff9c7c76bSteve Block    This library is distributed in the hope that it will be useful,
10cac0f67c402d107cdb10971b95719e2ff9c7c76bSteve Block    but WITHOUT ANY WARRANTY; without even the implied warranty of
11cac0f67c402d107cdb10971b95719e2ff9c7c76bSteve Block    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
12cac0f67c402d107cdb10971b95719e2ff9c7c76bSteve Block    Library General Public License for more details.
13cac0f67c402d107cdb10971b95719e2ff9c7c76bSteve Block
14cac0f67c402d107cdb10971b95719e2ff9c7c76bSteve Block    You should have received a copy of the GNU Library General Public License
15cac0f67c402d107cdb10971b95719e2ff9c7c76bSteve Block    along with this library; see the file COPYING.LIB.  If not, write to
16cac0f67c402d107cdb10971b95719e2ff9c7c76bSteve Block    the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
17cac0f67c402d107cdb10971b95719e2ff9c7c76bSteve Block    Boston, MA 02110-1301, USA.
18cac0f67c402d107cdb10971b95719e2ff9c7c76bSteve Block*/
19cac0f67c402d107cdb10971b95719e2ff9c7c76bSteve Block
20cac0f67c402d107cdb10971b95719e2ff9c7c76bSteve Block#ifndef PluginContainerSymbian_h
21cac0f67c402d107cdb10971b95719e2ff9c7c76bSteve Block#define PluginContainerSymbian_h
22cac0f67c402d107cdb10971b95719e2ff9c7c76bSteve Block
23cac0f67c402d107cdb10971b95719e2ff9c7c76bSteve Block#include <QWidget>
24cac0f67c402d107cdb10971b95719e2ff9c7c76bSteve Block
25dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Blockclass QGraphicsProxyWidget;
26dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block
27cac0f67c402d107cdb10971b95719e2ff9c7c76bSteve Blocknamespace WebCore {
28cac0f67c402d107cdb10971b95719e2ff9c7c76bSteve Block
29cac0f67c402d107cdb10971b95719e2ff9c7c76bSteve Block    class PluginView;
30cac0f67c402d107cdb10971b95719e2ff9c7c76bSteve Block
31cac0f67c402d107cdb10971b95719e2ff9c7c76bSteve Block    class PluginContainerSymbian : public QWidget {
32cac0f67c402d107cdb10971b95719e2ff9c7c76bSteve Block        Q_OBJECT
33cac0f67c402d107cdb10971b95719e2ff9c7c76bSteve Block    public:
34dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block        PluginContainerSymbian(PluginView*, QWidget* parent, QGraphicsProxyWidget* proxy = 0);
35cac0f67c402d107cdb10971b95719e2ff9c7c76bSteve Block        ~PluginContainerSymbian();
36cac0f67c402d107cdb10971b95719e2ff9c7c76bSteve Block
37cac0f67c402d107cdb10971b95719e2ff9c7c76bSteve Block        void requestGeometry(const QRect&, const QRegion& clip = QRegion());
38cac0f67c402d107cdb10971b95719e2ff9c7c76bSteve Block        void adjustGeometry();
39dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block        QGraphicsProxyWidget* proxy() { return m_proxy; }
40cac0f67c402d107cdb10971b95719e2ff9c7c76bSteve Block
41cac0f67c402d107cdb10971b95719e2ff9c7c76bSteve Block    protected:
42cac0f67c402d107cdb10971b95719e2ff9c7c76bSteve Block        virtual void focusInEvent(QFocusEvent*);
43cac0f67c402d107cdb10971b95719e2ff9c7c76bSteve Block        virtual void focusOutEvent(QFocusEvent*);
44cac0f67c402d107cdb10971b95719e2ff9c7c76bSteve Block    private:
45cac0f67c402d107cdb10971b95719e2ff9c7c76bSteve Block        PluginView* m_pluginView;
46dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block        QGraphicsProxyWidget* m_proxy;
47cac0f67c402d107cdb10971b95719e2ff9c7c76bSteve Block        QRect m_windowRect;
48cac0f67c402d107cdb10971b95719e2ff9c7c76bSteve Block        QRegion m_clipRegion;
49cac0f67c402d107cdb10971b95719e2ff9c7c76bSteve Block        bool m_hasPendingGeometryChange;
50cac0f67c402d107cdb10971b95719e2ff9c7c76bSteve Block    };
51cac0f67c402d107cdb10971b95719e2ff9c7c76bSteve Block}
52cac0f67c402d107cdb10971b95719e2ff9c7c76bSteve Block
53cac0f67c402d107cdb10971b95719e2ff9c7c76bSteve Block#endif // PluginContainerSymbian_h
54