Changeset 1184 for trunk/src/user32/oslibwin.cpp
- Timestamp:
- Oct 8, 1999, 2:10:27 PM (26 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/user32/oslibwin.cpp
r1176 r1184 1 /* $Id: oslibwin.cpp,v 1.1 4 1999-10-07 23:21:30 sandervlExp $ */1 /* $Id: oslibwin.cpp,v 1.15 1999-10-08 12:10:27 cbratschi Exp $ */ 2 2 /* 3 3 * Window API wrappers for OS/2 … … 26 26 #include "oslibgdi.h" 27 27 #include "pmwindow.h" 28 29 #define HAS_3DFRAME(exStyle) \ 30 ((exStyle & WS_EX_CLIENTEDGE_W) || (exStyle & WS_EX_STATICEDGE_W) || (exStyle & WS_EX_WINDOWEDGE_W)) 28 31 29 32 //****************************************************************************** … … 115 118 if (dwStyle & WS_CHILD_W) 116 119 { 120 if (dwStyle & WS_BORDER_W || 121 dwStyle & WS_DLGFRAME_W || 122 dwStyle & WS_THICKFRAME_W) 123 if (!HAS_3DFRAME(*OSFrameStyle)) *OSFrameStyle |= WS_EX_WINDOWEDGE_W; 124 117 125 if (dwExStyle & WS_EX_CLIENTEDGE_W || 118 126 dwExStyle & WS_EX_STATICEDGE_W || … … 688 696 689 697 if(scrollBar == OSLIB_VSCROLL) { 690 698 hwndScroll = WinWindowFromID(hwndParent, FID_VERTSCROLL); 691 699 } 692 700 else hwndScroll = WinWindowFromID(hwndParent, FID_HORZSCROLL); 693 701 694 702 if(hwndScroll == NULL) 695 703 return FALSE; 696 704 697 705 return WinEnableWindow(hwndScroll, fEnable); … … 702 710 { 703 711 if(hwndScroll == NULL) { 704 705 712 dprintf(("OSLibWinShowScrollBar: scrollbar %d (parent %x) not found!", scrollBar, hwndParent)); 713 return FALSE; 706 714 } 707 715 708 if(fShow != WinIsWindowVisible(hwndScroll)) 716 if(fShow != WinIsWindowVisible(hwndScroll)) 709 717 { 710 718 WinSetParent(hwndScroll, fShow ? hwndParent : HWND_OBJECT, FALSE); 711 719 WinSendMsg(hwndParent, WM_UPDATEFRAME, 712 MPFROMLONG( ( scrollBar == OSLIB_VSCROLL ) ? FCF_VERTSCROLL 713 720 MPFROMLONG( ( scrollBar == OSLIB_VSCROLL ) ? FCF_VERTSCROLL 721 : FCF_HORZSCROLL), 714 722 MPVOID ); 715 723 716 724 WinShowWindow(hwndScroll, fShow); 717 725 } 718 return TRUE; 726 return TRUE; 719 727 } 720 728 //****************************************************************************** … … 723 731 { 724 732 if(scrollBar == OSLIB_VSCROLL) { 725 733 return WinWindowFromID(hwndParent, FID_VERTSCROLL); 726 734 } 727 735 else return WinWindowFromID(hwndParent, FID_HORZSCROLL); … … 732 740 { 733 741 if(hwndScroll == NULL) 734 742 return 0; 735 743 736 744 return (ULONG)WinSendMsg(hwndScroll, SBM_QUERYPOS, 0, 0); … … 743 751 744 752 if(hwndScroll == NULL) 745 753 return 0; 746 754 747 755 oldPos = (ULONG)WinSendMsg(hwndScroll, SBM_QUERYPOS, 0, 0); 748 756 749 757 if(WinSendMsg(hwndScroll, SBM_SETPOS, MPFROMSHORT(pos), MPFROMLONG(fRedraw)) == FALSE) 750 758 return 0; 751 759 752 760 return oldPos; … … 754 762 //****************************************************************************** 755 763 //****************************************************************************** 756 BOOL OSLibWinSetScrollRange(HWND hwndParent, HWND hwndScroll, int minpos, 764 BOOL OSLibWinSetScrollRange(HWND hwndParent, HWND hwndScroll, int minpos, 757 765 int maxpos, int fRedraw) 758 766 { 759 767 if(hwndScroll == NULL) 760 768 return 0; 761 769 762 770 return (BOOL)WinSendMsg( hwndScroll, SBM_SETSCROLLBAR, … … 766 774 //****************************************************************************** 767 775 //****************************************************************************** 768 BOOL OSLibWinSetScrollPageSize(HWND hwndParent, HWND hwndScroll, int pagesize, 776 BOOL OSLibWinSetScrollPageSize(HWND hwndParent, HWND hwndScroll, int pagesize, 769 777 int totalsize, int fRedraw) 770 778 { 771 779 if(hwndScroll == NULL) 772 780 return 0; 773 781 774 782 return (BOOL)WinSendMsg( hwndScroll, SBM_SETTHUMBSIZE,
Note:
See TracChangeset
for help on using the changeset viewer.