Re: gnome-wrapper
- From: Nat Friedman <nat helixcode com>
- To: Dietmar Maurer <dm vlsivie tuwien ac at>
- Cc: "gnome-components-list gnome org" <gnome-components-list gnome org>
- Subject: Re: gnome-wrapper
- Date: Tue, 30 Nov 1999 19:20:11 -0500 (EST)
Dietmar Maurer writes:
> With the above workaround you need direct access to the GnomeClientSite structure,
> which is not a nice solution. Why not return the socket and make the wrapper
> optional. Or write a support function which creates the wrapper. I can't see any
> disadvantage.
The disadvantage is more API breakage, basically. Does this patch
make you feel any better?
Nat
Index: gnome-client-site.c
===================================================================
RCS file: /cvs/gnome/bonobo/bonobo/gnome-client-site.c,v
retrieving revision 1.39
diff -u -r1.39 gnome-client-site.c
--- gnome-client-site.c 1999/11/30 12:05:50 1.39
+++ gnome-client-site.c 1999/12/01 00:19:31
@@ -405,9 +405,10 @@
}
/**
- * gnome_client_site_new_view:
- * @client_site: the client site that contains a remote Embeddable
- * object.
+ * gnome_client_site_new_view_full:
+ * @client_site: the client site that contains a remote Embeddable object.
+ * @visible_cover: %TRUE if the cover should draw a border when it is active.
+ * @active_view: %TRUE if the view should be uncovered when it is created.
*
* Creates a ViewFrame and asks the remote @server_object (which must
* support the GNOME::Embeddable interface) to provide a new view of
@@ -419,7 +420,9 @@
* the new view of @server_object.
*/
GnomeViewFrame *
-gnome_client_site_new_view (GnomeClientSite *client_site)
+gnome_client_site_new_view_full (GnomeClientSite *client_site,
+ gboolean visible_cover,
+ gboolean active_view)
{
GnomeObjectClient *server_object;
GnomeViewFrame *view_frame;
@@ -446,6 +449,8 @@
*/
view_frame = gnome_view_frame_new (client_site);
wrapper = GNOME_WRAPPER (gnome_view_frame_get_wrapper (view_frame));
+ gnome_wrapper_set_visibility (wrapper, visible_cover);
+ gnome_wrapper_set_covered (wrapper, ! active_view);
gtk_container_add (GTK_CONTAINER (wrapper), socket);
@@ -488,6 +493,24 @@
CORBA_exception_free (&ev);
return view_frame;
+}
+
+/**
+ * gnome_client_site_new_view:
+ * @client_site: the client site that contains a remote Embeddable
+ * object.
+ *
+ * The same as gnome_client_site_new_view_full() with an inactive,
+ * visible cover.
+ *
+ * Returns: A GnomeViewFrame object that contains the view frame for
+ * the new view of @server_object.
+ */
+GnomeViewFrame *
+gnome_client_site_new_view (GnomeClientSite *client_site)
+{
+
+ return gnome_client_site_new_view_full (client_site, TRUE, FALSE);
}
static void
Index: gnome-client-site.h
===================================================================
RCS file: /cvs/gnome/bonobo/bonobo/gnome-client-site.h,v
retrieving revision 1.24
diff -u -r1.24 gnome-client-site.h
--- gnome-client-site.h 1999/11/30 12:05:50 1.24
+++ gnome-client-site.h 1999/12/01 00:19:31
@@ -63,6 +63,9 @@
/*
* Proxy/Utility functions.
*/
+GnomeViewFrame *gnome_client_site_new_view_full (GnomeClientSite *client_site,
+ gboolean visible_cover,
+ gboolean active_view);
GnomeViewFrame *gnome_client_site_new_view (GnomeClientSite *client_site);
GnomeCanvasItem *gnome_client_site_new_item (GnomeClientSite *client_site,
[Date Prev][
Date Next] [Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]