Some more WXWIN_COMPATIBILITY fixes.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@1119 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Julian Smart
1998-12-06 20:26:55 +00:00
parent 38d24a39d3
commit ca5e9f677a
6 changed files with 24 additions and 12 deletions

View File

@@ -29,7 +29,7 @@ public:
const wxString& title, const wxString& title,
const wxPoint& pos = wxDefaultPosition, const wxPoint& pos = wxDefaultPosition,
const wxSize& size = wxDefaultSize, const wxSize& size = wxDefaultSize,
long style = wxDEFAULT_FRAME|wxTINY_CAPTION_HORIZ, long style = wxDEFAULT_FRAME_STYLE|wxTINY_CAPTION_HORIZ,
const wxString& name = wxFrameNameStr) const wxString& name = wxFrameNameStr)
{ {
Create(parent, id, title, pos, size, style, name); Create(parent, id, title, pos, size, style, name);

View File

@@ -50,9 +50,9 @@ PERIPH_TARGET=xpm $(PERIPH_TARGET)
PERIPH_CLEAN_TARGET=clean_xpm $(PERIPH_CLEAN_TARGET) PERIPH_CLEAN_TARGET=clean_xpm $(PERIPH_CLEAN_TARGET)
!endif !endif
PERIPH_LIBS=$(WXDIR)\lib\zlib.lib $(PERIPH_LIBS) PERIPH_LIBS=$(WXDIR)\lib\zlib.lib $(WXDIR)\lib\winpng.lib $(PERIPH_LIBS)
PERIPH_TARGET=zlib $(PERIPH_TARGET) PERIPH_TARGET=zlib png $(PERIPH_TARGET)
PERIPH_CLEAN_TARGET=clean_zlib $(PERIPH_CLEAN_TARGET) PERIPH_CLEAN_TARGET=clean_zlib clean_png $(PERIPH_CLEAN_TARGET)
!if "$(DLL)" == "0" !if "$(DLL)" == "0"
DUMMY=dummy DUMMY=dummy
@@ -176,6 +176,7 @@ MSWOBJS = \
$(MSWDIR)\dde.obj \ $(MSWDIR)\dde.obj \
$(MSWDIR)\dialog.obj \ $(MSWDIR)\dialog.obj \
$(MSWDIR)\dib.obj \ $(MSWDIR)\dib.obj \
$(MSWDIR)\dibutils.obj \
$(MSWDIR)\dirdlg.obj \ $(MSWDIR)\dirdlg.obj \
$(MSWDIR)\filedlg.obj \ $(MSWDIR)\filedlg.obj \
$(MSWDIR)\font.obj \ $(MSWDIR)\font.obj \
@@ -203,6 +204,7 @@ MSWOBJS = \
$(MSWDIR)\palette.obj \ $(MSWDIR)\palette.obj \
$(MSWDIR)\pen.obj \ $(MSWDIR)\pen.obj \
$(MSWDIR)\penwin.obj \ $(MSWDIR)\penwin.obj \
$(MSWDIR)\pnghand.obj \
$(MSWDIR)\printdlg.obj \ $(MSWDIR)\printdlg.obj \
$(MSWDIR)\printwin.obj \ $(MSWDIR)\printwin.obj \
$(MSWDIR)\radiobox.obj \ $(MSWDIR)\radiobox.obj \
@@ -642,6 +644,16 @@ wxxpm: $(CFG)
make -f makefile.b32 -DCFG=$(CFG) -DFINAL=$(FINAL) -DWXWIN=$(WXDIR) -DDEBUG=$(DEBUG) make -f makefile.b32 -DCFG=$(CFG) -DFINAL=$(FINAL) -DWXWIN=$(WXDIR) -DDEBUG=$(DEBUG)
cd $(WXDIR)\src\msw cd $(WXDIR)\src\msw
png: $(CFG)
cd $(WXDIR)\src\png
make -f makefile.b32
cd $(WXDIR)\src\msw
clean_png:
cd $(WXDIR)\src\png
make -f makefile.b32 clean
cd $(WXDIR)\src\msw
zlib: $(CFG) zlib: $(CFG)
cd $(WXDIR)\src\zlib cd $(WXDIR)\src\zlib
make -f makefile.b32 lib make -f makefile.b32 lib

View File

@@ -34,11 +34,11 @@ extern void wxFindMaxSize(HWND hwnd, RECT *rect);
#if !USE_SHARED_LIBRARY #if !USE_SHARED_LIBRARY
IMPLEMENT_DYNAMIC_CLASS(wxScrollBar, wxControl) IMPLEMENT_DYNAMIC_CLASS(wxScrollBar, wxControl)
#if WXWIN_COMPATIBILITY
BEGIN_EVENT_TABLE(wxScrollBar, wxControl) BEGIN_EVENT_TABLE(wxScrollBar, wxControl)
#if WXWIN_COMPATIBILITY
EVT_SCROLL(wxScrollBar::OnScroll) EVT_SCROLL(wxScrollBar::OnScroll)
END_EVENT_TABLE()
#endif #endif
END_EVENT_TABLE()
#endif #endif
@@ -183,7 +183,7 @@ void wxScrollBar::MSWOnVScroll(WXWORD wParam, WXWORD pos, WXHWND control)
if (new_pos > maxPos) if (new_pos > maxPos)
new_pos = maxPos; new_pos = maxPos;
SetValue(new_pos); SetThumbPosition(new_pos);
wxScrollEvent event(scrollEvent, m_windowId); wxScrollEvent event(scrollEvent, m_windowId);
event.SetPosition(new_pos); event.SetPosition(new_pos);
event.SetEventObject( this ); event.SetEventObject( this );
@@ -331,7 +331,7 @@ WXHBRUSH wxScrollBar::OnCtlColor(WXHDC pDC, WXHWND pWnd, WXUINT nCtlColor,
void wxScrollBar::Command(wxCommandEvent& event) void wxScrollBar::Command(wxCommandEvent& event)
{ {
SetValue(event.m_commandInt); SetThumbPosition(event.m_commandInt);
ProcessCommand(event); ProcessCommand(event);
} }

View File

@@ -36,11 +36,11 @@
#if !USE_SHARED_LIBRARY #if !USE_SHARED_LIBRARY
IMPLEMENT_DYNAMIC_CLASS(wxSlider95, wxControl) IMPLEMENT_DYNAMIC_CLASS(wxSlider95, wxControl)
#if WXWIN_COMPATIBILITY
BEGIN_EVENT_TABLE(wxSlider95, wxControl) BEGIN_EVENT_TABLE(wxSlider95, wxControl)
#if WXWIN_COMPATIBILITY
EVT_SCROLL(wxSlider95::OnScroll) EVT_SCROLL(wxSlider95::OnScroll)
END_EVENT_TABLE()
#endif #endif
END_EVENT_TABLE()
#endif #endif

View File

@@ -488,7 +488,7 @@ wxToolBarTool *wxToolBar95::AddTool(int index, const wxBitmap& bitmap, const wxB
else else
tool->m_y = m_yMargin; tool->m_y = m_yMargin;
tool->SetSize(GetDefaultButtonWidth(), GetDefaultButtonHeight()); tool->SetSize(GetToolSize().x, GetToolSize().y);
m_tools.Append((long)index, tool); m_tools.Append((long)index, tool);
return tool; return tool;

View File

@@ -3189,7 +3189,7 @@ int wxWindow::GetScrollRange(int orient) const
#if defined(__WIN95__) #if defined(__WIN95__)
// Try to adjust the range to cope with page size > 1 // Try to adjust the range to cope with page size > 1
// - a Windows API quirk // - a Windows API quirk
int pageSize = GetScrollPage(orient); int pageSize = GetScrollThumb(orient);
if ( pageSize > 1 ) if ( pageSize > 1 )
{ {
maxPos -= (pageSize - 1); maxPos -= (pageSize - 1);