Changeset 835
- Timestamp:
- Mar 18, 2011, 2:10:26 AM (14 years ago)
- Location:
- trunk/src
- Files:
-
- 4 added
- 3 edited
- 1 copied
- 5 moved
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/3rdparty/os2/xsystray/apilib/xsystray.c
r834 r835 1 1 2 2 /* 3 *@@sourcefile xsystray _api.c:3 *@@sourcefile xsystray.c: 4 4 * Extended system tray widget for XCenter/eCenter. 5 5 * … … 30 30 #include <os2.h> 31 31 32 # include "xsystray_api.h"32 #define XSTAPI_IMPL 33 33 #include "xsystray.h" 34 35 #include "w_xsystray.h" 34 36 35 37 #include <string.h> -
trunk/src/3rdparty/os2/xsystray/apilib/xsystray.h
r834 r835 1 1 2 2 /* 3 *@@sourcefile xsystray _api.h:3 *@@sourcefile xsystray.h: 4 4 * Extended system tray widget for XCenter/eCenter. 5 5 * … … 31 31 #if __cplusplus 32 32 extern "C" { 33 #endif 34 35 #ifdef XSTAPI_IMPL 36 #define XSTAPI __declspec(dllexport) EXPENTRY 37 #else 38 #define XSTAPI EXPENTRY 33 39 #endif 34 40 … … 75 81 } XSTWHEELMSG, *PXSTWHEELMSG; 76 82 77 BOOL xstQuerySysTrayVersion(PULONG pulMajor, PULONG pulMinor, PULONG pulRevision); 78 BOOL xstAddSysTrayIcon(HWND hwnd, USHORT usId, HPOINTER hIcon, PCSZ pcszToolTip, 79 ULONG ulMsgId, ULONG ulFlags); 80 BOOL xstReplaceSysTrayIcon(HWND hwnd, USHORT usId, HPOINTER hIcon); 81 BOOL xstRemoveSysTrayIcon(HWND hwnd, USHORT usId); 82 BOOL xstSetSysTrayIconToolTip(HWND hwnd, USHORT usId, PCSZ pcszToolTip); 83 BOOL xstShowSysTrayIconBalloon(HWND hwnd, USHORT usId, PCSZ pcszTitle, 84 PCSZ pcszText, ULONG ulFlags, ULONG ulTimeout); 85 BOOL xstHideSysTrayIconBalloon(HWND hwnd, USHORT usId); 83 BOOL XSTAPI xstQuerySysTrayVersion(PULONG pulMajor, PULONG pulMinor, 84 PULONG pulRevision); 85 86 BOOL XSTAPI xstAddSysTrayIcon(HWND hwnd, USHORT usId, HPOINTER hIcon, 87 PCSZ pcszToolTip, ULONG ulMsgId, ULONG ulFlags); 88 89 BOOL XSTAPI xstReplaceSysTrayIcon(HWND hwnd, USHORT usId, HPOINTER hIcon); 86 90 87 BOOL xstQuerySysTrayIconRect(HWND hwnd, USHORT usId, PRECTL prclRect);91 BOOL XSTAPI xstRemoveSysTrayIcon(HWND hwnd, USHORT usId); 88 92 89 ULONG xstGetSysTrayCreatedMsgId();93 BOOL XSTAPI xstSetSysTrayIconToolTip(HWND hwnd, USHORT usId, PCSZ pcszToolTip); 90 94 91 ULONG xstGetSysTrayMaxTextLen(); 95 BOOL XSTAPI xstShowSysTrayIconBalloon(HWND hwnd, USHORT usId, PCSZ pcszTitle, 96 PCSZ pcszText, ULONG ulFlags, 97 ULONG ulTimeout); 98 99 BOOL XSTAPI xstHideSysTrayIconBalloon(HWND hwnd, USHORT usId); 100 101 BOOL XSTAPI xstQuerySysTrayIconRect(HWND hwnd, USHORT usId, PRECTL prclRect); 102 103 ULONG XSTAPI xstGetSysTrayCreatedMsgId(); 104 105 ULONG XSTAPI xstGetSysTrayMaxTextLen(); 92 106 93 107 #if __cplusplus -
trunk/src/3rdparty/os2/xsystray/plugin/plugin.pro
r834 r835 4 4 QT = 5 5 6 SOURCES = xsystray.c 6 TARGET = xsystray 7 7 8 DEF_FILE = xsystray.def 8 SOURCES = w_xsystray.c 9 10 DEF_FILE = w_xsystray.def 11 12 INCLUDEPATH += .. ../apilib 9 13 10 14 DESTDIR = $$[QT_INSTALL_PLUGINS]/xcenter -
trunk/src/3rdparty/os2/xsystray/plugin/w_xsystray.c
r834 r835 1 1 2 2 /* 3 *@@sourcefile xsystray.c:3 *@@sourcefile w_xsystray.c: 4 4 * Extended system tray widget for XCenter/eCenter. 5 5 * … … 77 77 #include "shared\center.h" // public XCenter interfaces 78 78 79 #include " xsystray.h"79 #include "w_xsystray.h" 80 80 81 81 #if defined(__IBMC__) || defined(__IBMCPP__) -
trunk/src/3rdparty/os2/xsystray/plugin/w_xsystray.h
r834 r835 1 1 2 2 /* 3 *@@sourcefile xsystray.h:3 *@@sourcefile w_xsystray.h: 4 4 * Extended system tray widget for XCenter/eCenter. 5 5 * … … 22 22 #define XSYSTRAY_HEADER_INCLUDED 23 23 24 #include "xsystray _api.h"24 #include "xsystray.h" 25 25 26 26 #include <sys/builtin.h> // atomics … … 115 115 * posted to clients (windows associated with system tray icons) about 116 116 * icon events. This structure unions all public notification code 117 * dependent structures defined in xsystray _api.h (starting with XST*).117 * dependent structures defined in xsystray.h (starting with XST*). 118 118 * 119 119 * All messages posted to the client have an ID corresponding to the … … 137 137 * 138 138 * NOTE: When you change the size of this structure, you may also need to 139 * change SERVER_MEMORYPOOL_SIZE value in xsystray.c (see the comments139 * change SERVER_MEMORYPOOL_SIZE value in w_xsystray.c (see the comments 140 140 * there for details). 141 141 */ -
trunk/src/3rdparty/os2/xsystray/xsystray.pro
r252 r835 1 TEMPLATE = lib 1 TEMPLATE = subdirs 2 SUBDIRS = plugin apilib 2 3 3 CONFIG += dll4 QT =5 6 SOURCES = xsystray.c7 8 DEF_FILE = xsystray.def9 10 DESTDIR = $$[QT_INSTALL_PLUGINS]/xcenter -
trunk/src/gui/util/qsystemtrayicon_pm.cpp
r659 r835 48 48 #include "qapplication.h" 49 49 #include "qdesktopwidget.h" 50 #include "qlibrary.h" 50 51 #include "qt_os2.h" 51 52 52 #include "xsystray_api.h" 53 // for dynamic linking to xsystray DLL 54 #define xstQuerySysTrayVersion (*_xstQuerySysTrayVersion) 55 #define xstAddSysTrayIcon (*_xstAddSysTrayIcon) 56 #define xstReplaceSysTrayIcon (*_xstReplaceSysTrayIcon) 57 #define xstRemoveSysTrayIcon (*_xstRemoveSysTrayIcon) 58 #define xstSetSysTrayIconToolTip (*_xstSetSysTrayIconToolTip) 59 #define xstQuerySysTrayIconRect (*_xstQuerySysTrayIconRect) 60 #define xstGetSysTrayCreatedMsgId (*_xstGetSysTrayCreatedMsgId) 61 #define xstGetSysTrayMaxTextLen (*_xstGetSysTrayMaxTextLen) 62 63 #include "xsystray.h" 53 64 54 65 QT_BEGIN_NAMESPACE … … 56 67 #define WM_XST_MYNOTIFY (WM_USER + 1000) 57 68 58 static ULONG WM_XST_CREATED = xstGetSysTrayCreatedMsgId();59 static ULONG MaxTextLen = xstGetSysTrayMaxTextLen();69 static ULONG WM_XST_CREATED = 0; 70 static ULONG MaxTextLen = 0; 60 71 61 72 class QSystemTrayIconSys : QWidget … … 307 318 bool QSystemTrayIconPrivate::isSystemTrayAvailable_sys() 308 319 { 320 static bool tried = false; 321 if (!tried) { 322 tried = true; 323 324 // link to the xsystray DLL at runtime 325 QLibrary xsystray(QLatin1String("xsystray")); 326 327 #define R(f) if ((*((void **)&_##f) = xsystray.resolve(#f)) == NULL) return false 328 329 R(xstQuerySysTrayVersion); 330 R(xstAddSysTrayIcon); 331 R(xstReplaceSysTrayIcon); 332 R(xstRemoveSysTrayIcon); 333 R(xstSetSysTrayIconToolTip); 334 R(xstQuerySysTrayIconRect); 335 R(xstGetSysTrayCreatedMsgId); 336 R(xstGetSysTrayMaxTextLen); 337 338 #undef R 339 340 // initialize some constants 341 WM_XST_CREATED = xstGetSysTrayCreatedMsgId(); 342 MaxTextLen = xstGetSysTrayMaxTextLen(); 343 } 344 309 345 return xstQuerySysTrayVersion(0, 0, 0); 310 346 } -
trunk/src/gui/util/util.pri
r769 r835 31 31 os2 { 32 32 SOURCES += \ 33 util/qsystemtrayicon_pm.cpp \ 34 ../3rdparty/os2/xsystray/xsystray_api.c 33 util/qsystemtrayicon_pm.cpp 34 # @todo this should be required to present extenrally in the 35 # environment when it gets moved to XWP (see #99 for details) 35 36 INCLUDEPATH += \ 36 ../3rdparty/os2/xsystray 37 ../3rdparty/os2/xsystray/apilib 37 38 } 38 39
Note:
See TracChangeset
for help on using the changeset viewer.