# HG changeset patch # User Eric Polino # Date 1183147517 0 # Node ID 7e0379a41a448921188e5e6afc20530c98a3e9fd # Parent 700b642631bc9b6843eced242e486eedc803dd9a# Parent 576edd9c4f7224c05e8826ff355e53a8cdc2e42b propagate from branch 'im.pidgin.pidgin' (head 89468df5d1cdb033902c9f7e41cfdf3a348d97bc) to branch 'im.pidgin.soc.2007.finchfeat' (head aa0595d32b99d229dafb41c7c83e1d1944175f99) diff -r 576edd9c4f72 -r 7e0379a41a44 doc/notify-signals.dox --- a/doc/notify-signals.dox Fri Jun 29 12:45:08 2007 +0000 +++ b/doc/notify-signals.dox Fri Jun 29 20:05:17 2007 +0000 @@ -1,4 +1,4 @@ -/** @page conversation-signals Notification Signals +/** @page notify-signals Notification Signals @signals @signal displaying-userinfo diff -r 576edd9c4f72 -r 7e0379a41a44 finch/gntconv.c diff -r 576edd9c4f72 -r 7e0379a41a44 finch/gntrequest.c diff -r 576edd9c4f72 -r 7e0379a41a44 finch/libgnt/gntkeys.h diff -r 576edd9c4f72 -r 7e0379a41a44 finch/libgnt/gntslider.c --- a/finch/libgnt/gntslider.c Fri Jun 29 12:45:08 2007 +0000 +++ b/finch/libgnt/gntslider.c Fri Jun 29 20:05:17 2007 +0000 @@ -70,11 +70,9 @@ int position, size = 0; if (slider->vertical) - mvwvline(widget->window, 0, 0, ACS_VLINE | COLOR_PAIR(GNT_COLOR_NORMAL), - (size = widget->priv.height)); + size = widget->priv.height; else - mvwhline(widget->window, 0, 0, ACS_HLINE | COLOR_PAIR(GNT_COLOR_NORMAL), - (size = widget->priv.width)); + size = widget->priv.width; if (gnt_widget_has_focus(widget)) attr |= GNT_COLOR_HIGHLIGHT; @@ -85,10 +83,22 @@ position = ((size - 1) * (slider->current - slider->min)) / (slider->max - slider->min); else position = 0; + if (slider->vertical) { + mvwvline(widget->window, size-position, 0, ACS_VLINE | COLOR_PAIR(GNT_COLOR_NORMAL) | A_BOLD, + position); + mvwvline(widget->window, 0, 0, ACS_VLINE | COLOR_PAIR(GNT_COLOR_NORMAL), + size-position); + } else { + mvwhline(widget->window, 0, 0, ACS_HLINE | COLOR_PAIR(GNT_COLOR_NORMAL) | A_BOLD, + position); + mvwhline(widget->window, 0, position, ACS_HLINE | COLOR_PAIR(GNT_COLOR_NORMAL), + size - position); + } + mvwaddch(widget->window, slider->vertical ? (size - position - 1) : 0, slider->vertical ? 0 : position, - ACS_BLOCK | COLOR_PAIR(attr)); + ACS_CKBOARD | COLOR_PAIR(attr)); } static void @@ -117,10 +127,7 @@ GntSlider *slider = GNT_SLIDER(bindable); if (slider->current <= slider->min) return FALSE; - slider->current -= slider->step; - sanitize_value(slider); - redraw_slider(slider); - slider_value_changed(slider); + gnt_slider_advance_step(slider, -1); return TRUE; } @@ -130,10 +137,7 @@ GntSlider *slider = GNT_SLIDER(bindable); if (slider->current >= slider->max) return FALSE; - slider->current += slider->step; - sanitize_value(slider); - redraw_slider(slider); - slider_value_changed(slider); + gnt_slider_advance_step(slider, 1); return TRUE; } diff -r 576edd9c4f72 -r 7e0379a41a44 finch/libgnt/gntstyle.h diff -r 576edd9c4f72 -r 7e0379a41a44 finch/libgnt/gntwidget.c --- a/finch/libgnt/gntwidget.c Fri Jun 29 12:45:08 2007 +0000 +++ b/finch/libgnt/gntwidget.c Fri Jun 29 20:05:17 2007 +0000 @@ -389,7 +389,7 @@ g_signal_emit(widget, signals[SIG_DRAW], 0); gnt_widget_queue_update(widget); - GNT_WIDGET_UNSET_FLAGS(widget, GNT_WIDGET_DRAWING | GNT_WIDGET_INVISIBLE); + GNT_WIDGET_UNSET_FLAGS(widget, GNT_WIDGET_DRAWING); } gboolean diff -r 576edd9c4f72 -r 7e0379a41a44 libpurple/blist.h --- a/libpurple/blist.h Fri Jun 29 12:45:08 2007 +0000 +++ b/libpurple/blist.h Fri Jun 29 20:05:17 2007 +0000 @@ -21,6 +21,8 @@ * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * + * @see @ref blist-signals */ #ifndef _PURPLE_BLIST_H_ #define _PURPLE_BLIST_H_ diff -r 576edd9c4f72 -r 7e0379a41a44 libpurple/cipher.h --- a/libpurple/cipher.h Fri Jun 29 12:45:08 2007 +0000 +++ b/libpurple/cipher.h Fri Jun 29 20:05:17 2007 +0000 @@ -21,6 +21,8 @@ * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * + * @see @ref cipher-signals */ #ifndef PURPLE_CIPHER_H #define PURPLE_CIPHER_H diff -r 576edd9c4f72 -r 7e0379a41a44 libpurple/core.h --- a/libpurple/core.h Fri Jun 29 12:45:08 2007 +0000 +++ b/libpurple/core.h Fri Jun 29 20:05:17 2007 +0000 @@ -20,6 +20,8 @@ * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * + * @see @ref core-signals */ #ifndef _PURPLE_CORE_H_ #define _PURPLE_CORE_H_ diff -r 576edd9c4f72 -r 7e0379a41a44 libpurple/dbus-server.h --- a/libpurple/dbus-server.h Fri Jun 29 12:45:08 2007 +0000 +++ b/libpurple/dbus-server.h Fri Jun 29 20:05:17 2007 +0000 @@ -22,6 +22,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * + * @see @ref dbus-server-signals */ #ifndef _PURPLE_DBUS_SERVER_H_ diff -r 576edd9c4f72 -r 7e0379a41a44 libpurple/imgstore.c --- a/libpurple/imgstore.c Fri Jun 29 12:45:08 2007 +0000 +++ b/libpurple/imgstore.c Fri Jun 29 20:05:17 2007 +0000 @@ -55,8 +55,8 @@ { PurpleStoredImage *img; - g_return_val_if_fail(data != NULL, 0); - g_return_val_if_fail(size > 0, 0); + g_return_val_if_fail(data != NULL, NULL); + g_return_val_if_fail(size > 0, NULL); img = g_new(PurpleStoredImage, 1); PURPLE_DBUS_REGISTER_POINTER(img, PurpleStoredImage); @@ -73,11 +73,13 @@ purple_imgstore_add_with_id(gpointer data, size_t size, const char *filename) { PurpleStoredImage *img = purple_imgstore_add(data, size, filename); - img->id = ++nextid; + if (img) { + img->id = ++nextid; - g_hash_table_insert(imgstore, &(img->id), img); + g_hash_table_insert(imgstore, &(img->id), img); + } - return img->id; + return (img ? img->id : 0); } PurpleStoredImage *purple_imgstore_find_by_id(int id) { diff -r 576edd9c4f72 -r 7e0379a41a44 libpurple/imgstore.h --- a/libpurple/imgstore.h Fri Jun 29 12:45:08 2007 +0000 +++ b/libpurple/imgstore.h Fri Jun 29 20:05:17 2007 +0000 @@ -22,6 +22,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * + * @see @ref imgstore-signals */ #ifndef _PURPLE_IMGSTORE_H_ #define _PURPLE_IMGSTORE_H_ diff -r 576edd9c4f72 -r 7e0379a41a44 libpurple/log.h --- a/libpurple/log.h Fri Jun 29 12:45:08 2007 +0000 +++ b/libpurple/log.h Fri Jun 29 20:05:17 2007 +0000 @@ -21,6 +21,8 @@ * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * + * @see @ref log-signals */ #ifndef _PURPLE_LOG_H_ #define _PURPLE_LOG_H_ diff -r 576edd9c4f72 -r 7e0379a41a44 libpurple/notify.h --- a/libpurple/notify.h Fri Jun 29 12:45:08 2007 +0000 +++ b/libpurple/notify.h Fri Jun 29 20:05:17 2007 +0000 @@ -21,6 +21,8 @@ * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * + * @see @ref notify-signals */ #ifndef _PURPLE_NOTIFY_H_ #define _PURPLE_NOTIFY_H_ diff -r 576edd9c4f72 -r 7e0379a41a44 libpurple/plugin.h --- a/libpurple/plugin.h Fri Jun 29 12:45:08 2007 +0000 +++ b/libpurple/plugin.h Fri Jun 29 20:05:17 2007 +0000 @@ -21,6 +21,10 @@ * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * + * @see @ref plugin-signals + * @see @ref plugin-ids + * @see @ref plugin-i18n */ #ifndef _PURPLE_PLUGIN_H_ #define _PURPLE_PLUGIN_H_ diff -r 576edd9c4f72 -r 7e0379a41a44 libpurple/protocols/yahoo/yahoochat.c --- a/libpurple/protocols/yahoo/yahoochat.c Fri Jun 29 12:45:08 2007 +0000 +++ b/libpurple/protocols/yahoo/yahoochat.c Fri Jun 29 20:05:17 2007 +0000 @@ -785,44 +785,6 @@ g_free(eroom); } -/* borrowed from gtkconv.c */ -static gboolean -meify(char *message, size_t len) -{ - /* - * Read /me-ify: If the message (post-HTML) starts with /me, - * remove the "/me " part of it (including that space) and return TRUE. - */ - char *c; - gboolean inside_html = 0; - - /* Umm.. this would be very bad if this happens. */ - g_return_val_if_fail(message != NULL, FALSE); - - if (len == -1) - len = strlen(message); - - for (c = message; *c != '\0'; c++, len--) { - if (inside_html) { - if (*c == '>') - inside_html = FALSE; - } - else { - if (*c == '<') - inside_html = TRUE; - else - break; - } - } - - if (*c != '\0' && !g_ascii_strncasecmp(c, "/me ", 4)) { - memmove(c, c + 4, len - 3); - return TRUE; - } - - return FALSE; -} - static int yahoo_chat_send(PurpleConnection *gc, const char *dn, const char *room, const char *what, PurpleMessageFlags flags) { struct yahoo_data *yd = gc->proto_data; @@ -839,7 +801,7 @@ msg1 = g_strdup(what); - if (meify(msg1, -1)) + if (purple_message_meify(msg1, -1)) me = 1; msg2 = yahoo_html_to_codes(msg1); diff -r 576edd9c4f72 -r 7e0379a41a44 libpurple/savedstatuses.h --- a/libpurple/savedstatuses.h Fri Jun 29 12:45:08 2007 +0000 +++ b/libpurple/savedstatuses.h Fri Jun 29 20:05:17 2007 +0000 @@ -21,6 +21,8 @@ * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * + * @see @ref savedstatus-signals */ #ifndef _PURPLE_SAVEDSTATUSES_H_ #define _PURPLE_SAVEDSTATUSES_H_ diff -r 576edd9c4f72 -r 7e0379a41a44 libpurple/sound.h --- a/libpurple/sound.h Fri Jun 29 12:45:08 2007 +0000 +++ b/libpurple/sound.h Fri Jun 29 20:05:17 2007 +0000 @@ -21,6 +21,8 @@ * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * + * @see @ref sound-signals */ #ifndef _PURPLE_SOUND_H_ #define _PURPLE_SOUND_H_ diff -r 576edd9c4f72 -r 7e0379a41a44 libpurple/util.h --- a/libpurple/util.h Fri Jun 29 12:45:08 2007 +0000 +++ b/libpurple/util.h Fri Jun 29 20:05:17 2007 +0000 @@ -1105,12 +1105,13 @@ void purple_print_utf8_to_console(FILE *filestream, char *message); /** - * Checks for messages starting with "/me " + * Checks for messages starting (post-HTML) with "/me ", including the space. * * @param message The message to check * @param len The message length, or -1 * - * @return TRUE if it starts with /me, and it has been removed, otherwise FALSE + * @return TRUE if it starts with "/me ", and it has been removed, otherwise + * FALSE */ gboolean purple_message_meify(char *message, size_t len);