You can subscribe to this list here.
2001 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
(106) |
Oct
(334) |
Nov
(246) |
Dec
(145) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2002 |
Jan
(42) |
Feb
(53) |
Mar
(232) |
Apr
(109) |
May
(137) |
Jun
(63) |
Jul
(26) |
Aug
(263) |
Sep
(193) |
Oct
(507) |
Nov
(440) |
Dec
(241) |
2003 |
Jan
(567) |
Feb
(195) |
Mar
(504) |
Apr
(481) |
May
(524) |
Jun
(522) |
Jul
(594) |
Aug
(502) |
Sep
(643) |
Oct
(508) |
Nov
(430) |
Dec
(377) |
2004 |
Jan
(361) |
Feb
(251) |
Mar
(219) |
Apr
(499) |
May
(461) |
Jun
(419) |
Jul
(314) |
Aug
(519) |
Sep
(416) |
Oct
(247) |
Nov
(305) |
Dec
(382) |
2005 |
Jan
(267) |
Feb
(282) |
Mar
(327) |
Apr
(338) |
May
(189) |
Jun
(400) |
Jul
(462) |
Aug
(530) |
Sep
(316) |
Oct
(523) |
Nov
(481) |
Dec
(650) |
2006 |
Jan
(536) |
Feb
(361) |
Mar
(287) |
Apr
(146) |
May
(101) |
Jun
(169) |
Jul
(221) |
Aug
(498) |
Sep
(300) |
Oct
(236) |
Nov
(209) |
Dec
(205) |
2007 |
Jan
(30) |
Feb
(23) |
Mar
(26) |
Apr
(15) |
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
From: <fac...@us...> - 2006-10-24 17:30:18
|
Revision: 17575 http://svn.sourceforge.net/gaim/?rev=17575&view=rev Author: faceprint Date: 2006-10-24 10:29:59 -0700 (Tue, 24 Oct 2006) Log Message: ----------- removed Modified Paths: -------------- trunk/po/POTFILES.in Modified: trunk/po/POTFILES.in =================================================================== --- trunk/po/POTFILES.in 2006-10-24 15:29:19 UTC (rev 17574) +++ trunk/po/POTFILES.in 2006-10-24 17:29:59 UTC (rev 17575) @@ -61,7 +61,6 @@ gtk/gtkwhiteboard.c gtk/plugins/cap/cap.c gtk/plugins/contact_priority.c -gtk/plugins/docklet/docklet.c gtk/plugins/extplacement.c gtk/plugins/gaiminc.c gtk/plugins/gaimrc.c This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ebl...@us...> - 2006-10-24 15:29:27
|
Revision: 17574 http://svn.sourceforge.net/gaim/?rev=17574&view=rev Author: eblanton Date: 2006-10-24 08:29:19 -0700 (Tue, 24 Oct 2006) Log Message: ----------- I am under the impression that our gstreamer support requires 0.10 or newer; someone in #gaim was bit by building a src.rpm into a binary that was happy, but then failing to have sound support. Someone (nosnilmot?) correct this if it's wrong. Modified Paths: -------------- trunk/gaim.spec.in Modified: trunk/gaim.spec.in =================================================================== --- trunk/gaim.spec.in 2006-10-24 03:37:46 UTC (rev 17573) +++ trunk/gaim.spec.in 2006-10-24 15:29:19 UTC (rev 17574) @@ -30,7 +30,7 @@ BuildRequires: libtool, pkgconfig, intltool, gettext, libxml2-devel %{?_with_avahi:BuildRequires: avahi-compat-howl-devel} %{?_with_dbus:BuildRequires: dbus-devel >= 0.35} -%{!?_without_gstreamer:BuildRequires: gstreamer-devel} +%{!?_without_gstreamer:BuildRequires: gstreamer-devel >= 0.10} %{!?_without_gtkspell:BuildRequires: gtkspell-devel} %{?_with_howl:BuildRequires: howl-devel} %{?_with_meanwhile:BuildRequires: meanwhile-devel} This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <rl...@us...> - 2006-10-24 03:37:52
|
Revision: 17573 http://svn.sourceforge.net/gaim/?rev=17573&view=rev Author: rlaager Date: 2006-10-23 20:37:46 -0700 (Mon, 23 Oct 2006) Log Message: ----------- Revert my previous change here, and re-fix the issue mentioned in SF Bug #1573887. Basically, I ended up special-casing u' so that u're and u'll will correct properly. This doesn't know the difference between U'LL and U'll, but I'm not terribly concerned about it. I think it'll be more coding than it's worth. If you really want me to fix that, speak up. Modified Paths: -------------- trunk/gtk/plugins/spellchk.c Modified: trunk/gtk/plugins/spellchk.c =================================================================== --- trunk/gtk/plugins/spellchk.c 2006-10-24 01:09:13 UTC (rev 17572) +++ trunk/gtk/plugins/spellchk.c 2006-10-24 03:37:46 UTC (rev 17573) @@ -298,6 +298,7 @@ g_free(spell); } +/* Pango doesn't know about the "'" character. Let's fix that. */ static gboolean spellchk_inside_word(GtkTextIter *iter) { @@ -326,8 +327,36 @@ if (gtk_text_iter_inside_word (iter) == TRUE) return TRUE; + if (c == '\'') { + gboolean result = gtk_text_iter_backward_char(iter); + gboolean output = gtk_text_iter_inside_word(iter); + + if (result) + { + /* + * Hack so that "u'll" will correct correctly. + */ + ucs4_char = gtk_text_iter_get_char(iter); + utf8_str = g_ucs4_to_utf8(&ucs4_char, 1, NULL, NULL, NULL); + if (utf8_str != NULL) + { + c = utf8_str[0]; + g_free(utf8_str); + + if (c == 'u' || c == 'U') + { + gtk_text_iter_forward_char(iter); + return FALSE; + } + } + + gtk_text_iter_forward_char(iter); + } + + return output; + } + return FALSE; - } static gboolean This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <sea...@us...> - 2006-10-24 01:09:22
|
Revision: 17572 http://svn.sourceforge.net/gaim/?rev=17572&view=rev Author: seanegan Date: 2006-10-23 18:09:13 -0700 (Mon, 23 Oct 2006) Log Message: ----------- blog post about things to change from beta4 Added Paths: ----------- web/htdocs/sean/posts/beta4.txt Added: web/htdocs/sean/posts/beta4.txt =================================================================== --- web/htdocs/sean/posts/beta4.txt (rev 0) +++ web/htdocs/sean/posts/beta4.txt 2006-10-24 01:09:13 UTC (rev 17572) @@ -0,0 +1,9 @@ +Beta4 +Hey, Gaim fans. You've probably noticed we released beta4 last week. We plan on following up real soon with +another beta that addresses some of the issues in beta4, principly: +<ul> +<li>On some Windows systems, beta4 is ridiculously slow. This is caused by a bug in our network detection code, and we have the fix ready to go</li> +<li>Some people hate---<i>hate</i>---the "system tray icon" flashing. We'll add a check item in the icon's context menu to turn on and off flashing. We'll probably +also add an option to control when the tray icon is visible: always, never, only when you have unread messages.</li> +</ul> +We'll probably do this tomorrow. Property changes on: web/htdocs/sean/posts/beta4.txt ___________________________________________________________________ Name: svn:mime-type + text/plain Name: svn:eol-style + native This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <de...@us...> - 2006-10-23 23:30:19
|
Revision: 17571 http://svn.sourceforge.net/gaim/?rev=17571&view=rev Author: deryni9 Date: 2006-10-23 16:30:15 -0700 (Mon, 23 Oct 2006) Log Message: ----------- 18:40:29 <casted> Hi, I found a bug in the gaim-remote script 18:41:48 <casted> ok. On line 104 it is currently: status_type = gaim.GaimSavedStatusGetType(current) 18:41:57 <casted> but should be: status_type = gaim.GaimSavedstatusGetType(current) 18:42:06 <casted> the status must be lowercase Modified Paths: -------------- trunk/COPYRIGHT trunk/libgaim/gaim-remote Modified: trunk/COPYRIGHT =================================================================== --- trunk/COPYRIGHT 2006-10-23 20:25:16 UTC (rev 17570) +++ trunk/COPYRIGHT 2006-10-23 23:30:15 UTC (rev 17571) @@ -45,6 +45,7 @@ Thomas Butter Andrea Canciani Michael Carlson +Keegan Carruthers-Smith Steve Cavilia Julien Cegarra Cerulean Studios, LLC Modified: trunk/libgaim/gaim-remote =================================================================== --- trunk/libgaim/gaim-remote 2006-10-23 20:25:16 UTC (rev 17570) +++ trunk/libgaim/gaim-remote 2006-10-23 23:30:15 UTC (rev 17571) @@ -101,7 +101,7 @@ status_id = params["status"] status_type = gaim.GaimPrimitiveGetTypeFromId(status_id) else: - status_type = gaim.GaimSavedStatusGetType(current) + status_type = gaim.GaimSavedstatusGetType(current) status_id = gaim.GaimPrimitiveGetIdFromType(status_type) if "message" in params: This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <dat...@us...> - 2006-10-23 20:25:27
|
Revision: 17570 http://svn.sourceforge.net/gaim/?rev=17570&view=rev Author: datallah Date: 2006-10-23 13:25:16 -0700 (Mon, 23 Oct 2006) Log Message: ----------- Add a wingaim only preference to disable the IM conv. flashing. Modified Paths: -------------- trunk/gtk/gtkprefs.c trunk/gtk/win32/gtkwin32dep.c Modified: trunk/gtk/gtkprefs.c =================================================================== --- trunk/gtk/gtkprefs.c 2006-10-23 20:21:54 UTC (rev 17569) +++ trunk/gtk/gtkprefs.c 2006-10-23 20:25:16 UTC (rev 17570) @@ -851,6 +851,10 @@ gaim_gtk_prefs_checkbox(_("Use smooth-scrolling"), "/gaim/gtk/conversations/use_smooth_scrolling", vbox); +#ifdef _WIN32 + gaim_gtk_prefs_checkbox(_("F_lash window when IMs are received"), "/gaim/gtk/win32/blink_im", vbox); +#endif + frame = gaim_gtk_create_imhtml(TRUE, &imhtml, &toolbar, NULL); gtk_widget_set_name(imhtml, "gaim_gtkprefs_font_imhtml"); gtk_imhtml_set_whole_buffer_formatting_only(GTK_IMHTML(imhtml), TRUE); Modified: trunk/gtk/win32/gtkwin32dep.c =================================================================== --- trunk/gtk/win32/gtkwin32dep.c 2006-10-23 20:21:54 UTC (rev 17569) +++ trunk/gtk/win32/gtkwin32dep.c 2006-10-23 20:25:16 UTC (rev 17570) @@ -267,7 +267,8 @@ gtkwgaim_conv_im_blink(GaimAccount *account, const char *who, char **message, GaimConversation *conv, GaimMessageFlags flags, void *data) { - gtkwgaim_conv_blink(conv, flags); + if (gaim_prefs_get_bool("/gaim/gtk/win32/blink_im")) + gtkwgaim_conv_blink(conv, flags); return FALSE; } @@ -294,6 +295,9 @@ void gtkwgaim_post_init(void) { + gaim_prefs_add_none("/gaim/gtk/win32"); + gaim_prefs_add_bool("/gaim/gtk/win32/blink_im", TRUE); + gaim_signal_connect(gaim_gtk_conversations_get_handle(), "displaying-im-msg", >kwin32_handle, GAIM_CALLBACK(gtkwgaim_conv_im_blink), NULL); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <mar...@us...> - 2006-10-23 20:22:10
|
Revision: 17569 http://svn.sourceforge.net/gaim/?rev=17569&view=rev Author: markhuetsch Date: 2006-10-23 13:21:54 -0700 (Mon, 23 Oct 2006) Log Message: ----------- Let qq compile on Solaris. Patch thanks to Torrey McMahon (tmcmahon2) and Taso N. Devetzis (devetzis). Modified Paths: -------------- trunk/libgaim/protocols/qq/file_trans.c trunk/libgaim/protocols/qq/send_file.c trunk/libgaim/protocols/qq/send_file.h Modified: trunk/libgaim/protocols/qq/file_trans.c =================================================================== --- trunk/libgaim/protocols/qq/file_trans.c 2006-10-23 19:43:45 UTC (rev 17568) +++ trunk/libgaim/protocols/qq/file_trans.c 2006-10-23 20:21:54 UTC (rev 17569) @@ -218,8 +218,8 @@ static int _qq_xfer_open_file(const gchar *filename, const gchar *method, GaimXfer *xfer) { ft_info *info = xfer->data; - info->dest_fp = fopen(gaim_xfer_get_local_filename(xfer), method); - if (info->dest_fp == NULL) { + info->u.dest_fp = fopen(gaim_xfer_get_local_filename(xfer), method); + if (info->u.dest_fp == NULL) { return -1; } return 0; @@ -229,22 +229,22 @@ { ft_info *info = xfer->data; - fseek(info->dest_fp, index * len, SEEK_SET); - return fread(buffer, 1, len, info->dest_fp); + fseek(info->u.dest_fp, index * len, SEEK_SET); + return fread(buffer, 1, len, info->u.dest_fp); } static gint _qq_xfer_write_file(guint8 *buffer, guint index, guint len, GaimXfer *xfer) { ft_info *info = xfer->data; - fseek(info->dest_fp, index * len, SEEK_SET); - return fwrite(buffer, 1, len, info->dest_fp); + fseek(info->u.dest_fp, index * len, SEEK_SET); + return fwrite(buffer, 1, len, info->u.dest_fp); } void qq_xfer_close_file(GaimXfer *xfer) { ft_info *info = xfer->data; - if (info->dest_fp) fclose(info->dest_fp); + if (info->u.dest_fp) fclose(info->u.dest_fp); } #endif Modified: trunk/libgaim/protocols/qq/send_file.c =================================================================== --- trunk/libgaim/protocols/qq/send_file.c 2006-10-23 19:43:45 UTC (rev 17568) +++ trunk/libgaim/protocols/qq/send_file.c 2006-10-23 20:21:54 UTC (rev 17569) @@ -204,8 +204,8 @@ info = (ft_info *) xfer->data; qq_xfer_close_file(xfer); - if (info->dest_fp != NULL) { - fclose(info->dest_fp); + if (info->u.dest_fp != NULL) { + fclose(info->u.dest_fp); gaim_debug(GAIM_DEBUG_INFO, "QQ", "file closed\n"); } if (info->major_fd != 0) { Modified: trunk/libgaim/protocols/qq/send_file.h =================================================================== --- trunk/libgaim/protocols/qq/send_file.h 2006-10-23 19:43:45 UTC (rev 17568) +++ trunk/libgaim/protocols/qq/send_file.h 2006-10-23 20:21:54 UTC (rev 17569) @@ -40,7 +40,7 @@ union { FILE *dest_fp; guint8 *buffer; - }; + } u; gboolean use_major; } ft_info; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <sea...@us...> - 2006-10-23 19:43:52
|
Revision: 17568 http://svn.sourceforge.net/gaim/?rev=17568&view=rev Author: seanegan Date: 2006-10-23 12:43:45 -0700 (Mon, 23 Oct 2006) Log Message: ----------- I'm an idiot. Modified Paths: -------------- trunk/gtk/gtkblist.c trunk/gtk/gtkblist.h trunk/gtk/gtknotify.c trunk/gtk/gtkstatusbox.c trunk/gtk/gtkstatusbox.h Modified: trunk/gtk/gtkblist.c =================================================================== --- trunk/gtk/gtkblist.c 2006-10-23 19:05:14 UTC (rev 17567) +++ trunk/gtk/gtkblist.c 2006-10-23 19:43:45 UTC (rev 17568) @@ -2078,7 +2078,6 @@ GdkPixbuf *status_icon; GdkPixbuf *avatar; int avatar_width; - int avatar_height; int width; int height; }; @@ -2102,7 +2101,6 @@ if(td->avatar) { td->avatar_width = gdk_pixbuf_get_width(td->avatar); - td->avatar_height = gdk_pixbuf_get_height(td->avatar); td->width += td->avatar_width + 8; td->height = MAX(td->height, gdk_pixbuf_get_height(td->avatar) + 8); } @@ -2136,8 +2134,6 @@ { struct tooltip_data *td = l->data; - - #if GTK_CHECK_VERSION(2,2,0) gdk_draw_pixbuf(GDK_DRAWABLE(gtkblist->tipwindow->window), NULL, td->status_icon, 0, 0, 4, current_height, -1 , -1, GDK_RGB_DITHER_NONE, 0, 0); @@ -2152,7 +2148,7 @@ max_width - (td->avatar_width + 4), current_height, -1, -1, GDK_RGB_DITHER_NONE, 0, 0); #endif - + gtk_paint_layout (style, gtkblist->tipwindow->window, GTK_STATE_NORMAL, FALSE, NULL, gtkblist->tipwindow, "tooltip", 38 + 4, current_height, td->layout); @@ -3864,10 +3860,6 @@ create_connection_error_buttons, NULL); } -void gaim_gtk_blist_add_alert(GtkWidget *alert) { - gtk_notebook_append_page(gtkblist->alert_notebook, alert, NULL); -} - /******************************************/ /* End of connection error handling stuff */ /******************************************/ @@ -3880,8 +3872,6 @@ GtkWidget *menu; GtkWidget *sw; GtkWidget *sep; - GtkWidget *hbox; - GtkWidget *label, *arrow; GtkAccelGroup *accel_group; GtkTreeSelection *selection; GtkTargetEntry dte[] = {{"GAIM_BLIST_NODE", GTK_TARGET_SAME_APP, DRAG_ROW}, @@ -4086,22 +4076,6 @@ gtkblist->error_buttons = gtk_vbox_new(FALSE, 0); gtk_box_pack_start(GTK_BOX(gtkblist->vbox), gtkblist->error_buttons, FALSE, FALSE, 0); - /* Create an area for showing buddy list alerts */ - hbox = gtk_hbox_new(FALSE,0); - gtk_box_pack_start(GTK_BOX(gtkblist->vbox), hbox, FALSE, FALSE, 0); - arrow = gtk_arrow_new(GTK_ARROW_RIGHT,GTK_SHADOW_NONE); - gtk_box_pack_end(GTK_BOX(hbox),arrow,FALSE,FALSE,0); - label = gtk_label_new(NULL); - gtk_label_set_markup(GTK_LABEL(label), "<span size='smaller'><b>(2/3)</b></span>"); - gtk_box_pack_end(GTK_BOX(hbox),label,FALSE,FALSE,0); - arrow = gtk_arrow_new(GTK_ARROW_LEFT,GTK_SHADOW_NONE); - gtk_box_pack_end(GTK_BOX(hbox),arrow,FALSE,FALSE,0); - - gtkblist->alert_notebook = gtk_notebook_new(); - gtk_notebook_set_show_tabs(GTK_NOTEBOOK(gtkblist->alert_notebook), FALSE); - gtk_notebook_set_show_border(GTK_NOTEBOOK(gtkblist->alert_notebook), FALSE); - gtk_box_pack_start(GTK_BOX(gtkblist->vbox), gtkblist->alert_notebook, FALSE, FALSE, 0); - /* Add the statusbox */ gtkblist->statusbox = gtk_gaim_status_box_new(); gtk_box_pack_start(GTK_BOX(gtkblist->vbox), gtkblist->statusbox, FALSE, TRUE, 0); Modified: trunk/gtk/gtkblist.h =================================================================== --- trunk/gtk/gtkblist.h 2006-10-23 19:05:14 UTC (rev 17567) +++ trunk/gtk/gtkblist.h 2006-10-23 19:43:45 UTC (rev 17568) @@ -94,8 +94,6 @@ GaimBlistNode *selected_node; /**< The currently selected node */ GtkWidget *error_buttons; /**< Box containing the connection error buttons */ GtkWidget *statusbox; /**< The status selector dropdown */ - - GtkWidget *alert_notebook; /**< The notebook for alerts */ }; #define GAIM_GTK_BLIST(list) ((GaimGtkBuddyList *)(list)->ui_data) @@ -303,11 +301,4 @@ */ void gaim_gtk_blist_update_account_error_state(GaimAccount *account, const char *message); -/** - * Adds a widget to the alert area of the buddy list - * - * @param widget The widget to add - */ -void gaim_gtk_blist_add_alert(GtkWidget *alert); - #endif /* _GAIM_GTKBLIST_H_ */ Modified: trunk/gtk/gtknotify.c =================================================================== --- trunk/gtk/gtknotify.c 2006-10-23 19:05:14 UTC (rev 17567) +++ trunk/gtk/gtknotify.c 2006-10-23 19:43:45 UTC (rev 17568) @@ -196,138 +196,84 @@ g_list_free(row); } - static void * gaim_gtk_notify_message(GaimNotifyMsgType type, const char *title, - const char *primary, const char *secondary) + const char *primary, const char *secondary) { - GtkStyle *style; - GdkColor color; - GtkWidget *ebox; - GtkWidget *vbox; - GtkWidget *hbox; - GtkWidget *bbox; - GtkWidget *label; - GtkWidget *button; - GtkWidget *alignment; - GtkWidget *img = NULL; - GtkStockItem close_item; - char label_text[2048]; - const char *icon_name = NULL; - char *primary_esc, *secondary_esc; + GtkWidget *dialog; + GtkWidget *hbox; + GtkWidget *label; + GtkWidget *img = NULL; + char label_text[2048]; + const char *icon_name = NULL; + char *primary_esc, *secondary_esc; - switch (type) - { - case GAIM_NOTIFY_MSG_ERROR: - icon_name = GAIM_STOCK_DIALOG_ERROR; - break; + switch (type) + { + case GAIM_NOTIFY_MSG_ERROR: + icon_name = GAIM_STOCK_DIALOG_ERROR; + break; - case GAIM_NOTIFY_MSG_WARNING: - icon_name = GAIM_STOCK_DIALOG_WARNING; - break; + case GAIM_NOTIFY_MSG_WARNING: + icon_name = GAIM_STOCK_DIALOG_WARNING; + break; - case GAIM_NOTIFY_MSG_INFO: - icon_name = GAIM_STOCK_DIALOG_INFO; - break; + case GAIM_NOTIFY_MSG_INFO: + icon_name = GAIM_STOCK_DIALOG_INFO; + break; - default: - icon_name = NULL; - break; - } + default: + icon_name = NULL; + break; + } - if (icon_name != NULL) - { - img = gtk_image_new_from_stock(icon_name, GTK_ICON_SIZE_BUTTON); - gtk_misc_set_alignment(GTK_MISC(img), 0, 0); - } + if (icon_name != NULL) + { + img = gtk_image_new_from_stock(icon_name, GTK_ICON_SIZE_DIALOG); + gtk_misc_set_alignment(GTK_MISC(img), 0, 0); + } - ebox = gtk_event_box_new(); - vbox = gtk_vbox_new(FALSE,0); - gtk_container_set_border_width(GTK_CONTAINER(vbox), 6); - color.red = 65535; - // gtk_widget_modify_bg(ebox, GTK_STATE_NORMAL, &(vbox->style->base[GTK_STATE_SELECTED])); - gtk_container_add(GTK_CONTAINER(ebox),vbox); + dialog = gtk_dialog_new_with_buttons(title ? title : GAIM_ALERT_TITLE, + NULL, 0, GTK_STOCK_CLOSE, + GTK_RESPONSE_CLOSE, NULL); - hbox = gtk_hbox_new(FALSE, 0); - gtk_container_add(GTK_CONTAINER(vbox), hbox); + gtk_window_set_role(GTK_WINDOW(dialog), "notify_dialog"); - if (img != NULL) - gtk_box_pack_start(GTK_BOX(hbox), img, FALSE, FALSE, 0); - primary_esc = g_markup_escape_text(primary, -1); - if (secondary) - secondary_esc = g_markup_escape_text(secondary, -1); - g_snprintf(label_text, sizeof(label_text), - "<span weight=\"bold\" size=\"smaller\">%s</span>%s<span size=\"smaller\">%s</span>", - primary_esc, - secondary ? "\n" : "", - secondary ? secondary_esc : ""); - g_free(primary_esc); - label = gtk_label_new(NULL); - gtk_widget_modify_text(vbox, GTK_STATE_NORMAL, &(label->style->white)); - gtk_label_set_markup(GTK_LABEL(label), label_text); - gtk_label_set_line_wrap(GTK_LABEL(label), TRUE); - gtk_misc_set_alignment(GTK_MISC(label), 0, 0); - gtk_box_pack_start(GTK_BOX(hbox), label, TRUE, TRUE, 0); -#if GTK_CHECK_VERSION(2,6,0) - g_object_set(label, "ellipsize", PANGO_ELLIPSIZE_END, NULL); -#endif -#if 0 - if (secondary) { - secondary_esc = g_markup_escape_text(secondary, -1); - g_snprintf(label_text, sizeof(label_text), - "<span size=\"smaller\">%s</span>", - secondary_esc); - g_free(secondary_esc); - label = gtk_label_new(NULL); - gtk_label_set_markup(GTK_LABEL(label), label_text); - gtk_label_set_line_wrap(GTK_LABEL(label), TRUE); - gtk_misc_set_alignment(GTK_MISC(label), 0, 0); - gtk_box_pack_start(GTK_BOX(vbox), label, TRUE, TRUE, 0); -#if GTK_CHECK_VERSION(2,6,0) - g_object_set(label, "ellipsize", PANGO_ELLIPSIZE_END, NULL); -#endif - } -#endif - bbox = gtk_hbutton_box_new(); - gtk_box_pack_start(GTK_BOX(vbox), bbox, FALSE, FALSE, 0); - gtk_button_box_set_layout(GTK_BUTTON_BOX(bbox), GTK_BUTTONBOX_END); + g_signal_connect(G_OBJECT(dialog), "response", + G_CALLBACK(message_response_cb), dialog); - button = gtk_button_new(); - g_signal_connect_swapped(G_OBJECT(button), "activate", gtk_widget_destroy, ebox); - alignment = gtk_alignment_new(0.5, 0.5, 0, 0); - gtk_container_add(GTK_CONTAINER(button), alignment); + gtk_container_set_border_width(GTK_CONTAINER(dialog), GAIM_HIG_BORDER); + gtk_window_set_resizable(GTK_WINDOW(dialog), FALSE); + gtk_dialog_set_has_separator(GTK_DIALOG(dialog), FALSE); + gtk_box_set_spacing(GTK_BOX(GTK_DIALOG(dialog)->vbox), GAIM_HIG_BORDER); + gtk_container_set_border_width(GTK_CONTAINER(GTK_DIALOG(dialog)->vbox), GAIM_HIG_BOX_SPACE); - hbox = gtk_hbox_new(FALSE, 0); - gtk_container_add(GTK_CONTAINER(alignment), hbox); + hbox = gtk_hbox_new(FALSE, GAIM_HIG_BORDER); + gtk_container_add(GTK_CONTAINER(GTK_DIALOG(dialog)->vbox), hbox); - img = gtk_image_new_from_stock(GTK_STOCK_CLOSE, GTK_ICON_SIZE_MENU); - gtk_misc_set_alignment(GTK_MISC(img), 0.5, 0.5); - gtk_box_pack_start(GTK_BOX(hbox), img, FALSE, FALSE, 0); + if (img != NULL) + gtk_box_pack_start(GTK_BOX(hbox), img, FALSE, FALSE, 0); - gtk_stock_lookup(GTK_STOCK_CLOSE, &close_item); - g_snprintf(label_text, sizeof(label_text), - "<span size=\"smaller\">%s</span>", close_item.label); - label = gtk_label_new(NULL); - gtk_misc_set_alignment(GTK_MISC(img), 0.5, 0.5); - gtk_box_pack_start(GTK_BOX(hbox), img, FALSE, FALSE, 0); + primary_esc = g_markup_escape_text(primary, -1); + secondary_esc = (secondary != NULL) ? g_markup_escape_text(secondary, -1) : NULL; + g_snprintf(label_text, sizeof(label_text), + "<span weight=\"bold\" size=\"larger\">%s</span>\n\n%s", + primary_esc, (secondary ? secondary_esc : "")); + g_free(primary_esc); + g_free(secondary_esc); - gtk_stock_lookup(GTK_STOCK_CLOSE, &close_item); - g_snprintf(label_text, sizeof(label_text), - "<span size=\"smaller\">%s</span>", close_item.label); - label = gtk_label_new(NULL); - gtk_misc_set_alignment(GTK_MISC(img), 0.5, 0.5); - gtk_label_set_markup_with_mnemonic(GTK_LABEL(label), label_text); - gtk_box_pack_start(GTK_BOX(hbox), label, FALSE, FALSE, 0); + label = gtk_label_new(NULL); - gtk_container_add(GTK_CONTAINER(bbox), button); + gtk_label_set_markup(GTK_LABEL(label), label_text); + gtk_label_set_line_wrap(GTK_LABEL(label), TRUE); + gtk_misc_set_alignment(GTK_MISC(label), 0, 0); + gtk_box_pack_start(GTK_BOX(hbox), label, FALSE, FALSE, 0); - gtk_widget_show_all(ebox); - gaim_gtk_blist_add_alert(ebox); + gtk_widget_show_all(dialog); - return ebox; + return dialog; } - static void selection_changed_cb(GtkTreeSelection *sel, GaimMailDialog *dialog) { Modified: trunk/gtk/gtkstatusbox.c =================================================================== --- trunk/gtk/gtkstatusbox.c 2006-10-23 19:05:14 UTC (rev 17567) +++ trunk/gtk/gtkstatusbox.c 2006-10-23 19:43:45 UTC (rev 17568) @@ -83,6 +83,10 @@ static void do_colorshift (GdkPixbuf *dest, GdkPixbuf *src, int shift); static void icon_choose_cb(const char *filename, gpointer data); +static void (*combo_box_size_request)(GtkWidget *widget, GtkRequisition *requisition); +static void (*combo_box_size_allocate)(GtkWidget *widget, GtkAllocation *allocation); +static void (*combo_box_forall) (GtkContainer *container, gboolean include_internals, GtkCallback callback, gpointer callback_data); + enum { /** A GtkGaimStatusBoxItemType */ TYPE_COLUMN, @@ -118,7 +122,7 @@ PROP_ICON_SEL, }; -GtkContainer *parent_class = NULL; +GtkComboBoxClass *parent_class = NULL; static void gtk_gaim_status_box_class_init (GtkGaimStatusBoxClass *klass); static void gtk_gaim_status_box_init (GtkGaimStatusBox *status_box); @@ -144,8 +148,8 @@ NULL /* value_table */ }; - status_box_type = g_type_register_static(GTK_TYPE_CONTAINER, - "GtkGaimStatusBox", + status_box_type = g_type_register_static(GTK_TYPE_COMBO_BOX, + "GtkGaimStatusBox", &status_box_info, 0); } @@ -195,7 +199,7 @@ if (status_no != -1) { gtk_widget_set_sensitive(GTK_WIDGET(status_box), FALSE); -// gtk_combo_box_set_active(GTK_COMBO_BOX(status_box), status_no); + gtk_combo_box_set_active(GTK_COMBO_BOX(status_box), status_no); message = gaim_status_get_attr_string(newstatus, "message"); @@ -422,16 +426,23 @@ gtk_gaim_status_box_class_init (GtkGaimStatusBoxClass *klass) { GObjectClass *object_class; + GtkComboBoxClass *combo_class; GtkWidgetClass *widget_class; GtkContainerClass *container_class = (GtkContainerClass*)klass; parent_class = g_type_class_peek_parent(klass); + combo_class = (GtkComboBoxClass*)klass; + combo_class->changed = gtk_gaim_status_box_changed; + widget_class = (GtkWidgetClass*)klass; + combo_box_size_request = widget_class->size_request; widget_class->size_request = gtk_gaim_status_box_size_request; + combo_box_size_allocate = widget_class->size_allocate; widget_class->size_allocate = gtk_gaim_status_box_size_allocate; widget_class->expose_event = gtk_gaim_status_box_expose_event; + combo_box_forall = container_class->forall; container_class->forall = gtk_gaim_status_box_forall; container_class->remove = NULL; @@ -507,17 +518,16 @@ gpointer data; /* Primary (get the status selected in the dropdown) */ -// gtk_combo_box_get_active_iter(GTK_COMBO_BOX(status_box), &iter); -// gtk_tree_model_get(GTK_TREE_MODEL(status_box->dropdown_store), &iter, -// TYPE_COLUMN, &type, -// DATA_COLUMN, &data, -// -1); -// if (type == GTK_GAIM_STATUS_BOX_TYPE_PRIMITIVE) -// primary = g_strdup(gaim_primitive_get_name_from_type(GPOINTER_TO_INT(data))); -// else -// /* This should never happen, but just in case... */ -// primary = g_strdup("New status"); - primary = g_strdup("Available"); + gtk_combo_box_get_active_iter(GTK_COMBO_BOX(status_box), &iter); + gtk_tree_model_get(GTK_TREE_MODEL(status_box->dropdown_store), &iter, + TYPE_COLUMN, &type, + DATA_COLUMN, &data, + -1); + if (type == GTK_GAIM_STATUS_BOX_TYPE_PRIMITIVE) + primary = g_strdup(gaim_primitive_get_name_from_type(GPOINTER_TO_INT(data))); + else + /* This should never happen, but just in case... */ + primary = g_strdup("New status"); } else if (account_status) primary = g_strdup(gaim_status_get_name(gaim_account_get_active_status(acct))); @@ -617,7 +627,7 @@ /* Make sure to activate the only row in the tree view */ path = gtk_tree_path_new_from_string("0"); -// gtk_cell_view_set_displayed_row(GTK_CELL_VIEW(status_box->cell_view), path); + gtk_cell_view_set_displayed_row(GTK_CELL_VIEW(status_box->cell_view), path); gtk_tree_path_free(path); update_size(status_box); @@ -683,7 +693,7 @@ (!gaim_savedstatus_has_substatuses(saved_status))) { index = get_statusbox_index(status_box, saved_status); -// gtk_combo_box_set_active(GTK_COMBO_BOX(status_box), index); + gtk_combo_box_set_active(GTK_COMBO_BOX(status_box), index); } else { @@ -692,7 +702,7 @@ gpointer data; /* Unset the active item */ -// gtk_combo_box_set_active(GTK_COMBO_BOX(status_box), -1); + gtk_combo_box_set_active(GTK_COMBO_BOX(status_box), -1); /* If this saved status is in the list store, then set it as the active item */ if (gtk_tree_model_get_iter_first(GTK_TREE_MODEL(status_box->dropdown_store), &iter)) @@ -720,7 +730,7 @@ || !strcmp(name, acct_status_name)) { /* Found! */ -// gtk_combo_box_set_active_iter(GTK_COMBO_BOX(status_box), &iter); + gtk_combo_box_set_active_iter(GTK_COMBO_BOX(status_box), &iter); g_free(name); break; } @@ -730,7 +740,7 @@ (GPOINTER_TO_INT(data) == gaim_savedstatus_get_creation_time(saved_status))) { /* Found! */ -// gtk_combo_box_set_active_iter(GTK_COMBO_BOX(status_box), &iter); + gtk_combo_box_set_active_iter(GTK_COMBO_BOX(status_box), &iter); break; } } @@ -916,7 +926,7 @@ if (tmp != NULL) g_object_unref(tmp); } -// gtk_combo_box_set_model(GTK_COMBO_BOX(status_box), GTK_TREE_MODEL(status_box->dropdown_store)); + gtk_combo_box_set_model(GTK_COMBO_BOX(status_box), GTK_TREE_MODEL(status_box->dropdown_store)); } static void @@ -933,7 +943,7 @@ icon_size = gtk_icon_size_from_name(GAIM_ICON_SIZE_STATUS_SMALL); /* Unset the model while clearing it */ -// gtk_combo_box_set_model(GTK_COMBO_BOX(status_box), NULL); + gtk_combo_box_set_model(GTK_COMBO_BOX(status_box), NULL); gtk_list_store_clear(status_box->dropdown_store); /* Don't set the model until the new statuses have been added to the box. * What is presumably a bug in Gtk < 2.4 causes things to get all confused @@ -975,7 +985,7 @@ gtk_gaim_status_box_add(GTK_GAIM_STATUS_BOX(status_box), GTK_GAIM_STATUS_BOX_TYPE_SAVED, pixbuf, _("Saved..."), NULL, NULL); if (pixbuf) g_object_unref(G_OBJECT(pixbuf)); -// gtk_combo_box_set_model(GTK_COMBO_BOX(status_box), GTK_TREE_MODEL(status_box->dropdown_store)); + gtk_combo_box_set_model(GTK_COMBO_BOX(status_box), GTK_TREE_MODEL(status_box->dropdown_store)); status_menu_refresh_iter(status_box); } else { @@ -1177,7 +1187,7 @@ static void toggled_cb(GtkWidget *widget, GtkGaimStatusBox *box) { -// gtk_combo_box_popup(GTK_COMBO_BOX(box)); + gtk_combo_box_popup(GTK_COMBO_BOX(box)); gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(box->toggle_button), FALSE); } @@ -1262,9 +1272,9 @@ status_box->store = gtk_list_store_new(NUM_COLUMNS, G_TYPE_INT, GDK_TYPE_PIXBUF, G_TYPE_STRING, G_TYPE_STRING, G_TYPE_STRING, G_TYPE_POINTER); status_box->dropdown_store = gtk_list_store_new(NUM_COLUMNS, G_TYPE_INT, GDK_TYPE_PIXBUF, G_TYPE_STRING, G_TYPE_STRING, G_TYPE_STRING, G_TYPE_POINTER); -// gtk_combo_box_set_model(GTK_COMBO_BOX(status_box), GTK_TREE_MODEL(status_box->dropdown_store)); + gtk_combo_box_set_model(GTK_COMBO_BOX(status_box), GTK_TREE_MODEL(status_box->dropdown_store)); gtk_cell_view_set_model(GTK_CELL_VIEW(status_box->cell_view), GTK_TREE_MODEL(status_box->store)); -// gtk_combo_box_set_wrap_width(GTK_COMBO_BOX(status_box), 0); + gtk_combo_box_set_wrap_width(GTK_COMBO_BOX(status_box), 0); gtk_list_store_append(status_box->store, &(status_box->iter)); gtk_container_add(GTK_CONTAINER(status_box->toggle_button), status_box->hbox); @@ -1278,20 +1288,20 @@ text_rend = gtk_cell_renderer_text_new(); icon_rend = gtk_cell_renderer_pixbuf_new(); -// gtk_cell_layout_pack_start(GTK_CELL_LAYOUT(status_box), icon_rend, FALSE); -// gtk_cell_layout_pack_start(GTK_CELL_LAYOUT(status_box), text_rend, TRUE); -// gtk_cell_layout_set_attributes(GTK_CELL_LAYOUT(status_box), icon_rend, "pixbuf", ICON_COLUMN, NULL); -// gtk_cell_layout_set_attributes(GTK_CELL_LAYOUT(status_box), text_rend, "markup", TEXT_COLUMN, NULL); + gtk_cell_layout_pack_start(GTK_CELL_LAYOUT(status_box), icon_rend, FALSE); + gtk_cell_layout_pack_start(GTK_CELL_LAYOUT(status_box), text_rend, TRUE); + gtk_cell_layout_set_attributes(GTK_CELL_LAYOUT(status_box), icon_rend, "pixbuf", ICON_COLUMN, NULL); + gtk_cell_layout_set_attributes(GTK_CELL_LAYOUT(status_box), text_rend, "markup", TEXT_COLUMN, NULL); #if GTK_CHECK_VERSION(2, 6, 0) g_object_set(text_rend, "ellipsize", PANGO_ELLIPSIZE_END, NULL); #endif status_box->icon_rend = gtk_cell_renderer_pixbuf_new(); status_box->text_rend = gtk_cell_renderer_text_new(); -// gtk_cell_layout_pack_start(GTK_CELL_LAYOUT(status_box->cell_view), status_box->icon_rend, FALSE); -// gtk_cell_layout_pack_start(GTK_CELL_LAYOUT(status_box->cell_view), status_box->text_rend, TRUE); -// gtk_cell_layout_set_attributes(GTK_CELL_LAYOUT(status_box->cell_view), status_box->icon_rend, "pixbuf", ICON_COLUMN, NULL); -// gtk_cell_layout_set_attributes(GTK_CELL_LAYOUT(status_box->cell_view), status_box->text_rend, "markup", TEXT_COLUMN, NULL); + gtk_cell_layout_pack_start(GTK_CELL_LAYOUT(status_box->cell_view), status_box->icon_rend, FALSE); + gtk_cell_layout_pack_start(GTK_CELL_LAYOUT(status_box->cell_view), status_box->text_rend, TRUE); + gtk_cell_layout_set_attributes(GTK_CELL_LAYOUT(status_box->cell_view), status_box->icon_rend, "pixbuf", ICON_COLUMN, NULL); + gtk_cell_layout_set_attributes(GTK_CELL_LAYOUT(status_box->cell_view), status_box->text_rend, "markup", TEXT_COLUMN, NULL); #if GTK_CHECK_VERSION(2, 6, 0) g_object_set(status_box->text_rend, "ellipsize", PANGO_ELLIPSIZE_END, NULL); #endif @@ -1331,7 +1341,7 @@ G_CALLBACK(imhtml_scroll_event_cb), status_box->imhtml); #if GTK_CHECK_VERSION(2,6,0) -// gtk_combo_box_set_row_separator_func(GTK_COMBO_BOX(status_box), dropdown_store_row_separator_func, NULL, NULL); + gtk_combo_box_set_row_separator_func(GTK_COMBO_BOX(status_box), dropdown_store_row_separator_func, NULL, NULL); #endif status_box->token_status_account = check_active_accounts_for_identical_statuses(); @@ -1366,7 +1376,7 @@ GtkRequisition *requisition) { GtkRequisition box_req; - gtk_widget_size_request(GTK_GAIM_STATUS_BOX(widget)->toggle_button, requisition); + combo_box_size_request(widget, requisition); requisition->height += 3; /* If the gtkimhtml is visible, then add some additional padding */ @@ -1428,7 +1438,7 @@ GtkAllocation parent_alc, box_alc, icon_alc; gint border_width = GTK_CONTAINER (widget)->border_width; - gtk_widget_size_request(GTK_GAIM_STATUS_BOX(widget)->toggle_button, &req); + combo_box_size_request(widget, &req); box_alc = *allocation; @@ -1467,6 +1477,7 @@ gtk_widget_size_allocate(status_box->icon_box, &icon_alc); } + combo_box_size_allocate(widget, &parent_alc); gtk_widget_size_allocate(status_box->toggle_button, &parent_alc); widget->allocation = *allocation; } @@ -1500,7 +1511,7 @@ (* callback) (status_box->icon_box, callback_data); } -// combo_box_forall(container, include_internals, callback, callback_data); + combo_box_forall(container, include_internals, callback, callback_data); } GtkWidget * @@ -1713,8 +1724,8 @@ GaimSavedStatus *saved_status = NULL; gboolean changed = TRUE; -// if (!gtk_combo_box_get_active_iter(GTK_COMBO_BOX(status_box), &iter)) -// return; + if (!gtk_combo_box_get_active_iter(GTK_COMBO_BOX(status_box), &iter)) + return; gtk_tree_model_get(GTK_TREE_MODEL(status_box->dropdown_store), &iter, TYPE_COLUMN, &type, @@ -1953,8 +1964,8 @@ status_box = GTK_GAIM_STATUS_BOX(box); -// if (!gtk_combo_box_get_active_iter(GTK_COMBO_BOX(status_box), &iter)) -// return; + if (!gtk_combo_box_get_active_iter(GTK_COMBO_BOX(status_box), &iter)) + return; gtk_tree_model_get(GTK_TREE_MODEL(status_box->dropdown_store), &iter, TYPE_COLUMN, &type, DATA_COLUMN, &data, Modified: trunk/gtk/gtkstatusbox.h =================================================================== --- trunk/gtk/gtkstatusbox.h 2006-10-23 19:05:14 UTC (rev 17567) +++ trunk/gtk/gtkstatusbox.h 2006-10-23 19:43:45 UTC (rev 17568) @@ -65,7 +65,7 @@ struct _GtkGaimStatusBox { - GtkContainer parent_instance; + GtkComboBox parent_instance; /** * This GtkListStore contains only one row--the currently selected status. @@ -131,7 +131,7 @@ struct _GtkGaimStatusBoxClass { - GtkContainerClass parent_class; + GtkComboBoxClass parent_class; /* signals */ void (* changed) (GtkComboBox *combo_box); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <sea...@us...> - 2006-10-23 19:05:35
|
Revision: 17567 http://svn.sourceforge.net/gaim/?rev=17567&view=rev Author: seanegan Date: 2006-10-23 12:05:14 -0700 (Mon, 23 Oct 2006) Log Message: ----------- res_init build fix? Modified Paths: -------------- trunk/gtk/gtkblist.c trunk/gtk/gtkblist.h trunk/gtk/gtknotify.c trunk/gtk/gtkstatusbox.c trunk/gtk/gtkstatusbox.h trunk/libgaim/network.c Modified: trunk/gtk/gtkblist.c =================================================================== --- trunk/gtk/gtkblist.c 2006-10-23 18:10:51 UTC (rev 17566) +++ trunk/gtk/gtkblist.c 2006-10-23 19:05:14 UTC (rev 17567) @@ -2078,6 +2078,7 @@ GdkPixbuf *status_icon; GdkPixbuf *avatar; int avatar_width; + int avatar_height; int width; int height; }; @@ -2101,6 +2102,7 @@ if(td->avatar) { td->avatar_width = gdk_pixbuf_get_width(td->avatar); + td->avatar_height = gdk_pixbuf_get_height(td->avatar); td->width += td->avatar_width + 8; td->height = MAX(td->height, gdk_pixbuf_get_height(td->avatar) + 8); } @@ -2134,6 +2136,8 @@ { struct tooltip_data *td = l->data; + + #if GTK_CHECK_VERSION(2,2,0) gdk_draw_pixbuf(GDK_DRAWABLE(gtkblist->tipwindow->window), NULL, td->status_icon, 0, 0, 4, current_height, -1 , -1, GDK_RGB_DITHER_NONE, 0, 0); @@ -2148,7 +2152,7 @@ max_width - (td->avatar_width + 4), current_height, -1, -1, GDK_RGB_DITHER_NONE, 0, 0); #endif - + gtk_paint_layout (style, gtkblist->tipwindow->window, GTK_STATE_NORMAL, FALSE, NULL, gtkblist->tipwindow, "tooltip", 38 + 4, current_height, td->layout); @@ -3860,6 +3864,10 @@ create_connection_error_buttons, NULL); } +void gaim_gtk_blist_add_alert(GtkWidget *alert) { + gtk_notebook_append_page(gtkblist->alert_notebook, alert, NULL); +} + /******************************************/ /* End of connection error handling stuff */ /******************************************/ @@ -3872,6 +3880,8 @@ GtkWidget *menu; GtkWidget *sw; GtkWidget *sep; + GtkWidget *hbox; + GtkWidget *label, *arrow; GtkAccelGroup *accel_group; GtkTreeSelection *selection; GtkTargetEntry dte[] = {{"GAIM_BLIST_NODE", GTK_TARGET_SAME_APP, DRAG_ROW}, @@ -4076,6 +4086,22 @@ gtkblist->error_buttons = gtk_vbox_new(FALSE, 0); gtk_box_pack_start(GTK_BOX(gtkblist->vbox), gtkblist->error_buttons, FALSE, FALSE, 0); + /* Create an area for showing buddy list alerts */ + hbox = gtk_hbox_new(FALSE,0); + gtk_box_pack_start(GTK_BOX(gtkblist->vbox), hbox, FALSE, FALSE, 0); + arrow = gtk_arrow_new(GTK_ARROW_RIGHT,GTK_SHADOW_NONE); + gtk_box_pack_end(GTK_BOX(hbox),arrow,FALSE,FALSE,0); + label = gtk_label_new(NULL); + gtk_label_set_markup(GTK_LABEL(label), "<span size='smaller'><b>(2/3)</b></span>"); + gtk_box_pack_end(GTK_BOX(hbox),label,FALSE,FALSE,0); + arrow = gtk_arrow_new(GTK_ARROW_LEFT,GTK_SHADOW_NONE); + gtk_box_pack_end(GTK_BOX(hbox),arrow,FALSE,FALSE,0); + + gtkblist->alert_notebook = gtk_notebook_new(); + gtk_notebook_set_show_tabs(GTK_NOTEBOOK(gtkblist->alert_notebook), FALSE); + gtk_notebook_set_show_border(GTK_NOTEBOOK(gtkblist->alert_notebook), FALSE); + gtk_box_pack_start(GTK_BOX(gtkblist->vbox), gtkblist->alert_notebook, FALSE, FALSE, 0); + /* Add the statusbox */ gtkblist->statusbox = gtk_gaim_status_box_new(); gtk_box_pack_start(GTK_BOX(gtkblist->vbox), gtkblist->statusbox, FALSE, TRUE, 0); Modified: trunk/gtk/gtkblist.h =================================================================== --- trunk/gtk/gtkblist.h 2006-10-23 18:10:51 UTC (rev 17566) +++ trunk/gtk/gtkblist.h 2006-10-23 19:05:14 UTC (rev 17567) @@ -94,6 +94,8 @@ GaimBlistNode *selected_node; /**< The currently selected node */ GtkWidget *error_buttons; /**< Box containing the connection error buttons */ GtkWidget *statusbox; /**< The status selector dropdown */ + + GtkWidget *alert_notebook; /**< The notebook for alerts */ }; #define GAIM_GTK_BLIST(list) ((GaimGtkBuddyList *)(list)->ui_data) @@ -301,4 +303,11 @@ */ void gaim_gtk_blist_update_account_error_state(GaimAccount *account, const char *message); +/** + * Adds a widget to the alert area of the buddy list + * + * @param widget The widget to add + */ +void gaim_gtk_blist_add_alert(GtkWidget *alert); + #endif /* _GAIM_GTKBLIST_H_ */ Modified: trunk/gtk/gtknotify.c =================================================================== --- trunk/gtk/gtknotify.c 2006-10-23 18:10:51 UTC (rev 17566) +++ trunk/gtk/gtknotify.c 2006-10-23 19:05:14 UTC (rev 17567) @@ -196,84 +196,138 @@ g_list_free(row); } + static void * gaim_gtk_notify_message(GaimNotifyMsgType type, const char *title, - const char *primary, const char *secondary) + const char *primary, const char *secondary) { - GtkWidget *dialog; - GtkWidget *hbox; - GtkWidget *label; - GtkWidget *img = NULL; - char label_text[2048]; - const char *icon_name = NULL; - char *primary_esc, *secondary_esc; + GtkStyle *style; + GdkColor color; + GtkWidget *ebox; + GtkWidget *vbox; + GtkWidget *hbox; + GtkWidget *bbox; + GtkWidget *label; + GtkWidget *button; + GtkWidget *alignment; + GtkWidget *img = NULL; + GtkStockItem close_item; + char label_text[2048]; + const char *icon_name = NULL; + char *primary_esc, *secondary_esc; - switch (type) - { - case GAIM_NOTIFY_MSG_ERROR: - icon_name = GAIM_STOCK_DIALOG_ERROR; - break; + switch (type) + { + case GAIM_NOTIFY_MSG_ERROR: + icon_name = GAIM_STOCK_DIALOG_ERROR; + break; - case GAIM_NOTIFY_MSG_WARNING: - icon_name = GAIM_STOCK_DIALOG_WARNING; - break; + case GAIM_NOTIFY_MSG_WARNING: + icon_name = GAIM_STOCK_DIALOG_WARNING; + break; - case GAIM_NOTIFY_MSG_INFO: - icon_name = GAIM_STOCK_DIALOG_INFO; - break; + case GAIM_NOTIFY_MSG_INFO: + icon_name = GAIM_STOCK_DIALOG_INFO; + break; - default: - icon_name = NULL; - break; - } + default: + icon_name = NULL; + break; + } - if (icon_name != NULL) - { - img = gtk_image_new_from_stock(icon_name, GTK_ICON_SIZE_DIALOG); - gtk_misc_set_alignment(GTK_MISC(img), 0, 0); - } + if (icon_name != NULL) + { + img = gtk_image_new_from_stock(icon_name, GTK_ICON_SIZE_BUTTON); + gtk_misc_set_alignment(GTK_MISC(img), 0, 0); + } - dialog = gtk_dialog_new_with_buttons(title ? title : GAIM_ALERT_TITLE, - NULL, 0, GTK_STOCK_CLOSE, - GTK_RESPONSE_CLOSE, NULL); + ebox = gtk_event_box_new(); + vbox = gtk_vbox_new(FALSE,0); + gtk_container_set_border_width(GTK_CONTAINER(vbox), 6); + color.red = 65535; + // gtk_widget_modify_bg(ebox, GTK_STATE_NORMAL, &(vbox->style->base[GTK_STATE_SELECTED])); + gtk_container_add(GTK_CONTAINER(ebox),vbox); - gtk_window_set_role(GTK_WINDOW(dialog), "notify_dialog"); + hbox = gtk_hbox_new(FALSE, 0); + gtk_container_add(GTK_CONTAINER(vbox), hbox); - g_signal_connect(G_OBJECT(dialog), "response", - G_CALLBACK(message_response_cb), dialog); + if (img != NULL) + gtk_box_pack_start(GTK_BOX(hbox), img, FALSE, FALSE, 0); + primary_esc = g_markup_escape_text(primary, -1); + if (secondary) + secondary_esc = g_markup_escape_text(secondary, -1); + g_snprintf(label_text, sizeof(label_text), + "<span weight=\"bold\" size=\"smaller\">%s</span>%s<span size=\"smaller\">%s</span>", + primary_esc, + secondary ? "\n" : "", + secondary ? secondary_esc : ""); + g_free(primary_esc); + label = gtk_label_new(NULL); + gtk_widget_modify_text(vbox, GTK_STATE_NORMAL, &(label->style->white)); + gtk_label_set_markup(GTK_LABEL(label), label_text); + gtk_label_set_line_wrap(GTK_LABEL(label), TRUE); + gtk_misc_set_alignment(GTK_MISC(label), 0, 0); + gtk_box_pack_start(GTK_BOX(hbox), label, TRUE, TRUE, 0); +#if GTK_CHECK_VERSION(2,6,0) + g_object_set(label, "ellipsize", PANGO_ELLIPSIZE_END, NULL); +#endif +#if 0 + if (secondary) { + secondary_esc = g_markup_escape_text(secondary, -1); + g_snprintf(label_text, sizeof(label_text), + "<span size=\"smaller\">%s</span>", + secondary_esc); + g_free(secondary_esc); + label = gtk_label_new(NULL); + gtk_label_set_markup(GTK_LABEL(label), label_text); + gtk_label_set_line_wrap(GTK_LABEL(label), TRUE); + gtk_misc_set_alignment(GTK_MISC(label), 0, 0); + gtk_box_pack_start(GTK_BOX(vbox), label, TRUE, TRUE, 0); +#if GTK_CHECK_VERSION(2,6,0) + g_object_set(label, "ellipsize", PANGO_ELLIPSIZE_END, NULL); +#endif + } +#endif + bbox = gtk_hbutton_box_new(); + gtk_box_pack_start(GTK_BOX(vbox), bbox, FALSE, FALSE, 0); + gtk_button_box_set_layout(GTK_BUTTON_BOX(bbox), GTK_BUTTONBOX_END); - gtk_container_set_border_width(GTK_CONTAINER(dialog), GAIM_HIG_BORDER); - gtk_window_set_resizable(GTK_WINDOW(dialog), FALSE); - gtk_dialog_set_has_separator(GTK_DIALOG(dialog), FALSE); - gtk_box_set_spacing(GTK_BOX(GTK_DIALOG(dialog)->vbox), GAIM_HIG_BORDER); - gtk_container_set_border_width(GTK_CONTAINER(GTK_DIALOG(dialog)->vbox), GAIM_HIG_BOX_SPACE); + button = gtk_button_new(); + g_signal_connect_swapped(G_OBJECT(button), "activate", gtk_widget_destroy, ebox); + alignment = gtk_alignment_new(0.5, 0.5, 0, 0); + gtk_container_add(GTK_CONTAINER(button), alignment); - hbox = gtk_hbox_new(FALSE, GAIM_HIG_BORDER); - gtk_container_add(GTK_CONTAINER(GTK_DIALOG(dialog)->vbox), hbox); + hbox = gtk_hbox_new(FALSE, 0); + gtk_container_add(GTK_CONTAINER(alignment), hbox); - if (img != NULL) - gtk_box_pack_start(GTK_BOX(hbox), img, FALSE, FALSE, 0); + img = gtk_image_new_from_stock(GTK_STOCK_CLOSE, GTK_ICON_SIZE_MENU); + gtk_misc_set_alignment(GTK_MISC(img), 0.5, 0.5); + gtk_box_pack_start(GTK_BOX(hbox), img, FALSE, FALSE, 0); - primary_esc = g_markup_escape_text(primary, -1); - secondary_esc = (secondary != NULL) ? g_markup_escape_text(secondary, -1) : NULL; - g_snprintf(label_text, sizeof(label_text), - "<span weight=\"bold\" size=\"larger\">%s</span>\n\n%s", - primary_esc, (secondary ? secondary_esc : "")); - g_free(primary_esc); - g_free(secondary_esc); + gtk_stock_lookup(GTK_STOCK_CLOSE, &close_item); + g_snprintf(label_text, sizeof(label_text), + "<span size=\"smaller\">%s</span>", close_item.label); + label = gtk_label_new(NULL); + gtk_misc_set_alignment(GTK_MISC(img), 0.5, 0.5); + gtk_box_pack_start(GTK_BOX(hbox), img, FALSE, FALSE, 0); - label = gtk_label_new(NULL); + gtk_stock_lookup(GTK_STOCK_CLOSE, &close_item); + g_snprintf(label_text, sizeof(label_text), + "<span size=\"smaller\">%s</span>", close_item.label); + label = gtk_label_new(NULL); + gtk_misc_set_alignment(GTK_MISC(img), 0.5, 0.5); + gtk_label_set_markup_with_mnemonic(GTK_LABEL(label), label_text); + gtk_box_pack_start(GTK_BOX(hbox), label, FALSE, FALSE, 0); - gtk_label_set_markup(GTK_LABEL(label), label_text); - gtk_label_set_line_wrap(GTK_LABEL(label), TRUE); - gtk_misc_set_alignment(GTK_MISC(label), 0, 0); - gtk_box_pack_start(GTK_BOX(hbox), label, FALSE, FALSE, 0); + gtk_container_add(GTK_CONTAINER(bbox), button); - gtk_widget_show_all(dialog); + gtk_widget_show_all(ebox); + gaim_gtk_blist_add_alert(ebox); - return dialog; + return ebox; } + static void selection_changed_cb(GtkTreeSelection *sel, GaimMailDialog *dialog) { Modified: trunk/gtk/gtkstatusbox.c =================================================================== --- trunk/gtk/gtkstatusbox.c 2006-10-23 18:10:51 UTC (rev 17566) +++ trunk/gtk/gtkstatusbox.c 2006-10-23 19:05:14 UTC (rev 17567) @@ -83,10 +83,6 @@ static void do_colorshift (GdkPixbuf *dest, GdkPixbuf *src, int shift); static void icon_choose_cb(const char *filename, gpointer data); -static void (*combo_box_size_request)(GtkWidget *widget, GtkRequisition *requisition); -static void (*combo_box_size_allocate)(GtkWidget *widget, GtkAllocation *allocation); -static void (*combo_box_forall) (GtkContainer *container, gboolean include_internals, GtkCallback callback, gpointer callback_data); - enum { /** A GtkGaimStatusBoxItemType */ TYPE_COLUMN, @@ -122,7 +118,7 @@ PROP_ICON_SEL, }; -GtkComboBoxClass *parent_class = NULL; +GtkContainer *parent_class = NULL; static void gtk_gaim_status_box_class_init (GtkGaimStatusBoxClass *klass); static void gtk_gaim_status_box_init (GtkGaimStatusBox *status_box); @@ -148,8 +144,8 @@ NULL /* value_table */ }; - status_box_type = g_type_register_static(GTK_TYPE_COMBO_BOX, - "GtkGaimStatusBox", + status_box_type = g_type_register_static(GTK_TYPE_CONTAINER, + "GtkGaimStatusBox", &status_box_info, 0); } @@ -199,7 +195,7 @@ if (status_no != -1) { gtk_widget_set_sensitive(GTK_WIDGET(status_box), FALSE); - gtk_combo_box_set_active(GTK_COMBO_BOX(status_box), status_no); +// gtk_combo_box_set_active(GTK_COMBO_BOX(status_box), status_no); message = gaim_status_get_attr_string(newstatus, "message"); @@ -426,23 +422,16 @@ gtk_gaim_status_box_class_init (GtkGaimStatusBoxClass *klass) { GObjectClass *object_class; - GtkComboBoxClass *combo_class; GtkWidgetClass *widget_class; GtkContainerClass *container_class = (GtkContainerClass*)klass; parent_class = g_type_class_peek_parent(klass); - combo_class = (GtkComboBoxClass*)klass; - combo_class->changed = gtk_gaim_status_box_changed; - widget_class = (GtkWidgetClass*)klass; - combo_box_size_request = widget_class->size_request; widget_class->size_request = gtk_gaim_status_box_size_request; - combo_box_size_allocate = widget_class->size_allocate; widget_class->size_allocate = gtk_gaim_status_box_size_allocate; widget_class->expose_event = gtk_gaim_status_box_expose_event; - combo_box_forall = container_class->forall; container_class->forall = gtk_gaim_status_box_forall; container_class->remove = NULL; @@ -518,16 +507,17 @@ gpointer data; /* Primary (get the status selected in the dropdown) */ - gtk_combo_box_get_active_iter(GTK_COMBO_BOX(status_box), &iter); - gtk_tree_model_get(GTK_TREE_MODEL(status_box->dropdown_store), &iter, - TYPE_COLUMN, &type, - DATA_COLUMN, &data, - -1); - if (type == GTK_GAIM_STATUS_BOX_TYPE_PRIMITIVE) - primary = g_strdup(gaim_primitive_get_name_from_type(GPOINTER_TO_INT(data))); - else - /* This should never happen, but just in case... */ - primary = g_strdup("New status"); +// gtk_combo_box_get_active_iter(GTK_COMBO_BOX(status_box), &iter); +// gtk_tree_model_get(GTK_TREE_MODEL(status_box->dropdown_store), &iter, +// TYPE_COLUMN, &type, +// DATA_COLUMN, &data, +// -1); +// if (type == GTK_GAIM_STATUS_BOX_TYPE_PRIMITIVE) +// primary = g_strdup(gaim_primitive_get_name_from_type(GPOINTER_TO_INT(data))); +// else +// /* This should never happen, but just in case... */ +// primary = g_strdup("New status"); + primary = g_strdup("Available"); } else if (account_status) primary = g_strdup(gaim_status_get_name(gaim_account_get_active_status(acct))); @@ -627,7 +617,7 @@ /* Make sure to activate the only row in the tree view */ path = gtk_tree_path_new_from_string("0"); - gtk_cell_view_set_displayed_row(GTK_CELL_VIEW(status_box->cell_view), path); +// gtk_cell_view_set_displayed_row(GTK_CELL_VIEW(status_box->cell_view), path); gtk_tree_path_free(path); update_size(status_box); @@ -693,7 +683,7 @@ (!gaim_savedstatus_has_substatuses(saved_status))) { index = get_statusbox_index(status_box, saved_status); - gtk_combo_box_set_active(GTK_COMBO_BOX(status_box), index); +// gtk_combo_box_set_active(GTK_COMBO_BOX(status_box), index); } else { @@ -702,7 +692,7 @@ gpointer data; /* Unset the active item */ - gtk_combo_box_set_active(GTK_COMBO_BOX(status_box), -1); +// gtk_combo_box_set_active(GTK_COMBO_BOX(status_box), -1); /* If this saved status is in the list store, then set it as the active item */ if (gtk_tree_model_get_iter_first(GTK_TREE_MODEL(status_box->dropdown_store), &iter)) @@ -730,7 +720,7 @@ || !strcmp(name, acct_status_name)) { /* Found! */ - gtk_combo_box_set_active_iter(GTK_COMBO_BOX(status_box), &iter); +// gtk_combo_box_set_active_iter(GTK_COMBO_BOX(status_box), &iter); g_free(name); break; } @@ -740,7 +730,7 @@ (GPOINTER_TO_INT(data) == gaim_savedstatus_get_creation_time(saved_status))) { /* Found! */ - gtk_combo_box_set_active_iter(GTK_COMBO_BOX(status_box), &iter); +// gtk_combo_box_set_active_iter(GTK_COMBO_BOX(status_box), &iter); break; } } @@ -926,7 +916,7 @@ if (tmp != NULL) g_object_unref(tmp); } - gtk_combo_box_set_model(GTK_COMBO_BOX(status_box), GTK_TREE_MODEL(status_box->dropdown_store)); +// gtk_combo_box_set_model(GTK_COMBO_BOX(status_box), GTK_TREE_MODEL(status_box->dropdown_store)); } static void @@ -943,7 +933,7 @@ icon_size = gtk_icon_size_from_name(GAIM_ICON_SIZE_STATUS_SMALL); /* Unset the model while clearing it */ - gtk_combo_box_set_model(GTK_COMBO_BOX(status_box), NULL); +// gtk_combo_box_set_model(GTK_COMBO_BOX(status_box), NULL); gtk_list_store_clear(status_box->dropdown_store); /* Don't set the model until the new statuses have been added to the box. * What is presumably a bug in Gtk < 2.4 causes things to get all confused @@ -985,7 +975,7 @@ gtk_gaim_status_box_add(GTK_GAIM_STATUS_BOX(status_box), GTK_GAIM_STATUS_BOX_TYPE_SAVED, pixbuf, _("Saved..."), NULL, NULL); if (pixbuf) g_object_unref(G_OBJECT(pixbuf)); - gtk_combo_box_set_model(GTK_COMBO_BOX(status_box), GTK_TREE_MODEL(status_box->dropdown_store)); +// gtk_combo_box_set_model(GTK_COMBO_BOX(status_box), GTK_TREE_MODEL(status_box->dropdown_store)); status_menu_refresh_iter(status_box); } else { @@ -1187,7 +1177,7 @@ static void toggled_cb(GtkWidget *widget, GtkGaimStatusBox *box) { - gtk_combo_box_popup(GTK_COMBO_BOX(box)); +// gtk_combo_box_popup(GTK_COMBO_BOX(box)); gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(box->toggle_button), FALSE); } @@ -1272,9 +1262,9 @@ status_box->store = gtk_list_store_new(NUM_COLUMNS, G_TYPE_INT, GDK_TYPE_PIXBUF, G_TYPE_STRING, G_TYPE_STRING, G_TYPE_STRING, G_TYPE_POINTER); status_box->dropdown_store = gtk_list_store_new(NUM_COLUMNS, G_TYPE_INT, GDK_TYPE_PIXBUF, G_TYPE_STRING, G_TYPE_STRING, G_TYPE_STRING, G_TYPE_POINTER); - gtk_combo_box_set_model(GTK_COMBO_BOX(status_box), GTK_TREE_MODEL(status_box->dropdown_store)); +// gtk_combo_box_set_model(GTK_COMBO_BOX(status_box), GTK_TREE_MODEL(status_box->dropdown_store)); gtk_cell_view_set_model(GTK_CELL_VIEW(status_box->cell_view), GTK_TREE_MODEL(status_box->store)); - gtk_combo_box_set_wrap_width(GTK_COMBO_BOX(status_box), 0); +// gtk_combo_box_set_wrap_width(GTK_COMBO_BOX(status_box), 0); gtk_list_store_append(status_box->store, &(status_box->iter)); gtk_container_add(GTK_CONTAINER(status_box->toggle_button), status_box->hbox); @@ -1288,20 +1278,20 @@ text_rend = gtk_cell_renderer_text_new(); icon_rend = gtk_cell_renderer_pixbuf_new(); - gtk_cell_layout_pack_start(GTK_CELL_LAYOUT(status_box), icon_rend, FALSE); - gtk_cell_layout_pack_start(GTK_CELL_LAYOUT(status_box), text_rend, TRUE); - gtk_cell_layout_set_attributes(GTK_CELL_LAYOUT(status_box), icon_rend, "pixbuf", ICON_COLUMN, NULL); - gtk_cell_layout_set_attributes(GTK_CELL_LAYOUT(status_box), text_rend, "markup", TEXT_COLUMN, NULL); +// gtk_cell_layout_pack_start(GTK_CELL_LAYOUT(status_box), icon_rend, FALSE); +// gtk_cell_layout_pack_start(GTK_CELL_LAYOUT(status_box), text_rend, TRUE); +// gtk_cell_layout_set_attributes(GTK_CELL_LAYOUT(status_box), icon_rend, "pixbuf", ICON_COLUMN, NULL); +// gtk_cell_layout_set_attributes(GTK_CELL_LAYOUT(status_box), text_rend, "markup", TEXT_COLUMN, NULL); #if GTK_CHECK_VERSION(2, 6, 0) g_object_set(text_rend, "ellipsize", PANGO_ELLIPSIZE_END, NULL); #endif status_box->icon_rend = gtk_cell_renderer_pixbuf_new(); status_box->text_rend = gtk_cell_renderer_text_new(); - gtk_cell_layout_pack_start(GTK_CELL_LAYOUT(status_box->cell_view), status_box->icon_rend, FALSE); - gtk_cell_layout_pack_start(GTK_CELL_LAYOUT(status_box->cell_view), status_box->text_rend, TRUE); - gtk_cell_layout_set_attributes(GTK_CELL_LAYOUT(status_box->cell_view), status_box->icon_rend, "pixbuf", ICON_COLUMN, NULL); - gtk_cell_layout_set_attributes(GTK_CELL_LAYOUT(status_box->cell_view), status_box->text_rend, "markup", TEXT_COLUMN, NULL); +// gtk_cell_layout_pack_start(GTK_CELL_LAYOUT(status_box->cell_view), status_box->icon_rend, FALSE); +// gtk_cell_layout_pack_start(GTK_CELL_LAYOUT(status_box->cell_view), status_box->text_rend, TRUE); +// gtk_cell_layout_set_attributes(GTK_CELL_LAYOUT(status_box->cell_view), status_box->icon_rend, "pixbuf", ICON_COLUMN, NULL); +// gtk_cell_layout_set_attributes(GTK_CELL_LAYOUT(status_box->cell_view), status_box->text_rend, "markup", TEXT_COLUMN, NULL); #if GTK_CHECK_VERSION(2, 6, 0) g_object_set(status_box->text_rend, "ellipsize", PANGO_ELLIPSIZE_END, NULL); #endif @@ -1341,7 +1331,7 @@ G_CALLBACK(imhtml_scroll_event_cb), status_box->imhtml); #if GTK_CHECK_VERSION(2,6,0) - gtk_combo_box_set_row_separator_func(GTK_COMBO_BOX(status_box), dropdown_store_row_separator_func, NULL, NULL); +// gtk_combo_box_set_row_separator_func(GTK_COMBO_BOX(status_box), dropdown_store_row_separator_func, NULL, NULL); #endif status_box->token_status_account = check_active_accounts_for_identical_statuses(); @@ -1376,7 +1366,7 @@ GtkRequisition *requisition) { GtkRequisition box_req; - combo_box_size_request(widget, requisition); + gtk_widget_size_request(GTK_GAIM_STATUS_BOX(widget)->toggle_button, requisition); requisition->height += 3; /* If the gtkimhtml is visible, then add some additional padding */ @@ -1438,7 +1428,7 @@ GtkAllocation parent_alc, box_alc, icon_alc; gint border_width = GTK_CONTAINER (widget)->border_width; - combo_box_size_request(widget, &req); + gtk_widget_size_request(GTK_GAIM_STATUS_BOX(widget)->toggle_button, &req); box_alc = *allocation; @@ -1477,7 +1467,6 @@ gtk_widget_size_allocate(status_box->icon_box, &icon_alc); } - combo_box_size_allocate(widget, &parent_alc); gtk_widget_size_allocate(status_box->toggle_button, &parent_alc); widget->allocation = *allocation; } @@ -1511,7 +1500,7 @@ (* callback) (status_box->icon_box, callback_data); } - combo_box_forall(container, include_internals, callback, callback_data); +// combo_box_forall(container, include_internals, callback, callback_data); } GtkWidget * @@ -1724,8 +1713,8 @@ GaimSavedStatus *saved_status = NULL; gboolean changed = TRUE; - if (!gtk_combo_box_get_active_iter(GTK_COMBO_BOX(status_box), &iter)) - return; +// if (!gtk_combo_box_get_active_iter(GTK_COMBO_BOX(status_box), &iter)) +// return; gtk_tree_model_get(GTK_TREE_MODEL(status_box->dropdown_store), &iter, TYPE_COLUMN, &type, @@ -1964,8 +1953,8 @@ status_box = GTK_GAIM_STATUS_BOX(box); - if (!gtk_combo_box_get_active_iter(GTK_COMBO_BOX(status_box), &iter)) - return; +// if (!gtk_combo_box_get_active_iter(GTK_COMBO_BOX(status_box), &iter)) +// return; gtk_tree_model_get(GTK_TREE_MODEL(status_box->dropdown_store), &iter, TYPE_COLUMN, &type, DATA_COLUMN, &data, Modified: trunk/gtk/gtkstatusbox.h =================================================================== --- trunk/gtk/gtkstatusbox.h 2006-10-23 18:10:51 UTC (rev 17566) +++ trunk/gtk/gtkstatusbox.h 2006-10-23 19:05:14 UTC (rev 17567) @@ -65,7 +65,7 @@ struct _GtkGaimStatusBox { - GtkComboBox parent_instance; + GtkContainer parent_instance; /** * This GtkListStore contains only one row--the currently selected status. @@ -131,7 +131,7 @@ struct _GtkGaimStatusBoxClass { - GtkComboBoxClass parent_class; + GtkContainerClass parent_class; /* signals */ void (* changed) (GtkComboBox *combo_box); Modified: trunk/libgaim/network.c =================================================================== --- trunk/libgaim/network.c 2006-10-23 18:10:51 UTC (rev 17566) +++ trunk/libgaim/network.c 2006-10-23 19:05:14 UTC (rev 17567) @@ -26,6 +26,9 @@ #include "internal.h" #ifndef _WIN32 +#include <resolv.h> +#include <netinet/in.h> +#include <arpa/nameser.h> #include <net/if.h> #include <sys/ioctl.h> #else This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <dat...@us...> - 2006-10-23 18:11:02
|
Revision: 17566 http://svn.sourceforge.net/gaim/?rev=17566&view=rev Author: datallah Date: 2006-10-23 11:10:51 -0700 (Mon, 23 Oct 2006) Log Message: ----------- fix searching in an empty conversation (SF bug #1582852) Modified Paths: -------------- trunk/gtk/gtkimhtml.c Modified: trunk/gtk/gtkimhtml.c =================================================================== --- trunk/gtk/gtkimhtml.c 2006-10-23 17:53:55 UTC (rev 17565) +++ trunk/gtk/gtkimhtml.c 2006-10-23 18:10:51 UTC (rev 17566) @@ -3531,22 +3531,25 @@ { GtkTextIter iter, start, end; gboolean new_search = TRUE; + GtkTextMark *start_mark; g_return_val_if_fail(imhtml != NULL, FALSE); g_return_val_if_fail(text != NULL, FALSE); - if (imhtml->search_string && !strcmp(text, imhtml->search_string)) + start_mark = gtk_text_buffer_get_mark(imhtml->text_buffer, "search"); + + if (start_mark && imhtml->search_string && !strcmp(text, imhtml->search_string)) new_search = FALSE; if (new_search) { gtk_imhtml_search_clear(imhtml); + g_free(imhtml->search_string); + imhtml->search_string = g_strdup(text); gtk_text_buffer_get_start_iter(imhtml->text_buffer, &iter); } else { gtk_text_buffer_get_iter_at_mark(imhtml->text_buffer, &iter, - gtk_text_buffer_get_mark(imhtml->text_buffer, "search")); + start_mark); } - g_free(imhtml->search_string); - imhtml->search_string = g_strdup(text); if (gtk_source_iter_forward_search(&iter, imhtml->search_string, GTK_SOURCE_SEARCH_VISIBLE_ONLY | GTK_SOURCE_SEARCH_CASE_INSENSITIVE, This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <sea...@us...> - 2006-10-23 17:54:12
|
Revision: 17565 http://svn.sourceforge.net/gaim/?rev=17565&view=rev Author: seanegan Date: 2006-10-23 10:53:55 -0700 (Mon, 23 Oct 2006) Log Message: ----------- [ 1582776 ] Re-init resolver when libnm connection changes Modified Paths: -------------- trunk/COPYRIGHT trunk/libgaim/network.c Modified: trunk/COPYRIGHT =================================================================== --- trunk/COPYRIGHT 2006-10-23 01:07:27 UTC (rev 17564) +++ trunk/COPYRIGHT 2006-10-23 17:53:55 UTC (rev 17565) @@ -62,6 +62,7 @@ Jason Cohen Todd Cohen Jono Cole +Lorenzo Colitti Nathan Conrad Felipe Contreras Alex Converse Modified: trunk/libgaim/network.c =================================================================== --- trunk/libgaim/network.c 2006-10-23 01:07:27 UTC (rev 17564) +++ trunk/libgaim/network.c 2006-10-23 17:53:55 UTC (rev 17565) @@ -543,6 +543,8 @@ switch(current) { case LIBNM_ACTIVE_NETWORK_CONNECTION: + /* Call res_init in case DNS servers have changed */ + res_init(); ui_ops->network_connected(); prev = current; break; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <rl...@us...> - 2006-10-23 01:07:31
|
Revision: 17564 http://svn.sourceforge.net/gaim/?rev=17564&view=rev Author: rlaager Date: 2006-10-22 18:07:27 -0700 (Sun, 22 Oct 2006) Log Message: ----------- Revert the changes from 17036. The log-displaying signal has a GaimGtkLogViewer argument, and gaim-encryption uses it. Accessor methods would be another way to solve this, but I don't really want to risk breaking things more. Modified Paths: -------------- trunk/ChangeLog.API trunk/gtk/gtklog.c trunk/gtk/gtklog.h Modified: trunk/ChangeLog.API =================================================================== --- trunk/ChangeLog.API 2006-10-22 07:04:28 UTC (rev 17563) +++ trunk/ChangeLog.API 2006-10-23 01:07:27 UTC (rev 17564) @@ -198,7 +198,6 @@ * gaim_conversation_get_send_history(), and send_history from GaimConversation * Removed ui_ops from GaimBuddyList. Use gaim_blist_get_ui_ops() instead - * GaimGtkLogViewer hidden... You weren't using it anyway. * GaimGtkConversation: dialogs (dialogs.search moved to GaimGtkWindow) * gaim_show_xfer_dialog: Use gaim_gtk_xfer_dialog_show(NULL) instead. * GaimGtkRoomlistDialog: Nothing used it outside of the file it was in. Modified: trunk/gtk/gtklog.c =================================================================== --- trunk/gtk/gtklog.c 2006-10-22 07:04:28 UTC (rev 17563) +++ trunk/gtk/gtklog.c 2006-10-23 01:07:27 UTC (rev 17564) @@ -34,25 +34,6 @@ #include "notify.h" #include "util.h" -typedef struct _GaimGtkLogViewer GaimGtkLogViewer; - -/** - * A GTK+ Log Viewer. You can look at logs with it. - */ -struct _GaimGtkLogViewer { - GList *logs; /**< The list of logs viewed in this viewer */ - - GtkWidget *window; /**< The viewer's window */ - GtkTreeStore *treestore; /**< The treestore containing said logs */ - GtkWidget *treeview; /**< The treeview representing said treestore */ - GtkWidget *imhtml; /**< The imhtml to display said logs */ - GtkWidget *entry; /**< The search entry, in which search terms - * are entered */ - GaimLogReadFlags flags; /**< The most recently used log flags */ - char *search; /**< The string currently being searched for */ - GtkWidget *label; /**< The label at the top of the log viewer */ -}; - static GHashTable *log_viewers = NULL; static void populate_log_tree(GaimGtkLogViewer *lv); static GaimGtkLogViewer *syslog_viewer = NULL; Modified: trunk/gtk/gtklog.h =================================================================== --- trunk/gtk/gtklog.h 2006-10-22 07:04:28 UTC (rev 17563) +++ trunk/gtk/gtklog.h 2006-10-23 01:07:27 UTC (rev 17564) @@ -30,6 +30,27 @@ #include "account.h" +typedef struct _GaimGtkLogViewer GaimGtkLogViewer; + +/** + * A GTK+ Log Viewer. You can look at logs with it. + */ +struct _GaimGtkLogViewer { + GList *logs; /**< The list of logs viewed in this viewer */ + + GtkWidget *window; /**< The viewer's window */ + GtkTreeStore *treestore; /**< The treestore containing said logs */ + GtkWidget *treeview; /**< The treeview representing said treestore */ + GtkWidget *imhtml; /**< The imhtml to display said logs */ + GtkWidget *entry; /**< The search entry, in which search terms + * are entered */ + GaimLogReadFlags flags; /**< The most recently used log flags */ + char *search; /**< The string currently being searched for */ + GtkWidget *label; /**< The label at the top of the log viewer */ +}; + + + void gaim_gtk_log_show(GaimLogType type, const char *screenname, GaimAccount *account); void gaim_gtk_log_show_contact(GaimContact *contact); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <rl...@us...> - 2006-10-22 07:04:35
|
Revision: 17563 http://svn.sourceforge.net/gaim/?rev=17563&view=rev Author: rlaager Date: 2006-10-22 00:04:28 -0700 (Sun, 22 Oct 2006) Log Message: ----------- SF Patch #1580113 from Taso N. Devetzis "gtkcellrendererexpander.c:aim_gtk_cell_renderer_expander_activate() prototype needs tweaking to compile under Solaris." Modified Paths: -------------- trunk/COPYRIGHT trunk/gtk/gtkcellrendererexpander.c Modified: trunk/COPYRIGHT =================================================================== --- trunk/COPYRIGHT 2006-10-22 05:12:28 UTC (rev 17562) +++ trunk/COPYRIGHT 2006-10-22 07:04:28 UTC (rev 17563) @@ -73,6 +73,7 @@ Michael Culbertson Martijn Dekker Philip Derrin +Taso N. Devetzis Balwinder Singh Dheeman Andrew Dieffenbach Finlay Dobbie Modified: trunk/gtk/gtkcellrendererexpander.c =================================================================== --- trunk/gtk/gtkcellrendererexpander.c 2006-10-22 05:12:28 UTC (rev 17562) +++ trunk/gtk/gtkcellrendererexpander.c 2006-10-22 07:04:28 UTC (rev 17563) @@ -62,7 +62,7 @@ const gchar *path, GdkRectangle *background_area, GdkRectangle *cell_area, - guint flags); + GtkCellRendererState flags); static void gaim_gtk_cell_renderer_expander_finalize (GObject *gobject); enum { This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <rl...@us...> - 2006-10-22 05:12:31
|
Revision: 17562 http://svn.sourceforge.net/gaim/?rev=17562&view=rev Author: rlaager Date: 2006-10-21 22:12:28 -0700 (Sat, 21 Oct 2006) Log Message: ----------- SF Patch #1581054 from Jason Lynch Fixes SF Bug #1581014 'Several switches in the configure script (startup-notification and gtkspell, among others) explicitly set the relevant enable_x variable to "no" in the AC_ARG_ENABLE macro in the "action-if-given" area, with the side effect that if someone explicitly passes --enable-feature, the feature will be disabled. replacing the "no" with "$enableval" as in other AC_ARG_ENABLE calls fixes the problem.' The signature is: AC_ARG_ENABLE (FEATURE, HELP-STRING, [ACTION-IF-GIVEN], [ACTION-IF-NOT-GIVEN]) Modified Paths: -------------- trunk/COPYRIGHT trunk/configure.ac Modified: trunk/COPYRIGHT =================================================================== --- trunk/COPYRIGHT 2006-10-22 05:05:16 UTC (rev 17561) +++ trunk/COPYRIGHT 2006-10-22 05:12:28 UTC (rev 17562) @@ -178,6 +178,7 @@ Uli Luckas Matthew Luckie Mike Lundy +Jason Lynch Lucio Maciel Brian Macke Paolo Maggi Modified: trunk/configure.ac =================================================================== --- trunk/configure.ac 2006-10-22 05:05:16 UTC (rev 17561) +++ trunk/configure.ac 2006-10-22 05:12:28 UTC (rev 17562) @@ -186,27 +186,27 @@ AC_ARG_ENABLE(screensaver, [AC_HELP_STRING([--disable-screensaver], [compile without X screensaver extension (used to detect idleness)])], - enable_screensaver="no", enable_screensaver="yes") + enable_screensaver="$enableval", enable_screensaver="yes") AC_ARG_ENABLE(sm, [AC_HELP_STRING([--disable-sm], [compile without X session management support])], - enable_sm="no", enable_sm="yes") + enable_sm="$enableval", enable_sm="yes") AC_ARG_ENABLE(startup-notification, [AC_HELP_STRING([--disable-startup-notification], [compile without startup notification support])], - enable_startup_notification="no", enable_startup_notification="yes") + enable_startup_notification="$enableval", enable_startup_notification="yes") AC_ARG_ENABLE(gtkspell, [AC_HELP_STRING([--disable-gtkspell], [compile without GtkSpell automatic spell checking])], - enable_gtkspell="no", enable_gtkspell="yes") + enable_gtkspell="$enableval", enable_gtkspell="yes") AC_ARG_ENABLE(gevolution, [AC_HELP_STRING([--disable-gevolution], [compile without the Gaim Evolution plugin])], - enable_gevolution="no", enable_gevolution="yes") + enable_gevolution="$enableval", enable_gevolution="yes") AC_ARG_ENABLE(cap, [AC_HELP_STRING([--disable-cap], [compile without Contact Availability Prediction plugin])], - enable_cap="no", enable_cap="yes") + enable_cap="$enableval", enable_cap="yes") AC_PATH_XTRA @@ -455,7 +455,7 @@ dnl ####################################################################### AC_ARG_ENABLE(gstreamer, [AC_HELP_STRING([--disable-gstreamer], [compile without GStreamer audio support])], - enable_gst="no", enable_gst="yes") + enable_gst="$enableval", enable_gst="yes") PKG_CHECK_MODULES(GSTREAMER, [gstreamer-0.10], , [ AC_MSG_RESULT(no) enable_gst="no" @@ -1564,7 +1564,7 @@ dnl # Check for Tcl dnl ####################################################################### AC_ARG_ENABLE(tcl, [AC_HELP_STRING([--disable-tcl], - [compile without Tcl scripting])], enable_tcl="no", enable_tcl="yes") + [compile without Tcl scripting])], enable_tcl="$enableval", enable_tcl="yes") AC_ARG_WITH(tclconfig, [AC_HELP_STRING([--with-tclconfig=DIR], [directory containing tclConfig.sh])]) @@ -1633,7 +1633,7 @@ dnl # Check for Tk dnl ####################################################################### AC_ARG_ENABLE(tk, [AC_HELP_STRING([--disable-tk], - [compile without Tcl support for Tk])], enable_tk="no", enable_tk="yes") + [compile without Tcl support for Tk])], enable_tk="$enableval", enable_tk="yes") AC_ARG_WITH(tkconfig, [AC_HELP_STRING([--with-tkconfig=DIR], [directory containing tkConfig.sh])]) @@ -1812,11 +1812,11 @@ AC_ARG_ENABLE(doxygen, [AC_HELP_STRING([--disable-doxygen], [enable documentation with doxygen])], - enable_doxygen="no", enable_doxygen="yes") + enable_doxygen="$enableval", enable_doxygen="yes") AC_ARG_ENABLE(dot, [AC_HELP_STRING([--enable-dot], [enable graphs in doxygen via 'dot'])], - enable_dot="no", enable_dot="yes") + enable_dot="$enableval", enable_dot="yes") if test "x$enable_doxygen" = xyes; then AC_CHECK_PROG(DOXYGEN, doxygen, true, false) This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <rl...@us...> - 2006-10-22 05:05:21
|
Revision: 17561 http://svn.sourceforge.net/gaim/?rev=17561&view=rev Author: rlaager Date: 2006-10-21 22:05:16 -0700 (Sat, 21 Oct 2006) Log Message: ----------- SF Patch #1581414 from Ari Pollak "The gg plugin doesn't link against libgg anymore when it's detected using pkg-config. This should be fixable by changing back this line in configure.ac: PKG_CHECK_MODULES(LIBGADU, libgadu, [ to this: PKG_CHECK_MODULES(GADU, libgadu, [" This was my mistake. Sorry. Modified Paths: -------------- trunk/configure.ac Modified: trunk/configure.ac =================================================================== --- trunk/configure.ac 2006-10-21 23:36:44 UTC (rev 17560) +++ trunk/configure.ac 2006-10-22 05:05:16 UTC (rev 17561) @@ -605,7 +605,7 @@ gadu_manual_check="no" fi if test "x$gadu_manual_check" = "xno"; then - PKG_CHECK_MODULES(LIBGADU, libgadu, [ + PKG_CHECK_MODULES(GADU, libgadu, [ gadu_includes="yes" gadu_libs="yes" ], [ This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <dat...@us...> - 2006-10-21 23:36:48
|
Revision: 17560 http://svn.sourceforge.net/gaim/?rev=17560&view=rev Author: datallah Date: 2006-10-21 16:36:44 -0700 (Sat, 21 Oct 2006) Log Message: ----------- Use Windows' built-in functionality to stop flashing. Modified Paths: -------------- trunk/gtk/win32/gtkwin32dep.c Modified: trunk/gtk/win32/gtkwin32dep.c =================================================================== --- trunk/gtk/win32/gtkwin32dep.c 2006-10-21 21:19:02 UTC (rev 17559) +++ trunk/gtk/win32/gtkwin32dep.c 2006-10-21 23:36:44 UTC (rev 17560) @@ -225,25 +225,6 @@ return win_hwnd; } -static int -halt_flash_filter(GtkWidget *widget, GdkEventFocus *event, gpointer data) { - if(MyFlashWindowEx) { - HWND hWnd = data; - FLASHWINFO info; - - if(!IsWindow(hWnd)) - return 0; - - memset(&info, 0, sizeof(FLASHWINFO)); - info.cbSize = sizeof(FLASHWINFO); - info.hwnd = hWnd; - info.dwFlags = FLASHW_STOP; - info.dwTimeout = 0; - MyFlashWindowEx(&info); - } - return 0; -} - void gtkwgaim_conv_blink(GaimConversation *conv, GaimMessageFlags flags) { GaimGtkWindow *win; @@ -266,21 +247,19 @@ window = win->window; + /* Don't flash if we have the window focused */ + if(GetForegroundWindow() == GDK_WINDOW_HWND(window->window)) + return; + if(MyFlashWindowEx) { FLASHWINFO info; - /* Don't flash if we have the window focused */ - if(GetForegroundWindow() == GDK_WINDOW_HWND(window->window)) - return; memset(&info, 0, sizeof(FLASHWINFO)); info.cbSize = sizeof(FLASHWINFO); info.hwnd = GDK_WINDOW_HWND(window->window); - info.dwFlags = FLASHW_ALL | FLASHW_TIMER; + info.dwFlags = FLASHW_ALL | FLASHW_TIMERNOFG; info.dwTimeout = 0; MyFlashWindowEx(&info); - /* Stop flashing when window receives focus */ - g_signal_connect(G_OBJECT(window), "focus-in-event", - G_CALLBACK(halt_flash_filter), info.hwnd); } } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <dat...@us...> - 2006-10-21 21:19:08
|
Revision: 17559 http://svn.sourceforge.net/gaim/?rev=17559&view=rev Author: datallah Date: 2006-10-21 14:19:02 -0700 (Sat, 21 Oct 2006) Log Message: ----------- move win32 gtk plugin extra dist stuff to gtk/plugins/Makefile.am Modified Paths: -------------- trunk/Makefile.am trunk/gtk/plugins/Makefile.am Modified: trunk/Makefile.am =================================================================== --- trunk/Makefile.am 2006-10-21 21:08:24 UTC (rev 17558) +++ trunk/Makefile.am 2006-10-21 21:19:02 UTC (rev 17559) @@ -20,12 +20,6 @@ intltool-merge.in \ intltool-update.in \ config.h.mingw \ - gtk/plugins/win32/transparency/Makefile.mingw \ - gtk/plugins/win32/transparency/win2ktrans.c \ - gtk/plugins/win32/winprefs/gtkappbar.c \ - gtk/plugins/win32/winprefs/gtkappbar.h \ - gtk/plugins/win32/winprefs/Makefile.mingw \ - gtk/plugins/win32/winprefs/winprefs.c \ po/Makefile.mingw noinst_HEADERS = config.h Modified: trunk/gtk/plugins/Makefile.am =================================================================== --- trunk/gtk/plugins/Makefile.am 2006-10-21 21:08:24 UTC (rev 17558) +++ trunk/gtk/plugins/Makefile.am 2006-10-21 21:19:02 UTC (rev 17559) @@ -78,7 +78,13 @@ gaiminc.c \ gtk-signals-test.c \ mailchk.c \ - raw.c + raw.c \ + win32/transparency/Makefile.mingw \ + win32/transparency/win2ktrans.c \ + win32/winprefs/gtkappbar.c \ + win32/winprefs/gtkappbar.h \ + win32/winprefs/Makefile.mingw \ + win32/winprefs/winprefs.c AM_CPPFLAGS = \ -DDATADIR=\"$(datadir)\" \ This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <sa...@us...> - 2006-10-21 21:08:50
|
Revision: 17558 http://svn.sourceforge.net/gaim/?rev=17558&view=rev Author: sadrul Date: 2006-10-21 14:08:24 -0700 (Sat, 21 Oct 2006) Log Message: ----------- Introduce actions. You can specify the bindings for the actions. Right now, only the tree and the entry widget have them. The manual includes the details. I believe Ethan had suggested something like this a while back. It made sense, so here it is. Modified Paths: -------------- trunk/console/libgnt/gnt-skel.c trunk/console/libgnt/gntentry.c trunk/console/libgnt/gntkeys.h trunk/console/libgnt/gntstyle.c trunk/console/libgnt/gnttree.c trunk/console/libgnt/gntutils.c trunk/console/libgnt/gntutils.h trunk/console/libgnt/gntwidget.c trunk/console/libgnt/gntwidget.h trunk/console/libgnt/test/multiwin.c trunk/console/libgnt/test/tv.c trunk/doc/gaim-text.1.in Modified: trunk/console/libgnt/gnt-skel.c =================================================================== --- trunk/console/libgnt/gnt-skel.c 2006-10-21 20:40:12 UTC (rev 17557) +++ trunk/console/libgnt/gnt-skel.c 2006-10-21 21:08:24 UTC (rev 17558) @@ -50,6 +50,13 @@ parent_class->size_request = gnt_skel_size_request; parent_class->key_pressed = gnt_skel_key_pressed; + parent_class->actions = g_hash_table_duplicate(parent_class->actions, g_str_hash, + g_str_equal, NULL, (GDestroyNotify)gnt_widget_action_free); + parent_class->bindings = g_hash_table_duplicate(parent_class->bindings, g_str_hash, + g_str_equal, NULL, (GDestroyNotify)gnt_widget_action_param_free); + + gnt_widget_actions_read(G_OBJECT_CLASS_TYPE(klass), klass); + GNTDEBUG; } Modified: trunk/console/libgnt/gntentry.c =================================================================== --- trunk/console/libgnt/gntentry.c 2006-10-21 20:40:12 UTC (rev 17557) +++ trunk/console/libgnt/gntentry.c 2006-10-21 21:08:24 UTC (rev 17558) @@ -157,35 +157,40 @@ gnt_widget_queue_update(widget); } -static void -move_back(GntEntry *entry) +static gboolean +move_back(GntWidget *widget, GList *null) { + GntEntry *entry = GNT_ENTRY(widget); if (entry->cursor <= entry->start) - return; + return FALSE; entry->cursor = g_utf8_find_prev_char(entry->start, entry->cursor); if (entry->cursor < entry->scroll) entry->scroll = entry->cursor; entry_redraw(GNT_WIDGET(entry)); + return TRUE; } -static void -move_forward(GntEntry *entry) +static gboolean +move_forward(GntWidget *widget, GList *list) { + GntEntry *entry = GNT_ENTRY(widget); if (entry->cursor >= entry->end) - return; + return FALSE; entry->cursor = g_utf8_find_next_char(entry->cursor, NULL); while (gnt_util_onscreen_width(entry->scroll, entry->cursor) >= GNT_WIDGET(entry)->priv.width) entry->scroll = g_utf8_find_next_char(entry->scroll, NULL); entry_redraw(GNT_WIDGET(entry)); + return TRUE; } -static void -backspace(GntEntry *entry) +static gboolean +backspace(GntWidget *widget, GList *null) { int len; + GntEntry *entry = GNT_ENTRY(widget); if (entry->cursor <= entry->start) - return; + return TRUE; len = entry->cursor - g_utf8_find_prev_char(entry->start, entry->cursor); entry->cursor -= len; @@ -198,15 +203,17 @@ entry_redraw(GNT_WIDGET(entry)); if (entry->ddown) show_suggest_dropdown(entry); + return TRUE; } -static void -delkey(GntEntry *entry) +static gboolean +delkey(GntWidget *widget, GList *null) { int len; + GntEntry *entry = GNT_ENTRY(widget); if (entry->cursor >= entry->end) - return; + return FALSE; len = g_utf8_find_next_char(entry->cursor, NULL) - entry->cursor; memmove(entry->cursor, entry->cursor + len, entry->end - entry->cursor - len + 1); @@ -215,99 +222,129 @@ if (entry->ddown) show_suggest_dropdown(entry); + return TRUE; } -static void -move_start(GntEntry *entry) +static gboolean +move_start(GntWidget *widget, GList *null) { + GntEntry *entry = GNT_ENTRY(widget); entry->scroll = entry->cursor = entry->start; entry_redraw(GNT_WIDGET(entry)); + return TRUE; } -static void -move_end(GntEntry *entry) +static gboolean +move_end(GntWidget *widget, GList *null) { + GntEntry *entry = GNT_ENTRY(widget); entry->cursor = entry->end; /* This should be better than this */ while (gnt_util_onscreen_width(entry->scroll, entry->cursor) >= GNT_WIDGET(entry)->priv.width) entry->scroll = g_utf8_find_next_char(entry->scroll, NULL); entry_redraw(GNT_WIDGET(entry)); + return TRUE; } static gboolean -gnt_entry_key_pressed(GntWidget *widget, const char *text) +history_prev(GntWidget *widget, GList *null) { GntEntry *entry = GNT_ENTRY(widget); + if (entry->histlength && entry->history->prev) + { + entry->history = entry->history->prev; + gnt_entry_set_text(entry, entry->history->data); + destroy_suggest(entry); - if (text[0] == 27) + return TRUE; + } + return FALSE; +} + +static gboolean +history_next(GntWidget *widget, GList *null) +{ + GntEntry *entry = GNT_ENTRY(widget); + if (entry->histlength && entry->history->next) { - if (strcmp(text + 1, GNT_KEY_DEL) == 0 && entry->cursor < entry->end) + if (entry->history->prev == NULL) { - delkey(entry); - return TRUE; + /* Save the current contents */ + char *text = g_strdup(gnt_entry_get_text(entry)); + g_free(entry->history->data); + entry->history->data = text; } - else if (strcmp(text + 1, GNT_KEY_LEFT) == 0) - { - move_back(entry); - return TRUE; - } - else if (strcmp(text + 1, GNT_KEY_RIGHT) == 0) - { - move_forward(entry); - return TRUE; - } - else if (strcmp(text + 1, GNT_KEY_HOME) == 0) - { - move_start(entry); - return TRUE; - } - else if (strcmp(text + 1, GNT_KEY_END) == 0) - { - move_end(entry); - return TRUE; - } - else if (strcmp(text + 1, GNT_KEY_CTRL_DOWN) == 0 && entry->histlength) - { - if (entry->history->prev) - { - entry->history = entry->history->prev; - gnt_entry_set_text(entry, entry->history->data); - destroy_suggest(entry); - return TRUE; - } - } - else if (strcmp(text + 1, GNT_KEY_UP) == 0 || - strcmp(text + 1, GNT_KEY_DOWN) == 0) - { - if (entry->ddown) - { - gnt_widget_key_pressed(entry->ddown, text); - return TRUE; - } - } - else if (strcmp(text + 1, GNT_KEY_CTRL_UP) == 0 && entry->histlength) - { - if (entry->history->next) - { - if (entry->history->prev == NULL) - { - /* Save the current contents */ - char *text = g_strdup(gnt_entry_get_text(entry)); - g_free(entry->history->data); - entry->history->data = text; - } + entry->history = entry->history->next; + gnt_entry_set_text(entry, entry->history->data); + destroy_suggest(entry); - entry->history = entry->history->next; - gnt_entry_set_text(entry, entry->history->data); - destroy_suggest(entry); + return TRUE; + } + return FALSE; +} - return TRUE; - } - } - else if (text[1] == 0) +static gboolean +suggest_show(GntWidget *widget, GList *null) +{ + return show_suggest_dropdown(GNT_ENTRY(widget)); +} + +static gboolean +suggest_next(GntWidget *widget, GList *null) +{ + GntEntry *entry = GNT_ENTRY(widget); + if (entry->ddown) { + gnt_widget_perform_action_named(entry->ddown, "move-down", NULL); + return TRUE; + } + return FALSE; +} + +static gboolean +suggest_prev(GntWidget *widget, GList *null) +{ + GntEntry *entry = GNT_ENTRY(widget); + if (entry->ddown) { + gnt_widget_perform_action_named(entry->ddown, "move-up", NULL); + return TRUE; + } + return FALSE; +} + +static gboolean +del_to_home(GntWidget *widget, GList *null) +{ + GntEntry *entry = GNT_ENTRY(widget); + memmove(entry->start, entry->cursor, entry->end - entry->cursor); + entry->end -= (entry->cursor - entry->start); + entry->cursor = entry->scroll = entry->start; + memset(entry->end, '\0', entry->buffer - (entry->end - entry->start)); + entry_redraw(widget); + return TRUE; +} + +static gboolean +del_to_end(GntWidget *widget, GList *null) +{ + GntEntry *entry = GNT_ENTRY(widget); + entry->end = entry->cursor; + memset(entry->end, '\0', entry->buffer - (entry->end - entry->start)); + entry_redraw(widget); + return TRUE; +} + +static gboolean +gnt_entry_key_pressed(GntWidget *widget, const char *text) +{ + GntEntry *entry = GNT_ENTRY(widget); + + if (text[0] == 27) + { + if (text[1] == 0) { destroy_suggest(entry); + return TRUE; } return FALSE; @@ -400,60 +437,6 @@ entry_redraw(widget); return TRUE; } - else - { - if (strcmp(text, GNT_KEY_BACKSPACE) == 0 && entry->cursor > entry->start) - { - backspace(entry); - return TRUE; - } - else if (strcmp(text, GNT_KEY_CTRL_A) == 0) - { - move_start(entry); - return TRUE; - } - else if (strcmp(text, GNT_KEY_CTRL_B) == 0) - { - move_back(entry); - return TRUE; - } - else if (strcmp(text, GNT_KEY_CTRL_D) == 0) - { - delkey(entry); - return TRUE; - } - else if (strcmp(text, GNT_KEY_CTRL_E) == 0) - { - move_end(entry); - return TRUE; - } - else if (strcmp(text, GNT_KEY_CTRL_F) == 0) - { - move_forward(entry); - return TRUE; - } - else if (strcmp(text, GNT_KEY_CTRL_H) == 0) - { - backspace(entry); - return TRUE; - } - else if (strcmp(text, GNT_KEY_CTRL_K) == 0) - { - entry->end = entry->cursor; - memset(entry->end, '\0', entry->buffer - (entry->end - entry->start)); - entry_redraw(widget); - return TRUE; - } - else if (strcmp(text, GNT_KEY_CTRL_U) == 0) - { - memmove(entry->start, entry->cursor, entry->end - entry->cursor); - entry->end -= (entry->cursor - entry->start); - entry->cursor = entry->scroll = entry->start; - memset(entry->end, '\0', entry->buffer - (entry->end - entry->start)); - entry_redraw(widget); - return TRUE; - } - } } return FALSE; @@ -503,6 +486,49 @@ parent_class->key_pressed = gnt_entry_key_pressed; parent_class->lost_focus = gnt_entry_lost_focus; + parent_class->actions = g_hash_table_duplicate(parent_class->actions, g_str_hash, + g_str_equal, g_free, (GDestroyNotify)gnt_widget_action_free); + parent_class->bindings = g_hash_table_duplicate(parent_class->bindings, g_str_hash, + g_str_equal, g_free, (GDestroyNotify)gnt_widget_action_param_free); + + gnt_widget_class_register_action(parent_class, "cursor-home", move_start, + GNT_KEY_CTRL_A, NULL); + gnt_widget_register_binding(parent_class, "cursor-home", "\033" GNT_KEY_HOME, NULL); + gnt_widget_class_register_action(parent_class, "cursor-end", move_end, + GNT_KEY_CTRL_E, NULL); + gnt_widget_register_binding(parent_class, "cursor-end", "\033" GNT_KEY_END, NULL); + gnt_widget_class_register_action(parent_class, "delete-prev", backspace, + GNT_KEY_BACKSPACE, NULL); + gnt_widget_class_register_action(parent_class, "delete-next", delkey, + "\033" GNT_KEY_DEL, NULL); + gnt_widget_register_binding(parent_class, "delete-next", GNT_KEY_CTRL_D, NULL); + gnt_widget_class_register_action(parent_class, "delete-start", del_to_home, + GNT_KEY_CTRL_U, NULL); + gnt_widget_class_register_action(parent_class, "delete-end", del_to_end, + GNT_KEY_CTRL_K, NULL); +#if 0 + gnt_widget_class_register_action(parent_class, "delete-prev-word", del_prev_word, + NULL, 1, NULL); + gnt_widget_class_register_action(parent_class, "delete-next-word", del_next_word, + NULL, 1, NULL); +#endif + gnt_widget_class_register_action(parent_class, "cursor-prev", move_back, + "\033" GNT_KEY_LEFT, NULL); + gnt_widget_class_register_action(parent_class, "cursor-next", move_forward, + "\033" GNT_KEY_RIGHT, NULL); + gnt_widget_class_register_action(parent_class, "suggest-show", suggest_show, + "\t", NULL); + gnt_widget_class_register_action(parent_class, "suggest-next", suggest_next, + "\033" GNT_KEY_DOWN, NULL); + gnt_widget_class_register_action(parent_class, "suggest-prev", suggest_prev, + "\033" GNT_KEY_UP, NULL); + gnt_widget_class_register_action(parent_class, "history-prev", history_prev, + "\033" GNT_KEY_CTRL_UP, NULL); + gnt_widget_class_register_action(parent_class, "history-next", history_next, + "\033" GNT_KEY_CTRL_DOWN, NULL); + + gnt_style_read_actions(G_OBJECT_CLASS_TYPE(klass), klass); + GNTDEBUG; } Modified: trunk/console/libgnt/gntkeys.h =================================================================== --- trunk/console/libgnt/gntkeys.h 2006-10-21 20:40:12 UTC (rev 17557) +++ trunk/console/libgnt/gntkeys.h 2006-10-21 21:08:24 UTC (rev 17558) @@ -23,6 +23,7 @@ #define GNT_KEY_BACKSPACE "\177" #define GNT_KEY_DEL "[3~" +#define GNT_KEY_INS "[2~" #define GNT_KEY_CTRL_A "\001" #define GNT_KEY_CTRL_B "\002" @@ -47,6 +48,19 @@ #define GNT_KEY_CTRL_X "\030" #define GNT_KEY_CTRL_Y "\031" +#define GNT_KEY_F1 "[[A" +#define GNT_KEY_F2 "[[B" +#define GNT_KEY_F3 "[[C" +#define GNT_KEY_F4 "[[D" +#define GNT_KEY_F5 "[[E" +#define GNT_KEY_F6 "[17~" +#define GNT_KEY_F7 "[18~" +#define GNT_KEY_F8 "[19~" +#define GNT_KEY_F9 "[20~" +#define GNT_KEY_F10 "[21~" +#define GNT_KEY_F11 "[23~" +#define GNT_KEY_F12 "[24~" + /** * This will do stuff with the terminal settings and stuff. */ Modified: trunk/console/libgnt/gntstyle.c =================================================================== --- trunk/console/libgnt/gntstyle.c 2006-10-21 20:40:12 UTC (rev 17557) +++ trunk/console/libgnt/gntstyle.c 2006-10-21 21:08:24 UTC (rev 17558) @@ -79,6 +79,141 @@ *t = '\0'; } +static char * +parse_key(const char *key) +{ + char *ret = NULL; + int ctrl = 0, alt = 0; + char k; + + /* XXX: Need to do something about ctrl/alt+home, end etc. */ + +#define SPECIAL_KEY(k, code) do { \ + if (strncasecmp(key, k, sizeof(k) - 1) == 0) \ + return g_strdup(code); \ + } while (0) + + SPECIAL_KEY("home", "\033" GNT_KEY_HOME); + SPECIAL_KEY("end", "\033" GNT_KEY_END); + SPECIAL_KEY("pageup", "\033" GNT_KEY_PGUP); + SPECIAL_KEY("pagedown", "\033" GNT_KEY_PGDOWN); + SPECIAL_KEY("insert", "\033" GNT_KEY_INS); + SPECIAL_KEY("delete", "\033" GNT_KEY_DEL); + + SPECIAL_KEY("left", "\033" GNT_KEY_LEFT); + SPECIAL_KEY("right", "\033" GNT_KEY_RIGHT); + SPECIAL_KEY("up", "\033" GNT_KEY_UP); + SPECIAL_KEY("down", "\033" GNT_KEY_DOWN); + + SPECIAL_KEY("tab", "\t"); + SPECIAL_KEY("menu", "\033" GNT_KEY_POPUP); + + SPECIAL_KEY("f1", "\033" GNT_KEY_F1); + SPECIAL_KEY("f2", "\033" GNT_KEY_F2); + SPECIAL_KEY("f3", "\033" GNT_KEY_F3); + SPECIAL_KEY("f4", "\033" GNT_KEY_F4); + SPECIAL_KEY("f5", "\033" GNT_KEY_F5); + SPECIAL_KEY("f6", "\033" GNT_KEY_F6); + SPECIAL_KEY("f7", "\033" GNT_KEY_F7); + SPECIAL_KEY("f8", "\033" GNT_KEY_F8); + SPECIAL_KEY("f9", "\033" GNT_KEY_F9); + SPECIAL_KEY("f10", "\033" GNT_KEY_F10); + SPECIAL_KEY("f11", "\033" GNT_KEY_F11); + SPECIAL_KEY("f12", "\033" GNT_KEY_F12); + +#undef SPECIAL_KEY + +#define MATCH(string, var) do { \ + if (strncasecmp(key, string, sizeof(string) - 1) == 0) { \ + key += sizeof(string) - 1; \ + var = 1; \ + } \ + }while (0) + + MATCH("c-", ctrl); + MATCH("ctl-", ctrl); + MATCH("ctr-", ctrl); + MATCH("ctrl-", ctrl); + + MATCH("alt-", alt); + MATCH("a-", alt); + MATCH("m-", alt); + MATCH("meta-", alt); + + if (strlen(key) != 1) /* We can only have stuff like "ctrl-alt-a" */ + return NULL; + + if (ctrl && (strchr("hijm", *key) != NULL || !isalpha(*key))) { + /* These keys cannot be used with ctrl */ + return NULL; + } + + if (ctrl) + k = *key | 0x20; + else + k = *key; + + ret = g_strdup_printf("%s%c", alt ? "\033" : "", ctrl ? k - 0x60 : k); + +#undef MATCH + + return ret; +} + +void gnt_style_read_actions(GType type, GntWidgetClass *klass) +{ +#if GLIB_CHECK_VERSION(2,6,0) + char *name; + GError *error = NULL; + + name = g_strdup_printf("%s::binding", g_type_name(type)); + + if (g_key_file_has_group(gkfile, name)) + { + unsigned int len = 0; + char **keys; + + keys = g_key_file_get_keys(gkfile, name, &len, &error); + if (error) + { + g_printerr("GntStyle: %s\n", error->message); + g_error_free(error); + g_free(name); + return; + } + + while (len--) + { + char *key, *action; + + key = g_strdup(keys[len]); + action = g_key_file_get_string(gkfile, name, keys[len], &error); + + if (error) + { + g_printerr("GntStyle: %s\n", error->message); + g_error_free(error); + error = NULL; + } + else + { + char *keycode = parse_key(key); + if (keycode == NULL) { + g_printerr("GntStyle: Invalid key-binding %s\n", key); + } else { + gnt_widget_register_binding(klass, action, keycode, NULL); + g_free(keycode); + } + } + g_free(key); + g_free(action); + } + g_strfreev(keys); + } + g_free(name); +#endif +} + void gnt_styles_get_keyremaps(GType type, GHashTable *hash) { #if GLIB_CHECK_VERSION(2,6,0) @@ -97,6 +232,7 @@ { g_printerr("GntStyle: %s\n", error->message); g_error_free(error); + g_free(name); return; } Modified: trunk/console/libgnt/gnttree.c =================================================================== --- trunk/console/libgnt/gnttree.c 2006-10-21 20:40:12 UTC (rev 17557) +++ trunk/console/libgnt/gnttree.c 2006-10-21 21:08:24 UTC (rev 17558) @@ -480,111 +480,108 @@ return g_hash_table_lookup(tree->hash, key); } -static void -action_down(GntTree *tree) +static gboolean +action_down(GntWidget *widget, GList *null) { int dist; + GntTree *tree = GNT_TREE(widget); + GntTreeRow *old = tree->current; GntTreeRow *row = get_next(tree->current); if (row == NULL) - return; + return FALSE; tree->current = row; if ((dist = get_distance(tree->current, tree->bottom)) < 0) gnt_tree_scroll(tree, -dist); else redraw_tree(tree); + if (old != tree->current) + tree_selection_changed(tree, old, tree->current); + return TRUE; } -static void -action_up(GntTree *tree) +static gboolean +action_up(GntWidget *widget, GList *list) { int dist; + GntTree *tree = GNT_TREE(widget); + GntTreeRow *old = tree->current; GntTreeRow *row = get_prev(tree->current); if (!row) - return; + return FALSE; tree->current = row; if ((dist = get_distance(tree->current, tree->top)) > 0) gnt_tree_scroll(tree, -dist); else redraw_tree(tree); + if (old != tree->current) + tree_selection_changed(tree, old, tree->current); + + return TRUE; } static gboolean -gnt_tree_key_pressed(GntWidget *widget, const char *text) +action_page_down(GntWidget *widget, GList *null) { GntTree *tree = GNT_TREE(widget); GntTreeRow *old = tree->current; + GntTreeRow *row = get_next(tree->bottom); + if (row) + { + int dist = get_distance(tree->top, tree->current); + tree->top = tree->bottom; + tree->current = get_next_n_opt(tree->top, dist, NULL); + redraw_tree(tree); + } + else if (tree->current != tree->bottom) + { + tree->current = tree->bottom; + redraw_tree(tree); + } + + if (old != tree->current) + tree_selection_changed(tree, old, tree->current); + return TRUE; +} + +static gboolean +action_page_up(GntWidget *widget, GList *null) +{ + GntTree *tree = GNT_TREE(widget); GntTreeRow *row; - int dist; + GntTreeRow *old = tree->current; - if (text[0] == 27) + if (tree->top != tree->root) { - if (strcmp(text+1, GNT_KEY_DOWN) == 0) - { - action_down(tree); - } - else if (strcmp(text+1, GNT_KEY_UP) == 0) - { - action_up(tree); - } - else if (strcmp(text+1, GNT_KEY_PGDOWN) == 0) - { - row = get_next(tree->bottom); - if (row) - { - int dist = get_distance(tree->top, tree->current); - tree->top = tree->bottom; - tree->current = get_next_n_opt(tree->top, dist, NULL); - redraw_tree(tree); - } - else if (tree->current != tree->bottom) - { - tree->current = tree->bottom; - redraw_tree(tree); - } - } - else if (strcmp(text+1, GNT_KEY_PGUP) == 0) - { - if (tree->top != tree->root) - { - int dist = get_distance(tree->top, tree->current); - row = get_prev_n(tree->top, widget->priv.height - 1 - - tree->show_title * 2 - 2 * (GNT_WIDGET_IS_FLAG_SET(widget, GNT_WIDGET_NO_BORDER) == 0)); - if (row == NULL) - row = tree->root; - tree->top = row; - tree->current = get_next_n_opt(tree->top, dist, NULL); - redraw_tree(tree); - } - else if (tree->current != tree->top) - { - tree->current = tree->top; - redraw_tree(tree); - } - } + int dist = get_distance(tree->top, tree->current); + row = get_prev_n(tree->top, widget->priv.height - 1 - + tree->show_title * 2 - 2 * (GNT_WIDGET_IS_FLAG_SET(widget, GNT_WIDGET_NO_BORDER) == 0)); + if (row == NULL) + row = tree->root; + tree->top = row; + tree->current = get_next_n_opt(tree->top, dist, NULL); + redraw_tree(tree); } - else if (iscntrl(text[0])) + else if (tree->current != tree->top) { - if (strcmp(text, GNT_KEY_CTRL_N) == 0 && (row = get_next(tree->current)) != NULL) - { - tree->current = row; - if ((dist = get_distance(tree->current, tree->bottom)) < 0) - gnt_tree_scroll(tree, -dist); - else - redraw_tree(tree); - } - else if (strcmp(text, GNT_KEY_CTRL_P) == 0 && (row = get_prev(tree->current)) != NULL) - { - tree->current = row; + tree->current = tree->top; + redraw_tree(tree); + } + if (old != tree->current) + tree_selection_changed(tree, old, tree->current); + return TRUE; +} - if ((dist = get_distance(tree->current, tree->top)) > 0) - gnt_tree_scroll(tree, -dist); - else - redraw_tree(tree); - } - else if (text[0] == '\r') - { - gnt_widget_activate(widget); - } +static gboolean +gnt_tree_key_pressed(GntWidget *widget, const char *text) +{ + GntTree *tree = GNT_TREE(widget); + GntTreeRow *old = tree->current; + GntTreeRow *row; + int dist; + + if (text[0] == '\r') + { + gnt_widget_activate(widget); } else if (text[0] == ' ' && text[1] == 0) { @@ -634,9 +631,9 @@ GntTree *tree = GNT_TREE(widget); GntTreeRow *old = tree->current; if (event == GNT_MOUSE_SCROLL_UP) { - action_up(GNT_TREE(widget)); + action_up(widget, NULL); } else if (event == GNT_MOUSE_SCROLL_DOWN) { - action_down(GNT_TREE(widget)); + action_down(widget, NULL); } else if (event == GNT_LEFT_MOUSE_DOWN) { GntTreeRow *row; GntTree *tree = GNT_TREE(widget); @@ -706,6 +703,24 @@ g_cclosure_marshal_VOID__POINTER, G_TYPE_NONE, 1, G_TYPE_POINTER); + parent_class->actions = g_hash_table_duplicate(parent_class->actions, g_str_hash, + g_str_equal, g_free, (GDestroyNotify)gnt_widget_action_free); + parent_class->bindings = g_hash_table_duplicate(parent_class->bindings, g_str_hash, + g_str_equal, g_free, (GDestroyNotify)gnt_widget_action_param_free); + + gnt_widget_class_register_action(parent_class, "move-up", action_up, + "\033" GNT_KEY_UP, NULL); + gnt_widget_register_binding(parent_class, "move-up", "\033" GNT_KEY_CTRL_N, NULL); + gnt_widget_class_register_action(parent_class, "move-down", action_down, + "\033" GNT_KEY_DOWN, NULL); + gnt_widget_register_binding(parent_class, "move-down", "\033" GNT_KEY_CTRL_P, NULL); + gnt_widget_class_register_action(parent_class, "page-up", action_page_up, + "\033" GNT_KEY_PGUP, NULL); + gnt_widget_class_register_action(parent_class, "page-down", action_page_down, + "\033" GNT_KEY_PGDOWN, NULL); + + gnt_style_read_actions(G_OBJECT_CLASS_TYPE(klass), klass); + GNTDEBUG; } @@ -1350,11 +1365,9 @@ for (i = 0; i < tree->ncol; i++) { gnt_tree_set_col_width(tree, i, widths[i]); twidth += widths[i] + (tree->show_separator ? 1 : 0) + 1; - fprintf(stderr, "column width for col %d: %d\n", i, widths[i]); } g_free(widths); - fprintf(stderr, "tree width: %d\n", twidth); gnt_widget_get_size(GNT_WIDGET(tree), NULL, &height); gnt_widget_set_size(GNT_WIDGET(tree), twidth, height); } Modified: trunk/console/libgnt/gntutils.c =================================================================== --- trunk/console/libgnt/gntutils.c 2006-10-21 20:40:12 UTC (rev 17557) +++ trunk/console/libgnt/gntutils.c 2006-10-21 21:08:24 UTC (rev 17558) @@ -105,3 +105,17 @@ return g_string_free(str, FALSE); } +static void +duplicate_values(gpointer key, gpointer value, gpointer data) +{ + g_hash_table_insert(data, key, value); +} + +GHashTable *g_hash_table_duplicate(GHashTable *src, GHashFunc hash, + GEqualFunc equal, GDestroyNotify key_d, GDestroyNotify value_d) +{ + GHashTable *dest = g_hash_table_new_full(hash, equal, key_d, value_d); + g_hash_table_foreach(src, duplicate_values, dest); + return dest; +} + Modified: trunk/console/libgnt/gntutils.h =================================================================== --- trunk/console/libgnt/gntutils.h 2006-10-21 20:40:12 UTC (rev 17557) +++ trunk/console/libgnt/gntutils.h 2006-10-21 21:08:24 UTC (rev 17558) @@ -17,3 +17,6 @@ * Returns a newly allocated string. */ char *gnt_util_onscreen_fit_string(const char *string, int maxw); + +GHashTable *g_hash_table_duplicate(GHashTable *src, GHashFunc hash, + GEqualFunc equal, GDestroyNotify key_d, GDestroyNotify value_d); Modified: trunk/console/libgnt/gntwidget.c =================================================================== --- trunk/console/libgnt/gntwidget.c 2006-10-21 20:40:12 UTC (rev 17557) +++ trunk/console/libgnt/gntwidget.c 2006-10-21 21:08:24 UTC (rev 17558) @@ -234,6 +234,13 @@ gnt_closure_marshal_BOOLEAN__INT_INT_INT, G_TYPE_BOOLEAN, 3, G_TYPE_INT, G_TYPE_INT, G_TYPE_INT); + klass->actions = g_hash_table_new_full(g_str_hash, g_str_equal, g_free, + (GDestroyNotify)gnt_widget_action_free); + klass->bindings = g_hash_table_new_full(g_str_hash, g_str_equal, g_free, + (GDestroyNotify)gnt_widget_action_param_free); + + gnt_style_read_actions(G_OBJECT_CLASS_TYPE(klass), klass); + GNTDEBUG; } @@ -384,12 +391,56 @@ } gboolean +gnt_widget_perform_action_named(GntWidget *widget, const char *name, ...) +{ + GType type = G_OBJECT_TYPE(widget); + GntWidgetClass *klass = GNT_WIDGET_CLASS(G_OBJECT_GET_CLASS(widget)); + GList *list = NULL; + va_list args; + GntWidgetAction *action; + void *p; + + va_start(args, name); + while ((p = va_arg(args, void *)) != NULL) + list = g_list_append(list, p); + va_end(args); + + action = g_hash_table_lookup(klass->actions, name); + if (action && action->u.action) { + if (list) + return action->u.action(widget, list); + else + return action->u.action_noparam(widget); + } + return FALSE; +} + +static gboolean +gnt_widget_perform_action(GntWidget *widget, const char *keys) +{ + GType type = G_OBJECT_TYPE(widget); + GntWidgetClass *klass = GNT_WIDGET_CLASS(G_OBJECT_GET_CLASS(widget)); + GntWidgetActionParam *param = g_hash_table_lookup(klass->bindings, keys); + + if (param && param->action) { + if (param->list) + return param->action->u.action(widget, param->list); + else + return param->action->u.action_noparam(widget); + } + return FALSE; +} + +gboolean gnt_widget_key_pressed(GntWidget *widget, const char *keys) { gboolean ret; if (!GNT_WIDGET_IS_FLAG_SET(widget, GNT_WIDGET_CAN_TAKE_FOCUS)) return FALSE; + if (gnt_widget_perform_action(widget, keys)) + return TRUE; + keys = gnt_widget_remap_keys(widget, keys); g_signal_emit(widget, signals[SIG_KEY_PRESSED], 0, keys, &ret); return ret; @@ -632,3 +683,71 @@ gnt_style_get_bool(GNT_STYLE_SHADOW, FALSE)); } +static void +register_binding(GntWidgetClass *klass, const char *name, const char *trigger, GList *list) +{ + GntWidgetActionParam *param; + + if (name == NULL || *name == '\0') { + g_hash_table_remove(klass->bindings, (char*)trigger); + return; + } + + param = g_new0(GntWidgetActionParam, 1); + param->action = g_hash_table_lookup(klass->actions, name); + param->list = list; + g_hash_table_replace(klass->bindings, g_strdup(trigger), param); +} + +void gnt_widget_register_binding(GntWidgetClass *klass, const char *name, + const char *trigger, ...) +{ + GList *list = NULL; + va_list args; + void *data; + + va_start(args, trigger); + while ((data = va_arg(args, void *))) { + list = g_list_append(list, data); + } + va_end(args); + + register_binding(klass, name, trigger, list); +} + +void gnt_widget_class_register_action(GntWidgetClass *klass, const char *name, + GntWidgetActionCallback callback, + const char *trigger, ...) +{ + void *data; + va_list args; + GntWidgetAction *action = g_new0(GntWidgetAction, 1); + GList *list; + + action->name = g_strdup(name); + action->u.action = callback; + + g_hash_table_replace(klass->actions, g_strdup(name), action); + + list = NULL; + va_start(args, trigger); + while ((data = va_arg(args, void *))) { + list = g_list_append(list, data); + } + va_end(args); + + register_binding(klass, name, trigger, list); +} + +void gnt_widget_action_free(GntWidgetAction *action) +{ + g_free(action->name); + g_free(action); +} + +void gnt_widget_action_param_free(GntWidgetActionParam *param) +{ + g_list_free(param->list); /* XXX: There may be a leak here for string parameters */ + g_free(param); +} + Modified: trunk/console/libgnt/gntwidget.h =================================================================== --- trunk/console/libgnt/gntwidget.h 2006-10-21 20:40:12 UTC (rev 17557) +++ trunk/console/libgnt/gntwidget.h 2006-10-21 21:08:24 UTC (rev 17558) @@ -88,6 +88,8 @@ GObjectClass parent; GHashTable *remaps; /* Key remaps */ + GHashTable *actions; /* name -> Action */ + GHashTable *bindings; /* key -> ActionParam */ void (*map)(GntWidget *obj); void (*show)(GntWidget *obj); /* This will call draw() and take focus (if it can take focus) */ @@ -149,6 +151,40 @@ gboolean gnt_widget_has_shadow(GntWidget *widget); +/******************/ +/* Widget Actions */ +/******************/ +typedef gboolean (*GntWidgetActionCallback) (GntWidget *widget, GList *params); +typedef gboolean (*GntWidgetActionCallbackNoParam)(GntWidget *widget); + +typedef struct _GnWidgetAction GntWidgetAction; +typedef struct _GnWidgetActionParam GntWidgetActionParam; + +struct _GnWidgetAction +{ + char *name; /* The name of the action */ + union { + gboolean (*action)(GntWidget *widget, GList *params); + gboolean (*action_noparam)(GntWidget *widget); + } u; +}; + +struct _GnWidgetActionParam +{ + GntWidgetAction *action; + GList *list; +}; + + +GntWidgetAction *gnt_widget_action_parse(const char *name); + +void gnt_widget_action_free(GntWidgetAction *action); +void gnt_widget_action_param_free(GntWidgetActionParam *param); + + +void gnt_widget_class_register_action(GntWidgetClass *klass, const char *name, + GntWidgetActionCallback callback, const char *trigger, ...); + G_END_DECLS #endif /* GNT_WIDGET_H */ Modified: trunk/console/libgnt/test/multiwin.c =================================================================== --- trunk/console/libgnt/test/multiwin.c 2006-10-21 20:40:12 UTC (rev 17557) +++ trunk/console/libgnt/test/multiwin.c 2006-10-21 21:08:24 UTC (rev 17558) @@ -62,6 +62,7 @@ gnt_tree_add_row_after(GNT_TREE(tree), "6", gnt_tree_create_row(GNT_TREE(tree), "6", " long text", "a2"), "4", NULL); + gnt_tree_add_row_after(GNT_TREE(tree), NULL, NULL, NULL, "4"); int i; for (i = 110; i < 430; i++) { Modified: trunk/console/libgnt/test/tv.c =================================================================== --- trunk/console/libgnt/test/tv.c 2006-10-21 20:40:12 UTC (rev 17557) +++ trunk/console/libgnt/test/tv.c 2006-10-21 21:08:24 UTC (rev 17558) @@ -13,7 +13,7 @@ { gnt_text_view_append_text_with_flags(GNT_TEXT_VIEW(view), gnt_entry_get_text(GNT_ENTRY(w)), - GNT_TEXT_FLAG_HIGHLIGHT); + GNT_TEXT_FLAG_UNDERLINE | GNT_TEXT_FLAG_HIGHLIGHT); gnt_entry_add_to_history(GNT_ENTRY(w), gnt_entry_get_text(GNT_ENTRY(w))); gnt_text_view_next_line(GNT_TEXT_VIEW(view)); gnt_entry_clear(GNT_ENTRY(w)); Modified: trunk/doc/gaim-text.1.in =================================================================== --- trunk/doc/gaim-text.1.in 2006-10-21 20:40:12 UTC (rev 17557) +++ trunk/doc/gaim-text.1.in 2006-10-21 21:08:24 UTC (rev 17558) @@ -192,6 +192,63 @@ \\ = \\r .br +.SH Widget Actions +You can specifiy key-bindings for specific widgets. The following entries in +\fI~/.gntrc\fR correspond to the default keybindings for the actions: + +.br +[GntEntry::binding] +.br +c-a = cursor-home +.br +home = cursor-home +.br +c-e = cursor-end +.br +end = cursor-end +.br +backspace = delete-prev +.br +del = delete-next +.br +c-d = delete-next +.br +c-u = delete-start +.br +c-k = delete-end +.br +left = cursor-prev +.br +right = cursor-next +.br +tab = suggest-show +.br +down = suggest-next +.br +up = suggest-prev +.br + +.br +[GntTree::binding] +.br +up = move-up +.br +down = move-down +.br +c-n = move-down +.br +c-p = move-up +.br +pageup = page-up +.br +pagedown = page-down +.br + +The \fBc-\fR corresponds to the \fBControl\fR key. You can also use \fBctrl-\fR +or \fBctr-\fR or \fBctl-\fR to indicate a combination. For alt-keys, you can use +one of \fBa-\fR, \fBalt-\fR, \fBm-\fR or \fBmeta-\fR. You can also use +\fBhome\fR, \fBend\fR, \fBleft\fR, \fBright\fR etc. keys. + .SH Mouse Support There is experimental mouse support. You can focus windows, activate buttons, select rows in a list, scroll using the wheel-scroll etc. Mouse support is This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <dat...@us...> - 2006-10-21 20:40:29
|
Revision: 17557 http://svn.sourceforge.net/gaim/?rev=17557&view=rev Author: datallah Date: 2006-10-21 13:40:12 -0700 (Sat, 21 Oct 2006) Log Message: ----------- Don't force GTK+ upgrade if there is a compatible version installed. Modified Paths: -------------- trunk/gaim-installer.nsi Modified: trunk/gaim-installer.nsi =================================================================== --- trunk/gaim-installer.nsi 2006-10-21 19:12:54 UTC (rev 17556) +++ trunk/gaim-installer.nsi 2006-10-21 20:40:12 UTC (rev 17557) @@ -64,7 +64,8 @@ !define GAIM_STARTUP_RUN_KEY "SOFTWARE\Microsoft\Windows\CurrentVersion\Run" !define GAIM_UNINST_EXE "gaim-uninst.exe" -!define GTK_VERSION "2.10.6" +!define GTK_MIN_VERSION "2.6.10" +!define GTK_INSTALL_VERSION "2.10.6" !define GTK_REG_KEY "SOFTWARE\GTK\2.0" !define PERL_REG_KEY "SOFTWARE\Perl" !define PERL_DLL "perl58.dll" @@ -320,35 +321,29 @@ File /oname=gtk-runtime.exe ${GTK_RUNTIME_INSTALLER} SetOverwrite off - ; This keeps track whether we install GTK+ or not.. - StrCpy $R5 "0" - Call DoWeNeedGtk Pop $R0 Pop $R6 StrCmp $R0 "0" have_gtk StrCmp $R0 "1" upgrade_gtk - StrCmp $R0 "2" no_gtk no_gtk + StrCmp $R0 "2" upgrade_gtk + StrCmp $R0 "3" no_gtk no_gtk no_gtk: StrCmp $R1 "NONE" gtk_no_install_rights ClearErrors ExecWait '"$TEMP\gtk-runtime.exe" /L=$LANGUAGE $ISSILENT /D=$GTK_FOLDER' - Goto gtk_install_cont + IfErrors gtk_install_error done upgrade_gtk: StrCpy $GTK_FOLDER $R6 + StrCmp $R0 "2" +2 ; Upgrade isn't optional MessageBox MB_YESNO $(GTK_UPGRADE_PROMPT) /SD IDYES IDNO done ClearErrors - ExecWait '"$TEMP\gtk-runtime.exe" /L=$LANGUAGE $ISSILENT' - Goto gtk_install_cont + ExecWait '"$TEMP\gtk-runtime.exe" /L=$LANGUAGE /S /D=$GTK_FOLDER' + IfErrors gtk_install_error done - gtk_install_cont: - IfErrors gtk_install_error - StrCpy $R5 "1" ; marker that says we installed... - Goto done - gtk_install_error: Delete "$TEMP\gtk-runtime.exe" MessageBox MB_OK $(GTK_INSTALL_ERROR) /SD IDOK @@ -967,9 +962,11 @@ ; First Pop: ; 0 - We have the correct version ; Second Pop: Key where Version was found -; 1 - We have an old version that needs to be upgraded +; 1 - We have an old version that should work, prompt user for optional upgrade ; Second Pop: HKLM or HKCU depending on where GTK was found. -; 2 - We don't have Gtk+ at all +; 2 - We have an old version that needs to be upgraded +; Second Pop: HKLM or HKCU depending on where GTK was found. +; 3 - We don't have Gtk+ at all ; Second Pop: "NONE, HKLM or HKCU" depending on our rights.. ; Function DoWeNeedGtk @@ -988,6 +985,7 @@ Push $0 Push $1 Push $2 + Push $3 Call CheckUserInstallRights Pop $1 @@ -1003,23 +1001,23 @@ StrCpy $2 "HKLM" StrCmp $0 "" no_gtk have_gtk - have_gtk: ; GTK+ is already installed.. check version. - ${VersionCompare} ${GTK_VERSION} $0 $0 - IntCmp $0 1 bad_version good_version good_version + ${VersionCompare} ${GTK_INSTALL_VERSION} $0 $3 + IntCmp $3 1 +1 good_version good_version + ${VersionCompare} ${GTK_MIN_VERSION} $0 $3 - bad_version: ; Bad version. If hklm ver and we have hkcu or no rights.. return no gtk - StrCmp $1 "NONE" no_gtk ; if no rights.. can't upgrade - StrCmp $1 "HKCU" 0 upgrade_gtk ; if HKLM can upgrade.. - StrCmp $2 "HKLM" no_gtk upgrade_gtk ; have hkcu rights.. if found hklm ver can't upgrade.. + StrCmp $1 "NONE" no_gtk ; if no rights.. can't upgrade + StrCmp $1 "HKCU" 0 +2 ; if HKLM can upgrade.. + StrCmp $2 "HKLM" no_gtk ; have hkcu rights.. if found hklm ver can't upgrade.. + Push $2 + IntCmp $3 1 +3 + Push "1" ; Optional Upgrade + Goto done + Push "2" ; Mandatory Upgrade + Goto done - upgrade_gtk: - Push $2 - Push "1" - Goto done - good_version: StrCmp $2 "HKLM" have_hklm_gtk have_hkcu_gtk have_hkcu_gtk: @@ -1038,14 +1036,15 @@ no_gtk: Push $1 ; our rights - Push "2" + Push "3" Goto done done: ; The top two items on the stack are what we want to return - Exch 3 + Exch 4 Pop $0 - Exch 3 + Exch 4 + Pop $3 Pop $2 Pop $1 FunctionEnd @@ -1222,8 +1221,8 @@ Pop $R0 Pop $GTK_FOLDER - StrCmp $R0 "0" have_gtk need_gtk - need_gtk: + IntCmp $R0 1 have_gtk have_gtk + MessageBox MB_OK $(GTK_INSTALLER_NEEDED) /SD IDOK Quit have_gtk: @@ -1239,16 +1238,13 @@ Pop $R0 Pop $R1 - StrCmp $R0 "0" have_gtk - StrCmp $R0 "1" upgrade_gtk - StrCmp $R0 "2" no_gtk no_gtk + IntCmp $R0 2 +2 +2 no_gtk + StrCmp $R0 "3" no_gtk no_gtk ; Don't show dir selector.. Upgrades are done to existing path.. - have_gtk: - upgrade_gtk: - Pop $R1 - Pop $R0 - Abort + Pop $R1 + Pop $R0 + Abort no_gtk: StrCmp $R1 "NONE" 0 no_gtk_cont @@ -1267,7 +1263,7 @@ StrCpy $R0 "${GTK_DEFAULT_INSTALL_PATH}" got_path: - StrCpy $name "GTK+ ${GTK_VERSION}" + StrCpy $name "GTK+ ${GTK_INSTALL_VERSION}" StrCpy $GTK_FOLDER $R0 Pop $R1 Pop $R0 This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <dat...@us...> - 2006-10-21 19:13:01
|
Revision: 17556 http://svn.sourceforge.net/gaim/?rev=17556&view=rev Author: datallah Date: 2006-10-21 12:12:54 -0700 (Sat, 21 Oct 2006) Log Message: ----------- This will fix the constant network change notification in Wingaim when "Peer Name Resolution Protocol" service is enabled. We now only look at the Network Location Awareness namespace. Add some better error handling. Modified Paths: -------------- trunk/libgaim/network.c Modified: trunk/libgaim/network.c =================================================================== --- trunk/libgaim/network.c 2006-10-20 23:08:07 UTC (rev 17555) +++ trunk/libgaim/network.c 2006-10-21 19:12:54 UTC (rev 17556) @@ -377,6 +377,9 @@ } #ifdef _WIN32 +#ifndef NS_NLA +#define NS_NLA 15 +#endif static gint wgaim_get_connected_network_count(void) { @@ -388,13 +391,15 @@ memset(&qs, 0, sizeof(WSAQUERYSET)); qs.dwSize = sizeof(WSAQUERYSET); - qs.dwNameSpace = NS_ALL; + qs.dwNameSpace = NS_NLA; retval = WSALookupServiceBegin(&qs, LUP_RETURN_ALL, &h); if (retval != ERROR_SUCCESS) { int errorid = WSAGetLastError(); gchar *msg = g_win32_error_message(errorid); - gaim_debug_warning("network", "Couldn't look up connected networks. %s (%d).\n", msg, errorid); + gaim_debug_warning("network", "Couldn't retrieve NLA SP lookup handle. " + "NLA service is probably not running. Message: %s (%d).\n", + msg, errorid); g_free(msg); return -1; @@ -446,13 +451,11 @@ time_t last_trigger = time(NULL); int WSAAPI (*MyWSANSPIoctl) ( - HANDLE hLookup, DWORD dwControlCode, LPVOID lpvInBuffer, - DWORD cbInBuffer, LPVOID lpvOutBuffer, DWORD cbOutBuffer, - LPDWORD lpcbBytesReturned, LPWSACOMPLETION lpCompletion) = NULL; + HANDLE hLookup, DWORD dwControlCode, LPVOID lpvInBuffer, + DWORD cbInBuffer, LPVOID lpvOutBuffer, DWORD cbOutBuffer, + LPDWORD lpcbBytesReturned, LPWSACOMPLETION lpCompletion) = NULL; - MyWSANSPIoctl = (void*) wgaim_find_and_loadproc("ws2_32.dll", "WSANSPIoctl"); - if (!MyWSANSPIoctl) { - gaim_debug_error("network", "Couldn't load WSANSPIoctl from ws2_32.dll.\n"); + if (!(MyWSANSPIoctl = (void*) wgaim_find_and_loadproc("ws2_32.dll", "WSANSPIoctl"))) { g_thread_exit(NULL); return NULL; } @@ -463,10 +466,18 @@ memset(&qs, 0, sizeof(WSAQUERYSET)); qs.dwSize = sizeof(WSAQUERYSET); - qs.dwNameSpace = NS_ALL; + qs.dwNameSpace = NS_NLA; + if (WSALookupServiceBegin(&qs, 0, &h) == SOCKET_ERROR) { + int errorid = WSAGetLastError(); + gchar *msg = g_win32_error_message(errorid); + gaim_debug_warning("network", "Couldn't retrieve NLA SP lookup handle. " + "NLA service is probably not running. Message: %s (%d).\n", + msg, errorid); + g_free(msg); + g_thread_exit(NULL); + return NULL; + } - retval = WSALookupServiceBegin(&qs, LUP_RETURN_ALL, &h); - /* Make sure at least 30 seconds have elapsed since the last * notification so we don't peg the cpu if this keeps changing. */ if ((time(NULL) - last_trigger) < 30) @@ -475,13 +486,22 @@ last_trigger = time(NULL); /* This will block until there is a network change */ - retval = MyWSANSPIoctl(h, SIO_NSP_NOTIFY_CHANGE, NULL, 0, NULL, 0, &retLen, NULL); + if (MyWSANSPIoctl(h, SIO_NSP_NOTIFY_CHANGE, NULL, 0, NULL, 0, &retLen, NULL) == SOCKET_ERROR) { + int errorid = WSAGetLastError(); + gchar *msg = g_win32_error_message(errorid); + gaim_debug_warning("network", "Unable to wait for changes. Message: %s (%d).\n", + msg, errorid); + g_free(msg); + } retval = WSALookupServiceEnd(h); g_idle_add(wgaim_network_change_thread_cb, NULL); } + + g_thread_exit(NULL); + return NULL; } #endif This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <rl...@us...> - 2006-10-20 23:08:43
|
Revision: 17555 http://svn.sourceforge.net/gaim/?rev=17555&view=rev Author: rlaager Date: 2006-10-20 16:08:07 -0700 (Fri, 20 Oct 2006) Log Message: ----------- Patch from Bj?\195?\182rn Voigt to standardize the Server and Port strings in the QQ prpl. Modified Paths: -------------- trunk/libgaim/protocols/qq/qq.c Modified: trunk/libgaim/protocols/qq/qq.c =================================================================== --- trunk/libgaim/protocols/qq/qq.c 2006-10-20 17:05:30 UTC (rev 17554) +++ trunk/libgaim/protocols/qq/qq.c 2006-10-20 23:08:07 UTC (rev 17555) @@ -1028,10 +1028,10 @@ option = gaim_account_option_bool_new(_("Login Hidden"), "hidden", FALSE); prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option); - option = gaim_account_option_string_new(_("QQ Server"), "server", NULL); + option = gaim_account_option_string_new(_("Server"), "server", NULL); prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option); - option = gaim_account_option_string_new(_("QQ Port"), "port", NULL); + option = gaim_account_option_string_new(_("Port"), "port", NULL); prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option); my_protocol = plugin; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <lsc...@us...> - 2006-10-20 17:05:35
|
Revision: 17554 http://svn.sourceforge.net/gaim/?rev=17554&view=rev Author: lschiere Date: 2006-10-20 10:05:30 -0700 (Fri, 20 Oct 2006) Log Message: ----------- a partial update. There are a few questions I should add, but I'm hoping that they will only be needed for beta4. Modified Paths: -------------- web/htdocs/faq2.txt Modified: web/htdocs/faq2.txt =================================================================== --- web/htdocs/faq2.txt 2006-10-20 15:04:26 UTC (rev 17553) +++ web/htdocs/faq2.txt 2006-10-20 17:05:30 UTC (rev 17554) @@ -505,28 +505,9 @@ generic file transfer API. </p> -Q: Is there a Gaim tray icon, or docklet, or gnome applet, or panel icon, -or <i>some</i>thing? +Q: Can I turn the tray icon off? -A: Yeah, Gaim supports what is called a system tray icon that conforms to -the standards at -<a href="http://www.freedesktop.org/">www.freedesktop.org</a>. -This tray icon is supported by Windows, KDE 3.1, Gnome 2.2, and Red Hat -Gnome 2.0. All you have to do is load the "System Tray Icon" plugin by -going to Preferences and then Plugins. -<p> - If you're using Gnome you need to make sure that your panel has a - Notification Area on it. To add one, right click on the panel, - select Add To Panel->Utility->Notification Area. Gaim will - insert the tray icon in any System Tray implementation that conforms - to these standards, so feel free to write one for your window manager - of choice. -</p> -<p> - Due to a flaw in these specs, KDE users may experience trouble with the - background color of the docklet. There is unfortunately nothing we can - do about this. -</p> +A: Sorry, no. The tray icon will load if you have a Notification Area. Q: What do those colors in the conversation tab mean? @@ -597,7 +578,12 @@ states into the behavior described above. </p> +Q: Why are no states listed when I go to set a state for Auto Away? +A: Gaim can only use saved states for this feature. You need to create +and save a named state first. + + !SECTION AIM/ICQ (OSCAR) Protocol Q: Can I set my profile? @@ -639,21 +625,8 @@ Q: Can I use AIM URI's such as "aim:goim?screenname=robflynn"? -A: Yes, with Gaim 0.60 and higher, but it can be difficult to set up. You -need to pass the entire URI to the gaim-remote program (included with -gaim). To do this with Gnome 2, run gnome-file-types-properties or "File -Types and Programs" from the preferences menu. Add a service with protocol -"aim" and set the program to <code>gaim-remote uri "%s"</code>. This will -make AIM URIs work in Galeon 2. Also, not all types of AIM URI's are -supported. The ones that <i>are</i> supported are goim, addbuddy, and -gochat. -<p> - You'll need a version of gaim compiled with dbus support for this to work. -</p> -<p> - If you use wingaim, this will not work as gaim-remote has not yet been ported - over. -</p> +A: Yes, you need to register gaim-url-handler in your browser. This +requires that Gaim be built with dbus support. Q: Does Gaim support DirectIM and IM Image? @@ -1121,7 +1094,9 @@ A: Merging the gaim-vv code will take time, and we are not sure when it will be ready. Even then, there will remain work to be done before voice -chat, video sharing, or internet phones will work on all protocols. +chat, video sharing, or internet phones will work on all protocols. Right +now there is nothing in subversion related to -vv, we are not sure when +that will change. Q: Where should I report bugs? This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <lsc...@us...> - 2006-10-20 15:04:38
|
Revision: 17553 http://svn.sourceforge.net/gaim/?rev=17553&view=rev Author: lschiere Date: 2006-10-20 08:04:26 -0700 (Fri, 20 Oct 2006) Log Message: ----------- Noticed by Eric Covener, someone messed up :-P Modified Paths: -------------- trunk/gtk/gtkgaim.h Modified: trunk/gtk/gtkgaim.h =================================================================== --- trunk/gtk/gtkgaim.h 2006-10-20 02:38:21 UTC (rev 17552) +++ trunk/gtk/gtkgaim.h 2006-10-20 15:04:26 UTC (rev 17553) @@ -22,7 +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 */ -// #warning ***gtkgaim*** +/* #warning ***gtkgaim*** */ #ifndef _GAIM_GTKGAIM_H_ #define _GAIM_GTKGAIM_H_ This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <sa...@us...> - 2006-10-20 02:38:29
|
Revision: 17552 http://svn.sourceforge.net/gaim/?rev=17552&view=rev Author: sadrul Date: 2006-10-19 19:38:21 -0700 (Thu, 19 Oct 2006) Log Message: ----------- s/GntGaim/Gaim-Text/ in the manpage. Modified Paths: -------------- trunk/doc/gaim-text.1.in Modified: trunk/doc/gaim-text.1.in =================================================================== --- trunk/doc/gaim-text.1.in 2006-10-20 00:19:41 UTC (rev 17551) +++ trunk/doc/gaim-text.1.in 2006-10-20 02:38:21 UTC (rev 17552) @@ -21,7 +21,7 @@ .\" USA. .TH gaim-text 1 .SH NAME -GntGaim \- A Pimpin' Penguin console frontend for Instant Messaging client Gaim. +Gaim-Text \- A Pimpin' Penguin console frontend for Instant Messaging client Gaim. .SH SYNOPSIS .TP 5 \fBgaim-text \fI[options]\fR This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <sa...@us...> - 2006-10-20 00:19:44
|
Revision: 17551 http://svn.sourceforge.net/gaim/?rev=17551&view=rev Author: sadrul Date: 2006-10-19 17:19:41 -0700 (Thu, 19 Oct 2006) Log Message: ----------- Do not print an extra newline for HTML logs. (20:17:27) seanegan: sadrul: are you checking the flags from gaim_log_read? (20:18:18) elb: sadrul: for HTML logs, it should strip 0x0a and turn <br> into 0x0a Modified Paths: -------------- trunk/console/plugins/gnthistory.c Modified: trunk/console/plugins/gnthistory.c =================================================================== --- trunk/console/plugins/gnthistory.c 2006-10-19 22:17:30 UTC (rev 17550) +++ trunk/console/plugins/gnthistory.c 2006-10-20 00:19:41 UTC (rev 17551) @@ -45,7 +45,7 @@ GaimConversationType convtype; GList *logs = NULL; const char *alias = name; - guint flags; + GaimLogReadFlags flags; char *history; char *header; GaimMessageFlags mflag; @@ -119,7 +119,8 @@ gaim_conversation_write(c, "", header, mflag, time(NULL)); g_free(header); - g_strchomp(history); + if (flags & GAIM_LOG_READ_NO_NEWLINE) + gaim_str_strip_char(history, '\n'); gaim_conversation_write(c, "", history, mflag, time(NULL)); g_free(history); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |