diff options
author | Cosimo Cecchi <cosimoc@gnome.org> | 2009-09-17 20:04:25 +0800 |
---|---|---|
committer | Cosimo Cecchi <cosimoc@gnome.org> | 2009-09-17 20:04:25 +0800 |
commit | 5c9327240c2c1498a3441a8462d13ae479a0fae2 (patch) | |
tree | cda97a11d36700a37c6034d9522972a64ec8579c | |
parent | 847aa7cd822ea23d0619ebfdfcbee61ad374c42c (diff) | |
download | gsoc2013-empathy-5c9327240c2c1498a3441a8462d13ae479a0fae2.tar gsoc2013-empathy-5c9327240c2c1498a3441a8462d13ae479a0fae2.tar.gz gsoc2013-empathy-5c9327240c2c1498a3441a8462d13ae479a0fae2.tar.bz2 gsoc2013-empathy-5c9327240c2c1498a3441a8462d13ae479a0fae2.tar.lz gsoc2013-empathy-5c9327240c2c1498a3441a8462d13ae479a0fae2.tar.xz gsoc2013-empathy-5c9327240c2c1498a3441a8462d13ae479a0fae2.tar.zst gsoc2013-empathy-5c9327240c2c1498a3441a8462d13ae479a0fae2.zip |
Don't paste if the remote contact is disconnected (#595417).
-rw-r--r-- | libempathy-gtk/empathy-chat.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/libempathy-gtk/empathy-chat.c b/libempathy-gtk/empathy-chat.c index c08b49c3f..d62537110 100644 --- a/libempathy-gtk/empathy-chat.c +++ b/libempathy-gtk/empathy-chat.c @@ -1957,9 +1957,16 @@ empathy_chat_paste (EmpathyChat *chat) { GtkTextBuffer *buffer; GtkClipboard *clipboard; + EmpathyChatPriv *priv; g_return_if_fail (EMPATHY_IS_CHAT (chat)); + priv = GET_PRIV (chat); + + if (priv->tp_chat == NULL || + !GTK_WIDGET_IS_SENSITIVE (chat->input_text_view)) + return; + buffer = gtk_text_view_get_buffer (GTK_TEXT_VIEW (chat->input_text_view)); clipboard = gtk_clipboard_get (GDK_SELECTION_CLIPBOARD); |