1. fixed makefile.vc for OLE files

2. fixed asserts in wxGTK::wxWindow::DoGetClientSize()


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@3007 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Vadim Zeitlin 1999-07-15 14:08:30 +00:00
parent 0efe5ba76e
commit 6a008b33c4
5 changed files with 94 additions and 88 deletions

View File

@ -225,4 +225,4 @@ wave.cpp M
window.cpp M
xpmhand.cpp M
# vi: set noet ts=16:
# vi: set noet ts=16 nolist:

View File

@ -6,7 +6,6 @@
#! Created: 14.07.99
#! Version: $Id$
#!#############################################################################
#${
#! include the code which parses filelist.txt file and initializes
#! %wxCommon, %wxGeneric and %wxMSW hashes.
@ -36,11 +35,13 @@
foreach $file (sort keys %wxMSW) {
next if $wxMSW{$file} =~ /\b16\b/;
#! OLE files live in a subdir
$project{"WXMSWOBJS"} .= '..\msw\\';
$project{"WXMSWOBJS"} .= 'ole\\' if $wxMSW{$file} =~ /\bO\b/;
$file =~ s/cp?p?$/obj/;
$project{"WXMSWOBJS"} .= "..\\msw\\\$D\\" . $file . " "
$project{"WXMSWOBJS"} .= '$D\\' . $file . " ";
}
#$}
# This file was automatically generated by tmake at #$ Now()
# DO NOT CHANGE THIS FILE, YOUR CHANGES WILL BE LOST! CHANGE VC.T!

View File

@ -664,7 +664,7 @@ static void gtk_window_expose_callback( GtkWidget *WXUNUSED(widget), GdkEventExp
if (!win->m_hasVMT)
return;
if (gdk_event->window != win->m_wxwindow->window)
if (gdk_event->window != win->m_wxwindow->window)
return;
win->GetUpdateRegion().Union( gdk_event->area.x,
@ -688,7 +688,7 @@ static void gtk_window_expose_callback( GtkWidget *WXUNUSED(widget), GdkEventExp
(int)gdk_event->area.width,
(int)gdk_event->area.height );
*/
win->GetUpdateRegion().Clear();
}
@ -709,7 +709,7 @@ static void gtk_window_draw_callback( GtkWidget *WXUNUSED(widget), GdkRectangle
wxPaintEvent event( win->GetId() );
event.SetEventObject( win );
/*
wxPrintf( "OnDraw from " );
if (win->GetClassInfo() && win->GetClassInfo()->GetClassName())
@ -2214,28 +2214,28 @@ void wxWindow::OnInternalIdle()
if (cursor.Ok() && m_currentGdkCursor != cursor)
{
if (m_wxwindow)
{
{
GdkWindow *window = m_wxwindow->window;
if (window)
if (window)
gdk_window_set_cursor( window, cursor.GetCursor() );
if (!g_globalCursor.Ok())
cursor = *wxSTANDARD_CURSOR;
window = m_widget->window;
if (window)
if (!g_globalCursor.Ok())
cursor = *wxSTANDARD_CURSOR;
window = m_widget->window;
if (window)
gdk_window_set_cursor( window, cursor.GetCursor() );
}
else
{
}
else
{
GdkWindow *window = m_widget->window;
if (window)
if (window)
gdk_window_set_cursor( window, cursor.GetCursor() );
}
}
m_currentGdkCursor = cursor;
}
UpdateWindowUI();
}
@ -2275,8 +2275,8 @@ void wxWindow::DoSetClientSize( int width, int height )
#else
if (HasFlag(wxRAISED_BORDER) || HasFlag(wxSUNKEN_BORDER))
{
/* when using GTK 1.2 we set the border size to 2 */
dw += 2 * 2;
/* when using GTK 1.2 we set the border size to 2 */
dw += 2 * 2;
dh += 2 * 2;
}
#endif
@ -2321,23 +2321,26 @@ void wxWindow::DoGetClientSize( int *width, int *height ) const
int dw = 0;
int dh = 0;
GtkScrolledWindow *scroll_window = GTK_SCROLLED_WINDOW(m_widget);
GtkScrolledWindowClass *scroll_class = GTK_SCROLLED_WINDOW_CLASS( GTK_OBJECT(m_widget)->klass );
#if (GTK_MINOR_VERSION == 0)
GtkWidget *viewport = scroll_window->viewport;
GtkStyleClass *viewport_class = viewport->style->klass;
if (HasFlag(wxRAISED_BORDER) || HasFlag(wxSUNKEN_BORDER))
{
dw += 2 * viewport_class->xthickness;
dh += 2 * viewport_class->ythickness;
if (HasScrolling())
{
GtkScrolledWindow *scroll_window = GTK_SCROLLED_WINDOW(m_widget);
GtkScrolledWindowClass *scroll_class = GTK_SCROLLED_WINDOW_CLASS( GTK_OBJECT(m_widget)->klass );
GtkWidget *viewport = scroll_window->viewport;
GtkStyleClass *viewport_class = viewport->style->klass;
dw += 2 * viewport_class->xthickness;
dh += 2 * viewport_class->ythickness;
}
}
#else
if (HasFlag(wxRAISED_BORDER) || HasFlag(wxSUNKEN_BORDER))
{
/* when using GTK 1.2 we set the border size to 2 */
dw += 2 * 2;
/* when using GTK 1.2 we set the border size to 2 */
dw += 2 * 2;
dh += 2 * 2;
}
#endif
@ -2350,6 +2353,9 @@ void wxWindow::DoGetClientSize( int *width, int *height ) const
we use this instead: range.slider_width = 11 + 2*2pts edge
*/
GtkScrolledWindow *scroll_window = GTK_SCROLLED_WINDOW(m_widget);
GtkScrolledWindowClass *scroll_class = GTK_SCROLLED_WINDOW_CLASS( GTK_OBJECT(m_widget)->klass );
if (scroll_window->vscrollbar_visible)
{
dw += 15; /* dw += vscrollbar->allocation.width; */
@ -2361,7 +2367,7 @@ void wxWindow::DoGetClientSize( int *width, int *height ) const
dh += 15; /* dh += hscrollbar->allocation.height; */
dh += scroll_class->scrollbar_spacing;
}
}
}
if (width) (*width) = m_width - dw;
if (height) (*height) = m_height - dh;

View File

@ -664,7 +664,7 @@ static void gtk_window_expose_callback( GtkWidget *WXUNUSED(widget), GdkEventExp
if (!win->m_hasVMT)
return;
if (gdk_event->window != win->m_wxwindow->window)
if (gdk_event->window != win->m_wxwindow->window)
return;
win->GetUpdateRegion().Union( gdk_event->area.x,
@ -688,7 +688,7 @@ static void gtk_window_expose_callback( GtkWidget *WXUNUSED(widget), GdkEventExp
(int)gdk_event->area.width,
(int)gdk_event->area.height );
*/
win->GetUpdateRegion().Clear();
}
@ -709,7 +709,7 @@ static void gtk_window_draw_callback( GtkWidget *WXUNUSED(widget), GdkRectangle
wxPaintEvent event( win->GetId() );
event.SetEventObject( win );
/*
wxPrintf( "OnDraw from " );
if (win->GetClassInfo() && win->GetClassInfo()->GetClassName())
@ -2214,28 +2214,28 @@ void wxWindow::OnInternalIdle()
if (cursor.Ok() && m_currentGdkCursor != cursor)
{
if (m_wxwindow)
{
{
GdkWindow *window = m_wxwindow->window;
if (window)
if (window)
gdk_window_set_cursor( window, cursor.GetCursor() );
if (!g_globalCursor.Ok())
cursor = *wxSTANDARD_CURSOR;
window = m_widget->window;
if (window)
if (!g_globalCursor.Ok())
cursor = *wxSTANDARD_CURSOR;
window = m_widget->window;
if (window)
gdk_window_set_cursor( window, cursor.GetCursor() );
}
else
{
}
else
{
GdkWindow *window = m_widget->window;
if (window)
if (window)
gdk_window_set_cursor( window, cursor.GetCursor() );
}
}
m_currentGdkCursor = cursor;
}
UpdateWindowUI();
}
@ -2275,8 +2275,8 @@ void wxWindow::DoSetClientSize( int width, int height )
#else
if (HasFlag(wxRAISED_BORDER) || HasFlag(wxSUNKEN_BORDER))
{
/* when using GTK 1.2 we set the border size to 2 */
dw += 2 * 2;
/* when using GTK 1.2 we set the border size to 2 */
dw += 2 * 2;
dh += 2 * 2;
}
#endif
@ -2321,23 +2321,26 @@ void wxWindow::DoGetClientSize( int *width, int *height ) const
int dw = 0;
int dh = 0;
GtkScrolledWindow *scroll_window = GTK_SCROLLED_WINDOW(m_widget);
GtkScrolledWindowClass *scroll_class = GTK_SCROLLED_WINDOW_CLASS( GTK_OBJECT(m_widget)->klass );
#if (GTK_MINOR_VERSION == 0)
GtkWidget *viewport = scroll_window->viewport;
GtkStyleClass *viewport_class = viewport->style->klass;
if (HasFlag(wxRAISED_BORDER) || HasFlag(wxSUNKEN_BORDER))
{
dw += 2 * viewport_class->xthickness;
dh += 2 * viewport_class->ythickness;
if (HasScrolling())
{
GtkScrolledWindow *scroll_window = GTK_SCROLLED_WINDOW(m_widget);
GtkScrolledWindowClass *scroll_class = GTK_SCROLLED_WINDOW_CLASS( GTK_OBJECT(m_widget)->klass );
GtkWidget *viewport = scroll_window->viewport;
GtkStyleClass *viewport_class = viewport->style->klass;
dw += 2 * viewport_class->xthickness;
dh += 2 * viewport_class->ythickness;
}
}
#else
if (HasFlag(wxRAISED_BORDER) || HasFlag(wxSUNKEN_BORDER))
{
/* when using GTK 1.2 we set the border size to 2 */
dw += 2 * 2;
/* when using GTK 1.2 we set the border size to 2 */
dw += 2 * 2;
dh += 2 * 2;
}
#endif
@ -2350,6 +2353,9 @@ void wxWindow::DoGetClientSize( int *width, int *height ) const
we use this instead: range.slider_width = 11 + 2*2pts edge
*/
GtkScrolledWindow *scroll_window = GTK_SCROLLED_WINDOW(m_widget);
GtkScrolledWindowClass *scroll_class = GTK_SCROLLED_WINDOW_CLASS( GTK_OBJECT(m_widget)->klass );
if (scroll_window->vscrollbar_visible)
{
dw += 15; /* dw += vscrollbar->allocation.width; */
@ -2361,7 +2367,7 @@ void wxWindow::DoGetClientSize( int *width, int *height ) const
dh += 15; /* dh += hscrollbar->allocation.height; */
dh += scroll_class->scrollbar_spacing;
}
}
}
if (width) (*width) = m_width - dw;
if (height) (*height) = m_height - dh;

View File

@ -1,8 +1,4 @@
# This file was automatically generated by tmake at 21:00, 1999/07/14
# This file was automatically generated by tmake at 16:05, 1999/07/15
# DO NOT CHANGE THIS FILE, YOUR CHANGES WILL BE LOST! CHANGE VC.T!
# File: makefile.vc
@ -90,6 +86,7 @@ GENERICOBJS= ..\generic\$D\busyinfo.obj \
..\generic\$D\sashwin.obj \
..\generic\$D\scrolwin.obj \
..\generic\$D\splitter.obj \
..\generic\$D\statusbr.obj \
..\generic\$D\tabg.obj \
..\generic\$D\textdlgg.obj \
..\generic\$D\tipdlg.obj
@ -106,11 +103,9 @@ NONESSENTIALOBJS= ..\generic\$D\colrdlgg.obj \
..\generic\$D\notebook.obj \
..\generic\$D\printps.obj \
..\generic\$D\prntdlgg.obj \
..\generic\$D\statusbr.obj \
..\generic\$D\treectrl.obj
COMMONOBJS = \
..\common\$D\extended.obj \
..\common\$D\y_tab.obj \
..\common\$D\cmndata.obj \
..\common\$D\config.obj \
@ -125,6 +120,8 @@ COMMONOBJS = \
..\common\$D\dynarray.obj \
..\common\$D\dynlib.obj \
..\common\$D\event.obj \
..\common\$D\extended.obj \
..\common\$D\ffile.obj \
..\common\$D\file.obj \
..\common\$D\fileconf.obj \
..\common\$D\filefn.obj \
@ -168,7 +165,7 @@ COMMONOBJS = \
..\common\$D\stream.obj \
..\common\$D\string.obj \
..\common\$D\tbarbase.obj \
..\common\$D\tbarsmpl.obj \
..\common\$D\textcmn.obj \
..\common\$D\textfile.obj \
..\common\$D\time.obj \
..\common\$D\timercmn.obj \
@ -190,7 +187,7 @@ COMMONOBJS = \
MSWOBJS = ..\msw\$D\accel.obj \
..\msw\$D\app.obj \
..\msw\$D\automtn.obj \
..\msw\ole\$D\automtn.obj \
..\msw\$D\bitmap.obj \
..\msw\$D\bmpbuttn.obj \
..\msw\$D\brush.obj \
@ -207,7 +204,7 @@ MSWOBJS = ..\msw\$D\accel.obj \
..\msw\$D\curico.obj \
..\msw\$D\cursor.obj \
..\msw\$D\data.obj \
..\msw\$D\dataobj.obj \
..\msw\ole\$D\dataobj.obj \
..\msw\$D\dc.obj \
..\msw\$D\dcclient.obj \
..\msw\$D\dcmemory.obj \
@ -219,20 +216,21 @@ MSWOBJS = ..\msw\$D\accel.obj \
..\msw\$D\dibutils.obj \
..\msw\$D\dirdlg.obj \
..\msw\$D\dragimag.obj \
..\msw\$D\dropsrc.obj \
..\msw\$D\droptgt.obj \
..\msw\ole\$D\dropsrc.obj \
..\msw\ole\$D\droptgt.obj \
..\msw\$D\filedlg.obj \
..\msw\$D\font.obj \
..\msw\$D\fontdlg.obj \
..\msw\$D\frame.obj \
..\msw\$D\gauge95.obj \
..\msw\$D\gaugemsw.obj \
..\msw\$D\gdiobj.obj \
..\msw\$D\helpwin.obj \
..\msw\$D\icon.obj \
..\msw\$D\imaglist.obj \
..\msw\$D\iniconf.obj \
..\msw\$D\joystick.obj \
..\msw\$D\listbox.obj \
..\msw\$D\listctrl.obj \
..\msw\$D\main.obj \
..\msw\$D\mdi.obj \
..\msw\$D\menu.obj \
@ -241,7 +239,8 @@ MSWOBJS = ..\msw\$D\accel.obj \
..\msw\$D\minifram.obj \
..\msw\$D\msgdlg.obj \
..\msw\$D\nativdlg.obj \
..\msw\$D\oleutils.obj \
..\msw\$D\notebook.obj \
..\msw\ole\$D\oleutils.obj \
..\msw\$D\ownerdrw.obj \
..\msw\$D\palette.obj \
..\msw\$D\pen.obj \
@ -257,7 +256,6 @@ MSWOBJS = ..\msw\$D\accel.obj \
..\msw\$D\scrolbar.obj \
..\msw\$D\settings.obj \
..\msw\$D\slider95.obj \
..\msw\$D\slidrmsw.obj \
..\msw\$D\spinbutt.obj \
..\msw\$D\statbmp.obj \
..\msw\$D\statbox.obj \
@ -267,14 +265,14 @@ MSWOBJS = ..\msw\$D\accel.obj \
..\msw\$D\tabctrl.obj \
..\msw\$D\taskbar.obj \
..\msw\$D\tbar95.obj \
..\msw\$D\tbarmsw.obj \
..\msw\$D\textctrl.obj \
..\msw\$D\thread.obj \
..\msw\$D\timer.obj \
..\msw\$D\tooltip.obj \
..\msw\$D\treectrl.obj \
..\msw\$D\utils.obj \
..\msw\$D\utilsexc.obj \
..\msw\$D\uuid.obj \
..\msw\ole\$D\uuid.obj \
..\msw\$D\wave.obj \
..\msw\$D\window.obj \
..\msw\$D\xpmhand.obj
@ -416,11 +414,6 @@ $(CPPFLAGS) $(MAKEPRECOMP) /Fo$D\dummydll.obj /c /Tp dummydll.cpp
# if not exist setup.h copy setup0.h setup.h
# cd "$(WXDIR)"\src\msw
..\common\$D\extended.obj: ..\common\extended.c
cl @<<
$(CPPFLAGS2) /c $(COMMDIR)\extended.c /Fo$@
<<
..\common\$D\y_tab.obj: ..\common\y_tab.c ..\common\lex_yy.c
cl @<<
$(CPPFLAGS2) /c ..\common\y_tab.c -DUSE_DEFINE -DYY_USE_PROTOS /Fo$@