Changeset 21548 for trunk/include/os2wrap2.h
- Timestamp:
- Jan 8, 2011, 1:51:04 PM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/include/os2wrap2.h
r21547 r21548 1560 1560 #define ATOM os2_ATOM 1561 1561 #define os2_MAKEINTATOM (x) ((PCH) os2_MAKEULONG (x, 0xffff)) 1562 #define os2_BM_CLICK 0x0120 1563 #define os2_BM_QUERYCHECKINDEX 0x0121 1564 #define os2_BM_QUERYHILITE 0x0122 1565 #define os2_BM_SETHILITE 0x0123 1566 #define os2_BM_QUERYCHECK 0x0124 1567 #define os2_BM_SETCHECK 0x0125 1568 #define os2_BM_SETDEFAULT 0x0126 1562 1569 #define _BTNCDATA os2__BTNCDATA 1563 1570 #define BTNCDATA os2_BTNCDATA … … 1648 1655 #define MB2INFO os2_MB2INFO 1649 1656 #define PMB2INFO os2_PMB2INFO 1650 #define os2_WinCheckButton (hwndDlg,id,usCheckState) \1651 ((os2_ULONG)WinSendDlgItemMsg (hwndDlg, id, BM_SETCHECK, \1652 os2_MPFROMSHORT (usCheckState), (os2_MPARAM)NULL))1653 #define os2_WinIsControlEnabled (hwndDlg,id) \1654 ((os2_BOOL)WinIsWindowEnabled (WinWindowFromID (hwndDlg, id)))1655 #define os2_WinQueryButtonCheckstate (hwndDlg,id) \1656 ((os2_ULONG)WinSendDlgItemMsg (hwndDlg, id, BM_QUERYCHECK, \1657 (os2_MPARAM)NULL, (os2_MPARAM)NULL))1658 1657 #define _DLGTITEM os2__DLGTITEM 1659 1658 #define DLGTITEM os2_DLGTITEM … … 1732 1731 #define os2_CHARMSG (pmsg) ((os2_PCHRMSG)((os2_PBYTE)pmsg + sizeof (os2_ULONG))) 1733 1732 #define os2_MOUSEMSG (pmsg) ((os2_PMSEMSG)((os2_PBYTE)pmsg + sizeof (os2_ULONG))) 1733 #define os2_LM_QUERYITEMCOUNT 0x0160 1734 #define os2_LM_INSERTITEM 0x0161 1735 #define os2_LM_SETTOPINDEX 0x0162 1736 #define os2_LM_DELETEITEM 0x0163 1737 #define os2_LM_SELECTITEM 0x0164 1738 #define os2_LM_QUERYSELECTION 0x0165 1739 #define os2_LM_SETITEMTEXT 0x0166 1740 #define os2_LM_QUERYITEMTEXTLENGTH 0x0167 1741 #define os2_LM_QUERYITEMTEXT 0x0168 1742 #define os2_LM_SETITEMHANDLE 0x0169 1743 #define os2_LM_QUERYITEMHANDLE 0x016a 1744 #define os2_LM_SEARCHSTRING 0x016b 1745 #define os2_LM_SETITEMHEIGHT 0x016c 1746 #define os2_LM_QUERYTOPINDEX 0x016d 1747 #define os2_LM_DELETEALL 0x016e 1748 #define os2_LM_INSERTMULTITEMS 0x016f 1749 #define os2_LM_SETITEMWIDTH 0x0660 /* ? */ 1734 1750 #define _LBOXINFO os2__LBOXINFO 1735 1751 #define LBOXINFO os2_LBOXINFO 1736 1752 #define PLBOXINFO os2_PLBOXINFO 1737 #define os2_WinDeleteLboxItem (hwndLbox,index) \1738 ((os2_LONG)WinSendMsg (hwndLbox, LM_DELETEITEM, os2_MPFROMLONG (index), \1739 (os2_MPARAM)NULL))1740 #define os2_WinInsertLboxItem (hwndLbox,index,psz) \1741 ((os2_LONG)WinSendMsg (hwndLbox, LM_INSERTITEM, os2_MPFROMLONG(index), \1742 os2_MPFROMP (psz)))1743 #define os2_WinQueryLboxCount (hwndLbox) \1744 ((os2_LONG)WinSendMsg (hwndLbox, LM_QUERYITEMCOUNT, (os2_MPARAM)NULL, \1745 (os2_MPARAM)NULL))1746 #define os2_WinQueryLboxItemText (hwndLbox,index,psz,cchMax) \1747 ((os2_LONG)WinSendMsg (hwndLbox, LM_QUERYITEMTEXT, \1748 os2_MPFROM2SHORT((index), (cchMax)), os2_MPFROMP (psz)))1749 #define os2_WinQueryLboxItemTextLength (hwndLbox,index) \1750 ((os2_SHORT)WinSendMsg (hwndLbox, LM_QUERYITEMTEXTLENGTH, \1751 os2_MPFROMSHORT (index), (os2_MPARAM)NULL))1752 #define os2_WinQueryLboxSelectedItem (hwndLbox) \1753 ((os2_LONG)WinSendMsg (hwndLbox, LM_QUERYSELECTION, os2_MPFROMLONG (LIT_FIRST), \1754 (os2_MPARAM)NULL))1755 #define os2_WinSetLboxItemText (hwndLbox,index,psz) \1756 ((os2_BOOL)WinSendMsg (hwndLbox, LM_SETITEMTEXT, \1757 os2_MPFROMLONG (index), os2_MPFROMP (psz)))1758 1753 #define os2_MIA_NODISMISS 0x0020 1759 1754 #define os2_MIA_FRAMED 0x1000 … … 1761 1756 #define os2_MIA_DISABLED 0x4000 1762 1757 #define os2_MIA_HILITED 0x8000 1758 #define os2_MM_INSERTITEM 0x0180 1759 #define os2_MM_DELETEITEM 0x0181 1760 #define os2_MM_QUERYITEM 0x0182 1761 #define os2_MM_SETITEM 0x0183 1762 #define os2_MM_QUERYITEMCOUNT 0x0184 1763 #define os2_MM_STARTMENUMODE 0x0185 1764 #define os2_MM_ENDMENUMODE 0x0186 1765 #define os2_MM_REMOVEITEM 0x0188 1766 #define os2_MM_SELECTITEM 0x0189 1767 #define os2_MM_QUERYSELITEMID 0x018a 1768 #define os2_MM_QUERYITEMTEXT 0x018b 1769 #define os2_MM_QUERYITEMTEXTLENGTH 0x018c 1770 #define os2_MM_SETITEMHANDLE 0x018d 1771 #define os2_MM_SETITEMTEXT 0x018e 1772 #define os2_MM_ITEMPOSITIONFROMID 0x018f 1773 #define os2_MM_ITEMIDFROMPOSITION 0x0190 1774 #define os2_MM_QUERYITEMATTR 0x0191 1775 #define os2_MM_SETITEMATTR 0x0192 1776 #define os2_MM_ISITEMVALID 0x0193 1777 #define os2_MM_QUERYITEMRECT 0x0194 1778 #define os2_MM_QUERYDEFAULTITEMID 0x0431 1779 #define os2_MM_SETDEFAULTITEMID 0x0432 1763 1780 #define _MENUITEM os2__MENUITEM 1764 1781 #define MENUITEM os2_MENUITEM … … 1772 1789 #define OWNERITEM os2_OWNERITEM 1773 1790 #define POWNERITEM os2_POWNERITEM 1774 #define os2_WinCheckMenuItem (hwndMenu,id,fcheck) \1775 ((os2_BOOL)WinSendMsg (hwndMenu, MM_SETITEMATTR, \1776 os2_MPFROM2SHORT (id, TRUE), \1777 os2_MPFROM2SHORT (os2_MIA_CHECKED, \1778 ((os2_USHORT)(fcheck) ? os2_MIA_CHECKED : 0))))1779 #define os2_WinEnableMenuItem (hwndMenu,id,fEnable) \1780 ((os2_BOOL)WinSendMsg (hwndMenu, MM_SETITEMATTR, os2_MPFROM2SHORT (id, TRUE), \1781 os2_MPFROM2SHORT (os2_MIA_DISABLED, \1782 ((os2_USHORT)(fEnable) ? 0 : os2_MIA_DISABLED))))1783 #define os2_WinIsMenuItemChecked (hwndMenu,id) \1784 ((os2_BOOL)WinSendMsg (hwndMenu, MM_QUERYITEMATTR, \1785 os2_MPFROM2SHORT (id, TRUE), \1786 os2_MPFROMLONG (os2_MIA_CHECKED)))1787 #define os2_WinIsMenuItemEnabled (hwndMenu,id) \1788 (!(os2_BOOL)WinSendMsg (hwndMenu, MM_QUERYITEMATTR, \1789 os2_MPFROM2SHORT (id, TRUE), \1790 os2_MPFROMLONG (os2_MIA_DISABLED)))1791 #define os2_WinIsMenuItemValid (hwndMenu,id) \1792 ((os2_BOOL)WinSendMsg (hwndMenu, MM_ISITEMVALID, \1793 os2_MPFROM2SHORT (id, TRUE), os2_MPFROMLONG (FALSE)))1794 #define os2_WinSetMenuItemText (hwndMenu,id,psz) \1795 ((os2_BOOL)WinSendMsg (hwndMenu, MM_SETITEMTEXT, \1796 os2_MPFROMLONG (id), os2_MPFROMP (psz)))1797 1791 #define os2_QS_KEY 0x0001 1798 1792 #define os2_QS_MOUSEBUTTON 0x0002 … … 1950 1944 #define MLE_SEARCHDATA os2_MLE_SEARCHDATA 1951 1945 #define PMLE_SEARCHDATA os2_PMLE_SEARCHDATA 1946 #define os2_BM_ERROR (-1) 1947 #define os2_BM_DEFAULT 0 1948 #define os2_BM_OR 1 1949 #define os2_BM_OVERPAINT 2 1950 #define os2_BM_LEAVEALONE 5 1951 #define os2_BM_XOR 4 1952 #define os2_BM_AND 6 1953 #define os2_BM_SUBTRACT 7 1954 #define os2_BM_MASKSRCNOT 8 1955 #define os2_BM_ZERO 9 1956 #define os2_BM_NOTMERGESRC 10 1957 #define os2_BM_NOTXORSRC 11 1958 #define os2_BM_INVERT 12 1959 #define os2_BM_MERGESRCNOT 13 1960 #define os2_BM_NOTCOPYSRC 14 1961 #define os2_BM_MERGENOTSRC 15 1962 #define os2_BM_NOTMASKSRC 16 1963 #define os2_BM_ONE 17 1964 #define os2_BM_SRCTRANSPARENT 18 1965 #define os2_BM_DESTTRANSPARENT 19 1952 1966 #define os2_TA_NORMAL_HORIZ 0x0001 1953 1967 #define os2_TA_LEFT 0x0002 … … 2484 2498 #define os2_OBJ_LOCATION 0x01000000 2485 2499 #define os2_OBJ_FORK 0x02000000 2486 #define os2_DosAllocMem (a, b, c) DosAllocMemEx((a),(b),(c) | os2_OBJ_FORK)2487 #define os2_DosAllocSharedMem (a,b,c,d) DosAllocSharedMemEx((a),(b),(c),(d) | os2_OBJ_FORK)2488 2500 2489 2501 /* include the main OS/2 API wrapper */ … … 4033 4045 #undef ATOM 4034 4046 #undef MAKEINTATOM 4047 #undef BM_CLICK 4048 #undef BM_QUERYCHECKINDEX 4049 #undef BM_QUERYHILITE 4050 #undef BM_SETHILITE 4051 #undef BM_QUERYCHECK 4052 #undef BM_SETCHECK 4053 #undef BM_SETDEFAULT 4035 4054 #undef _BTNCDATA 4036 4055 #undef BTNCDATA … … 4120 4139 #undef PMB2INFO 4121 4140 #undef WinCheckButton 4141 #define WinCheckButton(hwndDlg,id,usCheckState) \ 4142 ((os2_ULONG)WinSendDlgItemMsg (hwndDlg, id, os2_BM_SETCHECK, \ 4143 os2_MPFROMSHORT (usCheckState), (os2_MPARAM)NULL)) 4122 4144 #undef WinIsControlEnabled 4145 #define WinIsControlEnabled(hwndDlg,id) \ 4146 ((os2_BOOL)WinIsWindowEnabled (WinWindowFromID (hwndDlg, id))) 4123 4147 #undef WinQueryButtonCheckstate 4148 #define WinQueryButtonCheckstate(hwndDlg,id) \ 4149 ((os2_ULONG)WinSendDlgItemMsg (hwndDlg, id, os2_BM_QUERYCHECK, \ 4150 (os2_MPARAM)NULL, (os2_MPARAM)NULL)) 4124 4151 #undef _DLGTITEM 4125 4152 #undef DLGTITEM … … 4198 4225 #undef CHARMSG 4199 4226 #undef MOUSEMSG 4227 #undef LM_QUERYITEMCOUNT 4228 #undef LM_INSERTITEM 4229 #undef LM_SETTOPINDEX 4230 #undef LM_DELETEITEM 4231 #undef LM_SELECTITEM 4232 #undef LM_QUERYSELECTION 4233 #undef LM_SETITEMTEXT 4234 #undef LM_QUERYITEMTEXTLENGTH 4235 #undef LM_QUERYITEMTEXT 4236 #undef LM_SETITEMHANDLE 4237 #undef LM_QUERYITEMHANDLE 4238 #undef LM_SEARCHSTRING 4239 #undef LM_SETITEMHEIGHT 4240 #undef LM_QUERYTOPINDEX 4241 #undef LM_DELETEALL 4242 #undef LM_INSERTMULTITEMS 4243 #undef LM_SETITEMWIDTH 4200 4244 #undef _LBOXINFO 4201 4245 #undef LBOXINFO 4202 4246 #undef PLBOXINFO 4203 4247 #undef WinDeleteLboxItem 4248 #define WinDeleteLboxItem(hwndLbox,index) \ 4249 ((os2_LONG)WinSendMsg (hwndLbox, os2_LM_DELETEITEM, os2_MPFROMLONG (index), \ 4250 (os2_MPARAM)NULL)) 4204 4251 #undef WinInsertLboxItem 4252 #define WinInsertLboxItem(hwndLbox,index,psz) \ 4253 ((os2_LONG)WinSendMsg (hwndLbox, os2_LM_INSERTITEM, os2_MPFROMLONG(index), \ 4254 os2_MPFROMP (psz))) 4205 4255 #undef WinQueryLboxCount 4256 #define WinQueryLboxCount(hwndLbox) \ 4257 ((os2_LONG)WinSendMsg (hwndLbox, os2_LM_QUERYITEMCOUNT, (os2_MPARAM)NULL, \ 4258 (os2_MPARAM)NULL)) 4206 4259 #undef WinQueryLboxItemText 4260 #define WinQueryLboxItemText(hwndLbox,index,psz,cchMax) \ 4261 ((os2_LONG)WinSendMsg (hwndLbox, os2_LM_QUERYITEMTEXT, \ 4262 os2_MPFROM2SHORT((index), (cchMax)), os2_MPFROMP (psz))) 4207 4263 #undef WinQueryLboxItemTextLength 4264 #define WinQueryLboxItemTextLength(hwndLbox,index) \ 4265 ((os2_SHORT)WinSendMsg (hwndLbox, os2_LM_QUERYITEMTEXTLENGTH, \ 4266 os2_MPFROMSHORT (index), (os2_MPARAM)NULL)) 4208 4267 #undef WinQueryLboxSelectedItem 4268 #define WinQueryLboxSelectedItem(hwndLbox) \ 4269 ((os2_LONG)WinSendMsg (hwndLbox, os2_LM_QUERYSELECTION, os2_MPFROMLONG (LIT_FIRST), \ 4270 (os2_MPARAM)NULL)) 4209 4271 #undef WinSetLboxItemText 4272 #define WinSetLboxItemText(hwndLbox,index,psz) \ 4273 ((os2_BOOL)WinSendMsg (hwndLbox, os2_LM_SETITEMTEXT, \ 4274 os2_MPFROMLONG (index), os2_MPFROMP (psz))) 4210 4275 #undef MIA_NODISMISS 4211 4276 #undef MIA_FRAMED … … 4213 4278 #undef MIA_DISABLED 4214 4279 #undef MIA_HILITED 4280 #undef MM_INSERTITEM 4281 #undef MM_DELETEITEM 4282 #undef MM_QUERYITEM 4283 #undef MM_SETITEM 4284 #undef MM_QUERYITEMCOUNT 4285 #undef MM_STARTMENUMODE 4286 #undef MM_ENDMENUMODE 4287 #undef MM_REMOVEITEM 4288 #undef MM_SELECTITEM 4289 #undef MM_QUERYSELITEMID 4290 #undef MM_QUERYITEMTEXT 4291 #undef MM_QUERYITEMTEXTLENGTH 4292 #undef MM_SETITEMHANDLE 4293 #undef MM_SETITEMTEXT 4294 #undef MM_ITEMPOSITIONFROMID 4295 #undef MM_ITEMIDFROMPOSITION 4296 #undef MM_QUERYITEMATTR 4297 #undef MM_SETITEMATTR 4298 #undef MM_ISITEMVALID 4299 #undef MM_QUERYITEMRECT 4300 #undef MM_QUERYDEFAULTITEMID 4301 #undef MM_SETDEFAULTITEMID 4215 4302 #undef _MENUITEM 4216 4303 #undef MENUITEM … … 4225 4312 #undef POWNERITEM 4226 4313 #undef WinCheckMenuItem 4314 #define WinCheckMenuItem(hwndMenu,id,fcheck) \ 4315 ((os2_BOOL)WinSendMsg (hwndMenu, os2_MM_SETITEMATTR, \ 4316 os2_MPFROM2SHORT (id, TRUE), \ 4317 os2_MPFROM2SHORT (os2_MIA_CHECKED, \ 4318 ((os2_USHORT)(fcheck) ? os2_MIA_CHECKED : 0)))) 4227 4319 #undef WinEnableMenuItem 4320 #define WinEnableMenuItem(hwndMenu,id,fEnable) \ 4321 ((os2_BOOL)WinSendMsg (hwndMenu, os2_MM_SETITEMATTR, os2_MPFROM2SHORT (id, TRUE), \ 4322 os2_MPFROM2SHORT (os2_MIA_DISABLED, \ 4323 ((os2_USHORT)(fEnable) ? 0 : os2_MIA_DISABLED)))) 4228 4324 #undef WinIsMenuItemChecked 4325 #define WinIsMenuItemChecked(hwndMenu,id) \ 4326 ((os2_BOOL)WinSendMsg (hwndMenu, os2_MM_QUERYITEMATTR, \ 4327 os2_MPFROM2SHORT (id, TRUE), \ 4328 os2_MPFROMLONG (os2_MIA_CHECKED))) 4229 4329 #undef WinIsMenuItemEnabled 4330 #define WinIsMenuItemEnabled(hwndMenu,id) \ 4331 (!(os2_BOOL)WinSendMsg (hwndMenu, os2_MM_QUERYITEMATTR, \ 4332 os2_MPFROM2SHORT (id, TRUE), \ 4333 os2_MPFROMLONG (os2_MIA_DISABLED))) 4230 4334 #undef WinIsMenuItemValid 4335 #define WinIsMenuItemValid(hwndMenu,id) \ 4336 ((os2_BOOL)WinSendMsg (hwndMenu, os2_MM_ISITEMVALID, \ 4337 os2_MPFROM2SHORT (id, TRUE), os2_MPFROMLONG (FALSE))) 4231 4338 #undef WinSetMenuItemText 4339 #define WinSetMenuItemText(hwndMenu,id,psz) \ 4340 ((os2_BOOL)WinSendMsg (hwndMenu, os2_MM_SETITEMTEXT, \ 4341 os2_MPFROMLONG (id), os2_MPFROMP (psz))) 4232 4342 #undef QS_KEY 4233 4343 #undef QS_MOUSEBUTTON … … 4385 4495 #undef MLE_SEARCHDATA 4386 4496 #undef PMLE_SEARCHDATA 4497 #undef BM_ERROR 4498 #undef BM_DEFAULT 4499 #undef BM_OR 4500 #undef BM_OVERPAINT 4501 #undef BM_LEAVEALONE 4502 #undef BM_XOR 4503 #undef BM_AND 4504 #undef BM_SUBTRACT 4505 #undef BM_MASKSRCNOT 4506 #undef BM_ZERO 4507 #undef BM_NOTMERGESRC 4508 #undef BM_NOTXORSRC 4509 #undef BM_INVERT 4510 #undef BM_MERGESRCNOT 4511 #undef BM_NOTCOPYSRC 4512 #undef BM_MERGENOTSRC 4513 #undef BM_NOTMASKSRC 4514 #undef BM_ONE 4515 #undef BM_SRCTRANSPARENT 4516 #undef BM_DESTTRANSPARENT 4387 4517 #undef TA_NORMAL_HORIZ 4388 4518 #undef TA_LEFT … … 4920 5050 #undef OBJ_FORK 4921 5051 #undef DosAllocMem 5052 #define DosAllocMem(a, b, c) DosAllocMemEx((a),(b),(c) | os2_OBJ_FORK) 4922 5053 #undef DosAllocSharedMem 5054 #define DosAllocSharedMem(a,b,c,d) DosAllocSharedMemEx((a),(b),(c),(d) | os2_OBJ_FORK) 4923 5055 4924 5056 #endif /* __OS2WRAP2_H__ */
Note:
See TracChangeset
for help on using the changeset viewer.