Commit 5ee3a444 authored by Matthias Clasen's avatar Matthias Clasen

Remove sealed members from GtkSocket

parent 53845f08
......@@ -33,6 +33,7 @@
#include "gtkintl.h"
#include "gtkprivate.h"
#include "gtkplugprivate.h"
#include "gtksocketprivate.h"
#include "gtkwidgetprivate.h"
#include "gtkwindowprivate.h"
......@@ -346,8 +347,8 @@ _gtk_plug_add_to_socket (GtkPlug *plug,
gtk_plug_set_is_child (plug, TRUE);
priv->same_app = TRUE;
socket_->same_app = TRUE;
socket_->plug_widget = widget;
socket_->priv->same_app = TRUE;
socket_->priv->plug_widget = widget;
priv->socket_window = gtk_widget_get_window (GTK_WIDGET (socket_));
g_object_ref (priv->socket_window);
......@@ -436,14 +437,14 @@ _gtk_plug_remove_from_socket (GtkPlug *plug,
gtk_widget_unparent (GTK_WIDGET (plug));
_gtk_widget_set_in_reparent (widget, FALSE);
socket_->plug_widget = NULL;
if (socket_->plug_window != NULL)
socket_->priv->plug_widget = NULL;
if (socket_->priv->plug_window != NULL)
{
g_object_unref (socket_->plug_window);
socket_->plug_window = NULL;
g_object_unref (socket_->priv->plug_window);
socket_->priv->plug_window = NULL;
}
socket_->same_app = FALSE;
socket_->priv->same_app = FALSE;
priv->same_app = FALSE;
if (priv->socket_window != NULL)
......
This diff is collapsed.
This diff is collapsed.
......@@ -44,29 +44,13 @@ G_BEGIN_DECLS
typedef struct _GtkSocket GtkSocket;
typedef struct _GtkSocketClass GtkSocketClass;
typedef struct _GtkSocketPrivate GtkSocketPrivate;
struct _GtkSocket
{
GtkContainer container;
guint16 GSEAL (request_width);
guint16 GSEAL (request_height);
guint16 GSEAL (current_width);
guint16 GSEAL (current_height);
GdkWindow *GSEAL (plug_window);
GtkWidget *GSEAL (plug_widget);
gshort GSEAL (xembed_version); /* -1 == not xembed */
guint GSEAL (same_app) : 1;
guint GSEAL (focus_in) : 1;
guint GSEAL (have_size) : 1;
guint GSEAL (need_map) : 1;
guint GSEAL (is_mapped) : 1;
guint GSEAL (active) : 1;
GtkAccelGroup *GSEAL (accel_group);
GtkWidget *GSEAL (toplevel);
GtkSocketPrivate *priv;
};
struct _GtkSocketClass
......
......@@ -26,33 +26,50 @@
#ifndef __GTK_SOCKET_PRIVATE_H__
#define __GTK_SOCKET_PRIVATE_H__
typedef struct _GtkSocketPrivate GtkSocketPrivate;
#include "gtksocket.h"
struct _GtkSocketPrivate
{
gint resize_count;
guint16 request_width;
guint16 request_height;
guint16 current_width;
guint16 current_height;
GdkWindow *plug_window;
GtkWidget *plug_widget;
gshort xembed_version; /* -1 == not xembed */
guint same_app : 1;
guint focus_in : 1;
guint have_size : 1;
guint need_map : 1;
guint is_mapped : 1;
guint active : 1;
GtkAccelGroup *GSEAL (accel_group);
GtkWidget *GSEAL (toplevel);
};
/* In gtksocket.c: */
GtkSocketPrivate *_gtk_socket_get_private (GtkSocket *socket);
void _gtk_socket_add_grabbed_key (GtkSocket *socket,
guint keyval,
GdkModifierType modifiers);
guint keyval,
GdkModifierType modifiers);
void _gtk_socket_remove_grabbed_key (GtkSocket *socket,
guint keyval,
GdkModifierType modifiers);
void _gtk_socket_claim_focus (GtkSocket *socket,
gboolean send_event);
void _gtk_socket_add_window (GtkSocket *socket,
GdkNativeWindow xid,
gboolean need_reparent);
guint keyval,
GdkModifierType modifiers);
void _gtk_socket_claim_focus (GtkSocket *socket,
gboolean send_event);
void _gtk_socket_add_window (GtkSocket *socket,
GdkNativeWindow xid,
gboolean need_reparent);
void _gtk_socket_end_embedding (GtkSocket *socket);
void _gtk_socket_handle_map_request (GtkSocket *socket);
void _gtk_socket_unmap_notify (GtkSocket *socket);
void _gtk_socket_advance_toplevel_focus (GtkSocket *socket,
GtkDirectionType direction);
GtkDirectionType direction);
/* In backend-specific file: */
......@@ -88,36 +105,36 @@ void _gtk_socket_windowing_size_request (GtkSocket *socket);
*
*/
void _gtk_socket_windowing_send_key_event (GtkSocket *socket,
GdkEvent *gdk_event,
gboolean mask_key_presses);
GdkEvent *gdk_event,
gboolean mask_key_presses);
/*
* _gtk_socket_windowing_focus_change:
*
*/
void _gtk_socket_windowing_focus_change (GtkSocket *socket,
gboolean focus_in);
gboolean focus_in);
/*
* _gtk_socket_windowing_update_active:
*
*/
void _gtk_socket_windowing_update_active (GtkSocket *socket,
gboolean active);
gboolean active);
/*
* _gtk_socket_windowing_update_modality:
*
*/
void _gtk_socket_windowing_update_modality (GtkSocket *socket,
gboolean modality);
gboolean modality);
/*
* _gtk_socket_windowing_focus:
*
*/
void _gtk_socket_windowing_focus (GtkSocket *socket,
GtkDirectionType direction);
GtkDirectionType direction);
/*
* _gtk_socket_windowing_send_configure_event:
......@@ -165,7 +182,7 @@ void _gtk_socket_windowing_embed_set_focus_wrapped (void);
*
*/
GdkFilterReturn _gtk_socket_windowing_filter_func (GdkXEvent *gdk_xevent,
GdkEvent *event,
gpointer data);
GdkEvent *event,
gpointer data);
#endif /* __GTK_SOCKET_PRIVATE_H__ */
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment