1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/toolkit/xre/nsNativeAppSupportQt.h Wed Dec 31 06:09:35 2014 +0100 1.3 @@ -0,0 +1,37 @@ 1.4 +/* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ 1.5 +/* vim: set ts=8 et sw=2 tw=80: */ 1.6 +/* This Source Code Form is subject to the terms of the Mozilla Public 1.7 + * License, v. 2.0. If a copy of the MPL was not distributed with this 1.8 + * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ 1.9 + 1.10 +#include <stdlib.h> 1.11 +#include <QObject> 1.12 +#ifdef MOZ_ENABLE_QMSYSTEM2 1.13 +#include "qmdevicemode.h" 1.14 +#include "qmdisplaystate.h" 1.15 +#include "qmactivity.h" 1.16 +#endif 1.17 +#include "nsNativeAppSupportBase.h" 1.18 +#include "nsString.h" 1.19 + 1.20 +class nsNativeAppSupportQt : public QObject, public nsNativeAppSupportBase 1.21 +{ 1.22 + Q_OBJECT 1.23 +public: 1.24 + NS_IMETHOD Start(bool* aRetVal); 1.25 + NS_IMETHOD Stop(bool* aResult); 1.26 + 1.27 +#ifdef MOZ_ENABLE_QMSYSTEM2 1.28 +public Q_SLOTS: 1.29 + void activityChanged(MeeGo::QmActivity::Activity activity); 1.30 + void deviceModeChanged(MeeGo::QmDeviceMode::DeviceMode mode); 1.31 + void displayStateChanged(MeeGo::QmDisplayState::DisplayState state); 1.32 + void RefreshStates(); 1.33 + 1.34 +private: 1.35 + MeeGo::QmDeviceMode mDeviceMode; 1.36 + MeeGo::QmDisplayState mDisplayState; 1.37 + MeeGo::QmActivity mActivity; 1.38 +#endif 1.39 +}; 1.40 +