[Spice-devel] [PATCH spice-gtk 2/4] SpiceDisplay: mark clipboard properties and functions as deprecated
Hans de Goede
hdegoede at redhat.com
Mon Oct 10 07:35:10 PDT 2011
The SpiceGtkSession ones should be used instead.
Signed-off-by: Hans de Goede <hdegoede at redhat.com>
---
gtk/spice-gtk-session.c | 20 +++++++++++++-------
gtk/spice-widget.c | 11 ++++++-----
2 files changed, 19 insertions(+), 12 deletions(-)
diff --git a/gtk/spice-gtk-session.c b/gtk/spice-gtk-session.c
index d3cdd7d..c7f9be7 100644
--- a/gtk/spice-gtk-session.c
+++ b/gtk/spice-gtk-session.c
@@ -56,13 +56,10 @@ struct _SpiceGtkSessionPrivate {
* and #SpiceSession objects. Therefor there is no spice_gtk_session_new,
* instead there is spice_gtk_session_get() which ensures this 1:1 relation.
*
- * #SpiceDisplay uses #SpiceGtkSession internally, some #SpiceDisplay
- * properties map directly to #SpiceGtkSession properties, this means that
- * changing them for one #SpiceDisplay changes them for all displays.
- *
- * Depending on your UI, you may want to not show these properties on a
- * per display basis and instead show them in a global settings menu which
- * directly uses SpiceGtkSession.
+ * Client and guest clipboards will be shared automatically if
+ * #SpiceGtkSession:auto-clipboard is set to #TRUE. Alternatively, you
+ * can send / receive clipboard data from client to guest with
+ * spice_gtk_session_copy_to_guest() / spice_gtk_session_paste_from_guest().
*/
/* ------------------------------------------------------------------ */
@@ -247,6 +244,7 @@ static void spice_gtk_session_class_init(SpiceGtkSessionClass *klass)
*
* #SpiceSession this #SpiceGtkSession is associated with
*
+ * Since: 0.8
**/
g_object_class_install_property
(gobject_class, PROP_SESSION,
@@ -263,6 +261,8 @@ static void spice_gtk_session_class_init(SpiceGtkSessionClass *klass)
*
* When this is true the clipboard gets automatically shared between host
* and guest.
+ *
+ * Since: 0.8
**/
g_object_class_install_property
(gobject_class, PROP_AUTO_CLIPBOARD,
@@ -742,6 +742,8 @@ static void channel_destroy(SpiceSession *session, SpiceChannel *channel,
* after the #SpiceSession itself has been unref-ed by the caller.
*
* Returns: (transfer none): a weak reference to the #SpiceGtkSession associated with the passed in #SpiceSession
+ *
+ * Since 0.8
**/
SpiceGtkSession *spice_gtk_session_get(SpiceSession *session)
{
@@ -768,6 +770,8 @@ SpiceGtkSession *spice_gtk_session_get(SpiceSession *session)
* @self:
*
* Copy client-side clipboard to guest clipboard.
+ *
+ * Since 0.8
**/
void spice_gtk_session_copy_to_guest(SpiceGtkSession *self)
{
@@ -785,6 +789,8 @@ void spice_gtk_session_copy_to_guest(SpiceGtkSession *self)
* @self:
*
* Copy guest clipboard to client-side clipboard.
+ *
+ * Since 0.8
**/
void spice_gtk_session_paste_from_guest(SpiceGtkSession *self)
{
diff --git a/gtk/spice-widget.c b/gtk/spice-widget.c
index fe7dba6..15a2b61 100644
--- a/gtk/spice-widget.c
+++ b/gtk/spice-widget.c
@@ -68,11 +68,6 @@ static inline void gdk_drawable_get_size(GdkWindow *w, gint *ww, gint *wh)
* ungrabbed with spice_display_mouse_ungrab(), and by setting a key
* combination with spice_display_set_grab_keys().
*
- * Client and guest clipboards will be shared automatically if
- * #SpiceDisplay:auto-clipboard is set to #TRUE. Alternatively, you
- * can send clipboard data from client to guest with
- * spice_display_copy_to_guest().
-
* Finally, spice_display_get_pixbuf() will take a screenshot of the
* current display and return an #GdkPixbuf (that you can then easily
* save to disk).
@@ -1222,6 +1217,8 @@ static void spice_display_class_init(SpiceDisplayClass *klass)
*
* When this is true the clipboard gets automatically shared between host
* and guest.
+ *
+ * Deprecated: 0.8: Use #SpiceGtkSession's auto-clipboard property instead
**/
g_object_class_install_property
(gobject_class, PROP_AUTO_CLIPBOARD,
@@ -1678,6 +1675,8 @@ void spice_display_mouse_ungrab(SpiceDisplay *display)
* @display:
*
* Copy client-side clipboard to guest clipboard.
+ *
+ * Deprecated: 0.8: Use spice_gtk_session_copy_to_guest() instead
**/
void spice_display_copy_to_guest(SpiceDisplay *display)
{
@@ -1693,6 +1692,8 @@ void spice_display_copy_to_guest(SpiceDisplay *display)
* @display:
*
* Copy guest clipboard to client-side clipboard.
+ *
+ * Deprecated: 0.8: Use spice_gtk_session_paste_from_guest() instead
**/
void spice_display_paste_from_guest(SpiceDisplay *display)
{
--
1.7.6.4
More information about the Spice-devel
mailing list