Wed, 31 Dec 2014 06:09:35 +0100
Cloned upstream origin tor-browser at tor-browser-31.3.0esr-4.5-1-build1
revision ID fc1c9ff7c1b2defdbc039f12214767608f46423f for hacking purpose.
michael@0 | 1 | /* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ |
michael@0 | 2 | /* This Source Code Form is subject to the terms of the Mozilla Public |
michael@0 | 3 | * License, v. 2.0. If a copy of the MPL was not distributed with this file, |
michael@0 | 4 | * You can obtain one at http://mozilla.org/MPL/2.0/. */ |
michael@0 | 5 | |
michael@0 | 6 | #ifndef mozilla_dom_mobilemessage_MobileMessageThread_h |
michael@0 | 7 | #define mozilla_dom_mobilemessage_MobileMessageThread_h |
michael@0 | 8 | |
michael@0 | 9 | #include "mozilla/Attributes.h" |
michael@0 | 10 | #include "mozilla/dom/mobilemessage/SmsTypes.h" |
michael@0 | 11 | #include "nsIDOMMozMobileMessageThread.h" |
michael@0 | 12 | #include "nsString.h" |
michael@0 | 13 | |
michael@0 | 14 | namespace mozilla { |
michael@0 | 15 | namespace dom { |
michael@0 | 16 | |
michael@0 | 17 | class MobileMessageThread MOZ_FINAL : public nsIDOMMozMobileMessageThread |
michael@0 | 18 | { |
michael@0 | 19 | private: |
michael@0 | 20 | typedef mobilemessage::ThreadData ThreadData; |
michael@0 | 21 | |
michael@0 | 22 | public: |
michael@0 | 23 | NS_DECL_ISUPPORTS |
michael@0 | 24 | NS_DECL_NSIDOMMOZMOBILEMESSAGETHREAD |
michael@0 | 25 | |
michael@0 | 26 | MobileMessageThread(uint64_t aId, |
michael@0 | 27 | const nsTArray<nsString>& aParticipants, |
michael@0 | 28 | uint64_t aTimestamp, |
michael@0 | 29 | const nsString& aLastMessageSubject, |
michael@0 | 30 | const nsString& aBody, |
michael@0 | 31 | uint64_t aUnreadCount, |
michael@0 | 32 | mobilemessage::MessageType aLastMessageType); |
michael@0 | 33 | |
michael@0 | 34 | MobileMessageThread(const ThreadData& aData); |
michael@0 | 35 | |
michael@0 | 36 | static nsresult Create(uint64_t aId, |
michael@0 | 37 | const JS::Value& aParticipants, |
michael@0 | 38 | uint64_t aTimestamp, |
michael@0 | 39 | const nsAString& aLastMessageSubject, |
michael@0 | 40 | const nsAString& aBody, |
michael@0 | 41 | uint64_t aUnreadCount, |
michael@0 | 42 | const nsAString& aLastMessageType, |
michael@0 | 43 | JSContext* aCx, |
michael@0 | 44 | nsIDOMMozMobileMessageThread** aThread); |
michael@0 | 45 | |
michael@0 | 46 | const ThreadData& GetData() const { return mData; } |
michael@0 | 47 | |
michael@0 | 48 | private: |
michael@0 | 49 | // Don't try to use the default constructor. |
michael@0 | 50 | MobileMessageThread() MOZ_DELETE; |
michael@0 | 51 | |
michael@0 | 52 | ThreadData mData; |
michael@0 | 53 | }; |
michael@0 | 54 | |
michael@0 | 55 | } // namespace dom |
michael@0 | 56 | } // namespace mozilla |
michael@0 | 57 | |
michael@0 | 58 | #endif // mozilla_dom_mobilemessage_MobileMessageThread_h |