merged 2.2 branch

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@7748 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Bryan Petty
2000-07-15 19:51:35 +00:00
parent 8a693e6e04
commit f6bcfd974e
1835 changed files with 237729 additions and 67990 deletions

View File

@@ -216,7 +216,7 @@ gtk_frame_configure_callback( GtkWidget *WXUNUSED(widget), GdkEventConfigure *ev
if (!win->m_hasVMT)
return FALSE;
#if (GTK_MINOR_VERSION > 0)
int x = 0;
int y = 0;
@@ -243,7 +243,7 @@ gtk_frame_configure_callback( GtkWidget *WXUNUSED(widget), GdkEventConfigure *ev
so we do this directly after realization */
static gint
gtk_frame_realized_callback( GtkWidget *widget, wxFrame *win )
gtk_frame_realized_callback( GtkWidget * WXUNUSED(widget), wxFrame *win )
{
if (g_isIdle)
wxapp_install_idle_handler();
@@ -283,7 +283,7 @@ gtk_frame_realized_callback( GtkWidget *widget, wxFrame *win )
func |= GDK_FUNC_RESIZE;
decor |= GDK_DECOR_RESIZEH;
}
gdk_window_set_decorations( win->m_widget->window, (GdkWMDecoration)decor);
gdk_window_set_functions( win->m_widget->window, (GdkWMFunction)func);
}
@@ -394,7 +394,6 @@ void wxFrame::Init()
m_menuBarDetached = FALSE;
m_toolBarDetached = FALSE;
m_insertInClientArea = TRUE;
m_isFrame = FALSE;
}
bool wxFrame::Create( wxWindow *parent,
@@ -408,7 +407,6 @@ bool wxFrame::Create( wxWindow *parent,
wxTopLevelWindows.Append( this );
m_needParent = FALSE;
m_isFrame = TRUE;
if (!PreCreation( parent, pos, size ) ||
!CreateBase( parent, id, pos, size, style, wxDefaultValidator, name ))
@@ -475,7 +473,7 @@ bool wxFrame::Create( wxWindow *parent,
if ((m_x != -1) || (m_y != -1))
gtk_widget_set_uposition( m_widget, m_x, m_y );
gtk_widget_set_usize( m_widget, m_width, m_height );
/* we cannot set MWM hints and icons before the widget has
been realized, so we do this directly after realization */
gtk_signal_connect( GTK_OBJECT(m_widget), "realize",
@@ -535,7 +533,7 @@ void wxFrame::DoMoveWindow(int WXUNUSED(x), int WXUNUSED(y), int WXUNUSED(width)
{
wxFAIL_MSG( wxT("DoMoveWindow called for wxFrame") );
}
void wxFrame::DoSetSize( int x, int y, int width, int height, int sizeFlags )
{
wxASSERT_MSG( (m_widget != NULL), wxT("invalid frame") );
@@ -738,23 +736,22 @@ void wxFrame::GtkOnSize( int WXUNUSED(x), int WXUNUSED(y),
if ((m_minHeight != -1) && (m_height < m_minHeight)) m_height = m_minHeight;
if ((m_maxWidth != -1) && (m_width > m_maxWidth)) m_width = m_maxWidth;
if ((m_maxHeight != -1) && (m_height > m_maxHeight)) m_height = m_maxHeight;
/* set size hints */
gint flag = 0; // GDK_HINT_POS;
if ((m_minWidth != -1) || (m_minHeight != -1)) flag |= GDK_HINT_MIN_SIZE;
if ((m_maxWidth != -1) || (m_maxHeight != -1)) flag |= GDK_HINT_MAX_SIZE;
GdkGeometry geom;
geom.min_width = m_minWidth;
geom.min_height = m_minHeight;
geom.max_width = m_maxWidth;
geom.max_height = m_maxHeight;
gtk_window_set_geometry_hints( GTK_WINDOW(m_widget),
(GtkWidget*) NULL,
&geom,
(GdkWindowHints) flag );
if (m_mainWidget)
{
/* set size hints */
gint flag = 0; // GDK_HINT_POS;
if ((m_minWidth != -1) || (m_minHeight != -1)) flag |= GDK_HINT_MIN_SIZE;
if ((m_maxWidth != -1) || (m_maxHeight != -1)) flag |= GDK_HINT_MAX_SIZE;
GdkGeometry geom;
geom.min_width = m_minWidth;
geom.min_height = m_minHeight;
geom.max_width = m_maxWidth;
geom.max_height = m_maxHeight;
gtk_window_set_geometry_hints( GTK_WINDOW(m_widget),
(GtkWidget*) NULL,
&geom,
(GdkWindowHints) flag );
/* I revert back to wxGTK's original behaviour. m_mainWidget holds the
* menubar, the toolbar and the client area, which is represented by
@@ -926,7 +923,7 @@ void wxFrame::SetMenuBar( wxMenuBar *menuBar )
gtk_signal_disconnect_by_func( GTK_OBJECT(m_frameMenuBar->m_widget),
GTK_SIGNAL_FUNC(gtk_menu_detached_callback), (gpointer)this );
}
gtk_container_remove( GTK_CONTAINER(m_mainWidget), m_frameMenuBar->m_widget );
gtk_widget_ref( m_frameMenuBar->m_widget );
gtk_widget_unparent( m_frameMenuBar->m_widget );
@@ -971,9 +968,6 @@ wxToolBar* wxFrame::CreateToolBar( long style, wxWindowID id, const wxString& na
m_frameToolBar = wxFrameBase::CreateToolBar( style, id, name );
if (m_frameToolBar)
GetChildren().DeleteObject( m_frameToolBar );
m_insertInClientArea = TRUE;
m_sizeSet = FALSE;