|
1 /* |
|
2 * Copyright (c) 2010 Nokia Corporation and/or its subsidiary(-ies). |
|
3 * All rights reserved. |
|
4 * This component and the accompanying materials are made available |
|
5 * under the terms of "Eclipse Public License v1.0" |
|
6 * which accompanies this distribution, and is available |
|
7 * at the URL "http://www.eclipse.org/legal/epl-v10.html". |
|
8 * |
|
9 * Initial Contributors: |
|
10 * Nokia Corporation - initial contribution. |
|
11 * |
|
12 * Contributors: |
|
13 * |
|
14 * Description: |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 #ifndef BOOKMARKSCLIENTDEFS_H |
|
20 #define BOOKMARKSCLIENTDEFS_H |
|
21 |
|
22 #define BOOKMARKSCLIENT_PRIVATE(Class) \ |
|
23 private: \ |
|
24 inline Class##Private* priv_func() { return reinterpret_cast<Class##Private*>(priv_ptr); } \ |
|
25 inline const Class##Private* priv_func() const{ return static_cast<Class##Private*>(priv_ptr);} \ |
|
26 friend class Class##Private; \ |
|
27 void* priv_ptr; |
|
28 #define BOOKMARKSCLIENT_PUBLIC(Class) \ |
|
29 public: \ |
|
30 inline Class* pub_func() { return static_cast<Class *>(pub_ptr); } \ |
|
31 inline const Class* pub_func() const { return static_cast<const Class *>(pub_ptr); } \ |
|
32 private: \ |
|
33 friend class Class; \ |
|
34 void* pub_ptr; |
|
35 |
|
36 #define BOOKMARKSCLIENT_INITIALIZE(Class) \ |
|
37 priv_ptr=new Class##Private(); \ |
|
38 Class##Private* priv=priv_func();\ |
|
39 priv->pub_ptr = this; |
|
40 #define BOOKMARKSCLIENT_PUBLICPTR(Class) Class * const pub = pub_func() |
|
41 #define BOOKMARKSCLIENT_PRIVATEPTR(Class) Class##Private* const priv=priv_func() |
|
42 // #define BOOKMARKSENGINECLIENT_EXPORT Q_DECL_EXPORT |
|
43 |
|
44 |
|
45 #ifdef BUILDING_BOOKMARK_CONTENTDLL |
|
46 #define BOOKMARKSCONTENTDLL_EXPORT Q_DECL_EXPORT |
|
47 #else |
|
48 #define BOOKMARKSCONTENTDLL_EXPORT Q_DECL_IMPORT |
|
49 #endif |
|
50 |
|
51 enum EBrowserContentErrorTypes |
|
52 { |
|
53 ErrNone, |
|
54 ErrGeneral = -2 |
|
55 }; |
|
56 #endif //BOOKMARKSCLIENTDEFS_H |