Bug 788829 - Call SetSizeConstraints even if a popup is not open. r=enndeakin
[gecko.git] / toolkit / xre / nsNativeAppSupportQt.h
blobe8320fa7bc12f9744b7ea89ecc1f99f48b8d9149
1 /* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
2 /* vim: set ts=8 et sw=2 tw=80: */
3 /* This Source Code Form is subject to the terms of the Mozilla Public
4 * License, v. 2.0. If a copy of the MPL was not distributed with this
5 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
7 #include <stdlib.h>
8 #include <QObject>
9 #ifdef MOZ_ENABLE_QMSYSTEM2
10 #include "qmdevicemode.h"
11 #include "qmdisplaystate.h"
12 #include "qmactivity.h"
13 #endif
14 #include "nsNativeAppSupportBase.h"
15 #include "nsString.h"
17 #ifdef MOZ_ENABLE_LIBCONIC
18 #include <glib-object.h>
19 #endif
21 #if (MOZ_PLATFORM_MAEMO == 5)
22 #include <libosso.h>
23 #endif
25 class nsNativeAppSupportQt : public QObject, public nsNativeAppSupportBase
27 Q_OBJECT
28 public:
29 NS_IMETHOD Start(bool* aRetVal);
30 NS_IMETHOD Stop(bool* aResult);
31 #if (MOZ_PLATFORM_MAEMO == 5)
32 // Osso context must be initialized for maemo5 otherwise we will be killed in ~20 seconds
33 osso_context_t *m_osso_context;
34 #endif
35 #ifdef MOZ_ENABLE_QMSYSTEM2
36 public Q_SLOTS:
37 void activityChanged(MeeGo::QmActivity::Activity activity);
38 void deviceModeChanged(MeeGo::QmDeviceMode::DeviceMode mode);
39 void displayStateChanged(MeeGo::QmDisplayState::DisplayState state);
40 void RefreshStates();
42 private:
43 MeeGo::QmDeviceMode mDeviceMode;
44 MeeGo::QmDisplayState mDisplayState;
45 MeeGo::QmActivity mActivity;
46 #endif