[gaim-migrate @ 16994]
If an emblem is really big, scale it down to something sane.
Use a really big emblem (the msn prpl icon) in yahoo.
committer: Tailor Script <tailor@pidgin.im>
line source
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /**
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 * @file gtkaccount.c GTK+ Account Editor UI
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 * @ingroup gtkui
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 *
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 * gaim
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 *
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 * Gaim is the legal property of its developers, whose names are too numerous
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 * to list here. Please refer to the COPYRIGHT file distributed with this
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 * source distribution.
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 *
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 * This program is free software; you can redistribute it and/or modify
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 * it under the terms of the GNU General Public License as published by
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 * the Free Software Foundation; either version 2 of the License, or
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 * (at your option) any later version.
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 *
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 * This program is distributed in the hope that it will be useful,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 * GNU General Public License for more details.
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 *
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 * You should have received a copy of the GNU General Public License
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 * along with this program; if not, write to the Free Software
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 #include "internal.h"
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 #include "gtkgaim.h"
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 #include "account.h"
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 #include "accountopt.h"
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 #include "core.h"
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 #include "debug.h"
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 #include "notify.h"
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 #include "plugin.h"
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 #include "prefs.h"
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 #include "prpl.h"
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 #include "request.h"
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 #include "savedstatuses.h"
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 #include "signals.h"
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 #include "util.h"
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 #include "gtkaccount.h"
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 #include "gtkblist.h"
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 #include "gtkdialogs.h"
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 #include "gtkutils.h"
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 #include "gtkstatusbox.h"
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 #include "gaimstock.h"
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 enum
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 COLUMN_ICON,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 COLUMN_SCREENNAME,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 COLUMN_ENABLED,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 COLUMN_PROTOCOL,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 COLUMN_DATA,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 COLUMN_PULSE_DATA,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 NUM_COLUMNS
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 };
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 typedef struct
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GaimAccount *account;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 char *username;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 char *alias;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 } GaimGtkAccountAddUserData;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 typedef struct
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *window;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *treeview;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *modify_button;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *delete_button;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkListStore *model;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkTreeIter drag_iter;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkTreeViewColumn *screenname_col;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 } AccountsWindow;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 typedef struct
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GaimGtkAccountDialogType type;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GaimAccount *account;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 char *protocol_id;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GaimPlugin *plugin;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GaimPluginProtocolInfo *prpl_info;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GaimProxyType new_proxy_type;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GList *user_split_entries;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GList *protocol_opt_entries;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkSizeGroup *sg;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *window;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *top_vbox;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *bottom_vbox;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *ok_button;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *register_button;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Login Options */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *login_frame;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *protocol_menu;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *password_box;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *screenname_entry;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *password_entry;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *alias_entry;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *remember_pass_check;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* User Options */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *user_frame;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *new_mail_check;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *icon_hbox;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *icon_check;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *icon_entry;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 char *icon_path;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *icon_filesel;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *icon_preview;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *icon_text;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Protocol Options */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *protocol_frame;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Proxy Options */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *proxy_frame;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *proxy_vbox;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *proxy_dropdown;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *proxy_host_entry;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *proxy_port_entry;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *proxy_user_entry;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *proxy_pass_entry;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 } AccountPrefsDialog;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 typedef struct
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GdkPixbuf *online_pixbuf;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gboolean pulse_to_grey;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 float pulse_value;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 int timeout;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GaimAccount *account;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkTreeModel *model;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 } GaimGtkPulseData;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static AccountsWindow *accounts_window = NULL;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static GHashTable *account_pref_wins;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static void add_account_to_liststore(GaimAccount *account, gpointer user_data);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static void set_account(GtkListStore *store, GtkTreeIter *iter,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GaimAccount *account);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /**************************************************************************
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 * Add/Modify Account dialog
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 **************************************************************************/
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static void add_login_options(AccountPrefsDialog *dialog, GtkWidget *parent);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static void add_user_options(AccountPrefsDialog *dialog, GtkWidget *parent);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static void add_protocol_options(AccountPrefsDialog *dialog,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *parent);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static void add_proxy_options(AccountPrefsDialog *dialog, GtkWidget *parent);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static GtkWidget *
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 add_pref_box(AccountPrefsDialog *dialog, GtkWidget *parent,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 const char *text, GtkWidget *widget)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *hbox;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *label;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 hbox = gtk_hbox_new(FALSE, GAIM_HIG_BOX_SPACE);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_box_pack_start(GTK_BOX(parent), hbox, FALSE, FALSE, 0);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_show(hbox);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 label = gtk_label_new_with_mnemonic(text);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_size_group_add_widget(dialog->sg, label);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_misc_set_alignment(GTK_MISC(label), 0, 0.5);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_box_pack_start(GTK_BOX(hbox), label, FALSE, FALSE, 0);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_show(label);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_box_pack_start(GTK_BOX(hbox), widget, TRUE, TRUE, GAIM_HIG_BORDER);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_show(widget);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_set_accessible_label (widget, label);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 return hbox;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static void
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 set_dialog_icon(AccountPrefsDialog *dialog)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 char *filename = gaim_buddy_icons_get_full_path(dialog->icon_path);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GdkPixbuf *pixbuf = NULL;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (filename)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 pixbuf = gdk_pixbuf_new_from_file(filename, NULL);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (pixbuf && dialog->prpl_info &&
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 (dialog->prpl_info->icon_spec.scale_rules & GAIM_ICON_SCALE_DISPLAY))
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 int width, height;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GdkPixbuf *scale;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_gtk_buddy_icon_get_scale_size(pixbuf,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 &dialog->prpl_info->icon_spec, &width, &height);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 scale = gdk_pixbuf_scale_simple(pixbuf, width, height, GDK_INTERP_BILINEAR);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_object_unref(G_OBJECT(pixbuf));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 pixbuf = scale;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_image_set_from_pixbuf(GTK_IMAGE(dialog->icon_entry), pixbuf);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (pixbuf != NULL)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_object_unref(G_OBJECT(pixbuf));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_free(filename);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static void
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 set_account_protocol_cb(GtkWidget *item, const char *id,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 AccountPrefsDialog *dialog)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GaimPlugin *new_plugin;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 new_plugin = gaim_find_prpl(id);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (new_plugin == dialog->plugin)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 return;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->plugin = new_plugin;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (dialog->plugin != NULL)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(dialog->plugin);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_free(dialog->protocol_id);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->protocol_id = g_strdup(dialog->plugin->info->id);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (dialog->account != NULL)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_account_clear_settings(dialog->account);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 add_login_options(dialog, dialog->top_vbox);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 add_user_options(dialog, dialog->top_vbox);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 add_protocol_options(dialog, dialog->bottom_vbox);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (!dialog->prpl_info || !dialog->prpl_info->register_user) {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_hide(dialog->register_button);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 } else {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (dialog->prpl_info != NULL &&
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 (dialog->prpl_info->options & OPT_PROTO_REGISTER_NOSCREENNAME)) {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_set_sensitive(dialog->register_button, TRUE);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 } else {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_set_sensitive(dialog->register_button, FALSE);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_show(dialog->register_button);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static void
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 screenname_changed_cb(GtkEntry *entry, AccountPrefsDialog *dialog)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (dialog->ok_button)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_set_sensitive(dialog->ok_button,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 *gtk_entry_get_text(entry) != '\0');
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (dialog->register_button) {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (dialog->prpl_info != NULL && (dialog->prpl_info->options & OPT_PROTO_REGISTER_NOSCREENNAME))
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_set_sensitive(dialog->register_button, TRUE);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 else
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_set_sensitive(dialog->register_button,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 *gtk_entry_get_text(entry) != '\0');
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static void
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 icon_filesel_choose_cb(const char *filename, gpointer data)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 AccountPrefsDialog *dialog;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog = data;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (filename) {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_free(dialog->icon_path);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->icon_path = gaim_gtk_convert_buddy_icon(dialog->plugin, filename);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 set_dialog_icon(dialog);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_show(dialog->icon_entry);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->icon_filesel = NULL;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static void
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 icon_select_cb(GtkWidget *button, AccountPrefsDialog *dialog)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->icon_filesel = gaim_gtk_buddy_icon_chooser_new(GTK_WINDOW(dialog->window), icon_filesel_choose_cb, dialog);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_show_all(dialog->icon_filesel);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static void
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 icon_reset_cb(GtkWidget *button, AccountPrefsDialog *dialog)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_free(dialog->icon_path);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->icon_path = NULL;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_hide(dialog->icon_entry);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static void
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 account_dnd_recv(GtkWidget *widget, GdkDragContext *dc, gint x, gint y,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkSelectionData *sd, guint info, guint t, AccountPrefsDialog *dialog)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gchar *name = (gchar *)sd->data;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if ((sd->length >= 0) && (sd->format == 8)) {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Well, it looks like the drag event was cool.
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 * Let's do something with it */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (!g_ascii_strncasecmp(name, "file://", 7)) {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GError *converr = NULL;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gchar *tmp, *rtmp;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* It looks like we're dealing with a local file. Let's
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 * just untar it in the right place */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if(!(tmp = g_filename_from_uri(name, NULL, &converr))) {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_debug(GAIM_DEBUG_ERROR, "buddyicon", "%s\n",
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 (converr ? converr->message :
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 "g_filename_from_uri error"));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 return;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if ((rtmp = strchr(tmp, '\r')) || (rtmp = strchr(tmp, '\n')))
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 *rtmp = '\0';
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_free(dialog->icon_path);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->icon_path = gaim_gtk_convert_buddy_icon(dialog->plugin, tmp);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 set_dialog_icon(dialog);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_show(dialog->icon_entry);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_free(tmp);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_drag_finish(dc, TRUE, FALSE, t);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_drag_finish(dc, FALSE, FALSE, t);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static void
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 update_editable(GaimConnection *gc, AccountPrefsDialog *dialog)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gboolean set;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GList *l;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (dialog->account == NULL)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 return;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (gc != NULL && dialog->account != gaim_connection_get_account(gc))
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 return;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 set = !(gaim_account_is_connected(dialog->account) || gaim_account_is_connecting(dialog->account));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_set_sensitive(dialog->protocol_menu, set);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_set_sensitive(dialog->screenname_entry, set);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 for (l = dialog->user_split_entries ; l != NULL ; l = l->next)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_set_sensitive((GtkWidget *)l->data, set);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static void
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 add_login_options(AccountPrefsDialog *dialog, GtkWidget *parent)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *frame;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *vbox;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *entry;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GList *user_splits;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GList *l, *l2;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 char *username = NULL;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (dialog->login_frame != NULL)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_destroy(dialog->login_frame);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Build the login options frame. */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 frame = gaim_gtk_make_frame(parent, _("Login Options"));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* cringe */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->login_frame = gtk_widget_get_parent(gtk_widget_get_parent(frame));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_box_reorder_child(GTK_BOX(parent), dialog->login_frame, 0);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_show(dialog->login_frame);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Main vbox */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 vbox = gtk_vbox_new(FALSE, GAIM_HIG_BOX_SPACE);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_container_add(GTK_CONTAINER(frame), vbox);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_show(vbox);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Protocol */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->protocol_menu = gaim_gtk_protocol_option_menu_new(
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->protocol_id, G_CALLBACK(set_account_protocol_cb), dialog);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 add_pref_box(dialog, vbox, _("Protocol:"), dialog->protocol_menu);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Screen name */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->screenname_entry = gtk_entry_new();
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 add_pref_box(dialog, vbox, _("Screen name:"), dialog->screenname_entry);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_signal_connect(G_OBJECT(dialog->screenname_entry), "changed",
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 G_CALLBACK(screenname_changed_cb), dialog);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Do the user split thang */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (dialog->plugin == NULL) /* Yeah right. */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 user_splits = NULL;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 else
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 user_splits = dialog->prpl_info->user_splits;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (dialog->account != NULL)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 username = g_strdup(gaim_account_get_username(dialog->account));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (dialog->user_split_entries != NULL) {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_list_free(dialog->user_split_entries);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->user_split_entries = NULL;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 for (l = user_splits; l != NULL; l = l->next) {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GaimAccountUserSplit *split = l->data;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 char *buf;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 buf = g_strdup_printf("%s:", gaim_account_user_split_get_text(split));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 entry = gtk_entry_new();
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 add_pref_box(dialog, vbox, buf, entry);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_free(buf);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->user_split_entries =
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_list_append(dialog->user_split_entries, entry);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 for (l = g_list_last(dialog->user_split_entries),
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 l2 = g_list_last(user_splits);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 l != NULL && l2 != NULL;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 l = l->prev, l2 = l2->prev) {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *entry = l->data;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GaimAccountUserSplit *split = l2->data;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 const char *value = NULL;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 char *c;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (dialog->account != NULL) {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 c = strrchr(username,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_account_user_split_get_separator(split));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (c != NULL) {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 *c = '\0';
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 c++;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 value = c;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (value == NULL)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 value = gaim_account_user_split_get_default_value(split);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (value != NULL)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_entry_set_text(GTK_ENTRY(entry), value);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (username != NULL)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_entry_set_text(GTK_ENTRY(dialog->screenname_entry), username);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_free(username);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Password */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->password_entry = gtk_entry_new();
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_entry_set_visibility(GTK_ENTRY(dialog->password_entry), FALSE);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_entry_set_invisible_char(GTK_ENTRY(dialog->password_entry), GAIM_INVISIBLE_CHAR);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->password_box = add_pref_box(dialog, vbox, _("Password:"),
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->password_entry);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Alias */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->alias_entry = gtk_entry_new();
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 add_pref_box(dialog, vbox, _("Local alias:"), dialog->alias_entry);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Remember Password */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->remember_pass_check =
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_check_button_new_with_label(_("Remember password"));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(dialog->remember_pass_check),
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 FALSE);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_box_pack_start(GTK_BOX(vbox), dialog->remember_pass_check,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 FALSE, FALSE, 0);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_show(dialog->remember_pass_check);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Set the fields. */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (dialog->account != NULL) {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (gaim_account_get_password(dialog->account))
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_entry_set_text(GTK_ENTRY(dialog->password_entry),
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_account_get_password(dialog->account));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (gaim_account_get_alias(dialog->account))
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_entry_set_text(GTK_ENTRY(dialog->alias_entry),
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_account_get_alias(dialog->account));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_toggle_button_set_active(
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GTK_TOGGLE_BUTTON(dialog->remember_pass_check),
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_account_get_remember_password(dialog->account));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (dialog->prpl_info != NULL &&
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 (dialog->prpl_info->options & OPT_PROTO_NO_PASSWORD)) {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_hide(dialog->password_box);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_hide(dialog->remember_pass_check);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Do not let the user change the protocol/screenname while connected. */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 update_editable(NULL, dialog);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_signal_connect(gaim_connections_get_handle(), "signing-on", dialog,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 G_CALLBACK(update_editable), dialog);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_signal_connect(gaim_connections_get_handle(), "signed-off", dialog,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 G_CALLBACK(update_editable), dialog);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static void
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 icon_check_cb(GtkWidget *checkbox, AccountPrefsDialog *dialog)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_set_sensitive(dialog->icon_hbox, gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON(dialog->icon_check)));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static void
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 add_user_options(AccountPrefsDialog *dialog, GtkWidget *parent)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *frame;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *vbox;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *vbox2;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *hbox;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *hbox2;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *button;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *label;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (dialog->user_frame != NULL)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_destroy(dialog->user_frame);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Build the user options frame. */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 frame = gaim_gtk_make_frame(parent, _("User Options"));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->user_frame = gtk_widget_get_parent(gtk_widget_get_parent(frame));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_box_reorder_child(GTK_BOX(parent), dialog->user_frame, 1);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_show(dialog->user_frame);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Main vbox */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 vbox = gtk_vbox_new(FALSE, GAIM_HIG_BOX_SPACE);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_container_add(GTK_CONTAINER(frame), vbox);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_show(vbox);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* New mail notifications */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->new_mail_check =
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_check_button_new_with_label(_("New mail notifications"));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_box_pack_start(GTK_BOX(vbox), dialog->new_mail_check, FALSE, FALSE, 0);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_show(dialog->new_mail_check);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Buddy icon */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->icon_check = gtk_check_button_new_with_label(_("Use this buddy icon for this account:"));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_signal_connect(G_OBJECT(dialog->icon_check), "toggled", G_CALLBACK(icon_check_cb), dialog);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_show(dialog->icon_check);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_box_pack_start(GTK_BOX(vbox), dialog->icon_check, FALSE, FALSE, 0);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->icon_hbox = hbox = gtk_hbox_new(FALSE, GAIM_HIG_BOX_SPACE);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_set_sensitive(hbox, gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON(dialog->icon_check)));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_box_pack_start(GTK_BOX(vbox), hbox, FALSE, FALSE, 0);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_show(hbox);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 label = gtk_label_new(" ");
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_box_pack_start(GTK_BOX(hbox), label, FALSE, FALSE, 0);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_show(label);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->icon_entry = gtk_image_new();
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_box_pack_start(GTK_BOX(hbox), dialog->icon_entry,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 FALSE, FALSE, 0);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_show(dialog->icon_entry);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_set_accessible_label (dialog->icon_entry, label);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->icon_path = NULL;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 vbox2 = gtk_vbox_new(FALSE, 0);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_box_pack_start(GTK_BOX(hbox), vbox2, TRUE, TRUE, 0);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_show(vbox2);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 hbox2 = gtk_hbox_new(FALSE, GAIM_HIG_BOX_SPACE);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_box_pack_start(GTK_BOX(vbox2), hbox2, FALSE, FALSE, GAIM_HIG_BORDER);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_show(hbox2);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 button = gtk_button_new_from_stock(GTK_STOCK_OPEN);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_box_pack_start(GTK_BOX(hbox2), button, FALSE, FALSE, 0);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_signal_connect(G_OBJECT(button), "clicked",
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 G_CALLBACK(icon_select_cb), dialog);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_show(button);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 button = gtk_button_new_from_stock(GTK_STOCK_REMOVE);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_signal_connect(G_OBJECT(button), "clicked",
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 G_CALLBACK(icon_reset_cb), dialog);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_box_pack_start(GTK_BOX(hbox2), button, FALSE, FALSE, 0);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_show(button);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (dialog->prpl_info != NULL) {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (!(dialog->prpl_info->options & OPT_PROTO_MAIL_CHECK))
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_hide(dialog->new_mail_check);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (!(dialog->prpl_info->icon_spec.format != NULL))
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_hide(dialog->icon_hbox);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (dialog->account != NULL) {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(dialog->new_mail_check),
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_account_get_check_mail(dialog->account));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(dialog->icon_check),
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 !gaim_account_get_ui_bool(dialog->account, GAIM_GTK_UI, "use-global-buddyicon",
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 TRUE));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->icon_path = g_strdup(gaim_account_get_ui_string(dialog->account, GAIM_GTK_UI, "non-global-buddyicon", NULL));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 set_dialog_icon(dialog);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (!dialog->prpl_info ||
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 (!(dialog->prpl_info->options & OPT_PROTO_MAIL_CHECK) &&
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 (dialog->prpl_info->icon_spec.format == NULL))) {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Nothing to see :( aww. */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_hide(dialog->user_frame);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static void
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 add_protocol_options(AccountPrefsDialog *dialog, GtkWidget *parent)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GaimAccountOption *option;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GaimAccount *account;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *frame, *vbox, *check, *entry, *combo;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 const GList *list, *node;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gint i, idx, int_value;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkListStore *model;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkTreeIter iter;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkCellRenderer *renderer;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GaimKeyValuePair *kvp;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GList *l;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 char buf[1024];
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 char *title;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 const char *str_value;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gboolean bool_value;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (dialog->protocol_frame != NULL) {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_destroy(dialog->protocol_frame);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->protocol_frame = NULL;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (dialog->protocol_opt_entries != NULL) {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_list_free(dialog->protocol_opt_entries);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->protocol_opt_entries = NULL;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (dialog->prpl_info == NULL ||
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->prpl_info->protocol_options == NULL) {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 return;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 account = dialog->account;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Build the protocol options frame. */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_snprintf(buf, sizeof(buf), _("%s Options"), dialog->plugin->info->name);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 frame = gaim_gtk_make_frame(parent, buf);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->protocol_frame =
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_get_parent(gtk_widget_get_parent(frame));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_box_reorder_child(GTK_BOX(parent), dialog->protocol_frame, 0);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_show(dialog->protocol_frame);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Main vbox */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 vbox = gtk_vbox_new(FALSE, GAIM_HIG_BOX_SPACE);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_container_add(GTK_CONTAINER(frame), vbox);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_show(vbox);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 for (l = dialog->prpl_info->protocol_options; l != NULL; l = l->next)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 option = (GaimAccountOption *)l->data;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 switch (gaim_account_option_get_type(option))
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 case GAIM_PREF_BOOLEAN:
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (account == NULL ||
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 strcmp(gaim_account_get_protocol_id(account),
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->protocol_id))
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 bool_value = gaim_account_option_get_default_bool(option);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 else
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 bool_value = gaim_account_get_bool(account,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_account_option_get_setting(option),
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_account_option_get_default_bool(option));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 check = gtk_check_button_new_with_label(
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_account_option_get_text(option));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(check),
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 bool_value);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_box_pack_start(GTK_BOX(vbox), check, FALSE, FALSE, 0);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_show(check);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->protocol_opt_entries =
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_list_append(dialog->protocol_opt_entries, check);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 break;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 case GAIM_PREF_INT:
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (account == NULL ||
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 strcmp(gaim_account_get_protocol_id(account),
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->protocol_id))
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 int_value = gaim_account_option_get_default_int(option);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 else
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 int_value = gaim_account_get_int(account,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_account_option_get_setting(option),
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_account_option_get_default_int(option));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_snprintf(buf, sizeof(buf), "%d", int_value);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 entry = gtk_entry_new();
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_entry_set_text(GTK_ENTRY(entry), buf);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 title = g_strdup_printf("%s:",
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_account_option_get_text(option));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 add_pref_box(dialog, vbox, title, entry);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_free(title);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->protocol_opt_entries =
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_list_append(dialog->protocol_opt_entries, entry);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 break;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 case GAIM_PREF_STRING:
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (account == NULL ||
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 strcmp(gaim_account_get_protocol_id(account),
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->protocol_id))
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 str_value = gaim_account_option_get_default_string(option);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 else
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 str_value = gaim_account_get_string(account,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_account_option_get_setting(option),
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_account_option_get_default_string(option));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 entry = gtk_entry_new();
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (gaim_account_option_get_masked(option))
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_entry_set_visibility(GTK_ENTRY(entry), FALSE);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_entry_set_invisible_char(GTK_ENTRY(entry), GAIM_INVISIBLE_CHAR);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (str_value != NULL)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_entry_set_text(GTK_ENTRY(entry), str_value);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 title = g_strdup_printf("%s:",
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_account_option_get_text(option));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 add_pref_box(dialog, vbox, title, entry);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_free(title);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->protocol_opt_entries =
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_list_append(dialog->protocol_opt_entries, entry);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 break;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 case GAIM_PREF_STRING_LIST:
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 i = 0;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 idx = 0;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (account == NULL ||
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 strcmp(gaim_account_get_protocol_id(account),
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->protocol_id))
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 str_value = gaim_account_option_get_default_list_value(option);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 else
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 str_value = gaim_account_get_string(account,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_account_option_get_setting(option),
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_account_option_get_default_list_value(option));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 list = gaim_account_option_get_list(option);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 model = gtk_list_store_new(2, G_TYPE_STRING, G_TYPE_POINTER);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 combo = gtk_combo_box_new_with_model(GTK_TREE_MODEL(model));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Loop through list of GaimKeyValuePair items */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 for (node = list; node != NULL; node = node->next) {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (node->data != NULL) {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 kvp = (GaimKeyValuePair *) node->data;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if ((kvp->value != NULL) && (str_value != NULL) &&
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 !g_utf8_collate(kvp->value, str_value))
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 idx = i;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_list_store_append(model, &iter);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_list_store_set(model, &iter,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 0, kvp->key,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 1, kvp->value,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 -1);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 i++;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Set default */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_combo_box_set_active(GTK_COMBO_BOX(combo), idx);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Define renderer */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 renderer = gtk_cell_renderer_text_new();
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_cell_layout_pack_start(GTK_CELL_LAYOUT(combo), renderer,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 TRUE);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_cell_layout_set_attributes(GTK_CELL_LAYOUT(combo),
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 renderer, "text", 0, NULL);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 title = g_strdup_printf("%s:",
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_account_option_get_text(option));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 add_pref_box(dialog, vbox, title, combo);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_free(title);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->protocol_opt_entries =
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_list_append(dialog->protocol_opt_entries, combo);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 break;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 default:
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 break;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static GtkWidget *
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 make_proxy_dropdown(void)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *dropdown;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkListStore *model;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkTreeIter iter;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkCellRenderer *renderer;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 model = gtk_list_store_new(2, G_TYPE_STRING, G_TYPE_INT);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dropdown = gtk_combo_box_new_with_model(GTK_TREE_MODEL(model));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_list_store_append(model, &iter);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_list_store_set(model, &iter,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 0, _("Use Global Proxy Settings"),
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 1, GAIM_PROXY_USE_GLOBAL,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 -1);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_list_store_append(model, &iter);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_list_store_set(model, &iter,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 0, _("No Proxy"),
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 1, GAIM_PROXY_NONE,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 -1);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_list_store_append(model, &iter);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_list_store_set(model, &iter,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 0, _("HTTP"),
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 1, GAIM_PROXY_HTTP,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 -1);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_list_store_append(model, &iter);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_list_store_set(model, &iter,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 0, _("SOCKS 4"),
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 1, GAIM_PROXY_SOCKS4,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 -1);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_list_store_append(model, &iter);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_list_store_set(model, &iter,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 0, _("SOCKS 5"),
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 1, GAIM_PROXY_SOCKS5,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 -1);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_list_store_append(model, &iter);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_list_store_set(model, &iter,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 0, _("Use Environmental Settings"),
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 1, GAIM_PROXY_USE_ENVVAR,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 -1);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 renderer = gtk_cell_renderer_text_new();
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_cell_layout_pack_start(GTK_CELL_LAYOUT(dropdown), renderer, TRUE);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_cell_layout_set_attributes(GTK_CELL_LAYOUT(dropdown), renderer,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 "text", 0, NULL);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 return dropdown;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static void
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 proxy_type_changed_cb(GtkWidget *menu, AccountPrefsDialog *dialog)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->new_proxy_type =
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_combo_box_get_active(GTK_COMBO_BOX(menu)) - 1;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (dialog->new_proxy_type == GAIM_PROXY_USE_GLOBAL ||
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->new_proxy_type == GAIM_PROXY_NONE ||
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->new_proxy_type == GAIM_PROXY_USE_ENVVAR) {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_hide_all(dialog->proxy_vbox);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 else
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_show_all(dialog->proxy_vbox);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static void
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 port_popup_cb(GtkWidget *w, GtkMenu *menu, gpointer data)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *item1;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *item2;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* This is an easter egg.
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 It means one of two things, both intended as humourus:
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 A) your network is really slow and you have nothing better to do than
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 look at butterflies.
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 B)You are looking really closely at something that shouldn't matter. */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 item1 = gtk_menu_item_new_with_label(_("If you look real closely"));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* This is an easter egg. See the comment on the previous line in the source. */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 item2 = gtk_menu_item_new_with_label(_("you can see the butterflies mating"));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_show(item1);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_show(item2);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Prepend these in reverse order so they appear correctly. */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_menu_shell_prepend(GTK_MENU_SHELL(menu), item2);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_menu_shell_prepend(GTK_MENU_SHELL(menu), item1);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static void
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 add_proxy_options(AccountPrefsDialog *dialog, GtkWidget *parent)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GaimProxyInfo *proxy_info;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *frame;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *vbox;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *vbox2;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (dialog->proxy_frame != NULL)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_destroy(dialog->proxy_frame);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 frame = gaim_gtk_make_frame(parent, _("Proxy Options"));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->proxy_frame = gtk_widget_get_parent(gtk_widget_get_parent(frame));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_box_reorder_child(GTK_BOX(parent), dialog->proxy_frame, 1);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_show(dialog->proxy_frame);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Main vbox */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 vbox = gtk_vbox_new(FALSE, GAIM_HIG_BOX_SPACE);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_container_add(GTK_CONTAINER(frame), vbox);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_show(vbox);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Proxy Type drop-down. */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->proxy_dropdown = make_proxy_dropdown();
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 add_pref_box(dialog, vbox, _("Proxy _type:"), dialog->proxy_dropdown);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Setup the second vbox, which may be hidden at times. */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->proxy_vbox = vbox2 = gtk_vbox_new(FALSE, GAIM_HIG_BOX_SPACE);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_box_pack_start(GTK_BOX(vbox), vbox2, FALSE, FALSE, GAIM_HIG_BORDER);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_show(vbox2);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Host */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->proxy_host_entry = gtk_entry_new();
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 add_pref_box(dialog, vbox2, _("_Host:"), dialog->proxy_host_entry);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Port */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->proxy_port_entry = gtk_entry_new();
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 add_pref_box(dialog, vbox2, _("_Port:"), dialog->proxy_port_entry);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_signal_connect(G_OBJECT(dialog->proxy_port_entry), "populate-popup",
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 G_CALLBACK(port_popup_cb), NULL);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* User */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->proxy_user_entry = gtk_entry_new();
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 add_pref_box(dialog, vbox2, _("_Username:"), dialog->proxy_user_entry);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Password */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->proxy_pass_entry = gtk_entry_new();
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_entry_set_visibility(GTK_ENTRY(dialog->proxy_pass_entry), FALSE);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_entry_set_invisible_char(GTK_ENTRY(dialog->proxy_pass_entry), GAIM_INVISIBLE_CHAR);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 add_pref_box(dialog, vbox2, _("Pa_ssword:"), dialog->proxy_pass_entry);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (dialog->account != NULL &&
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 (proxy_info = gaim_account_get_proxy_info(dialog->account)) != NULL) {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GaimProxyType type = gaim_proxy_info_get_type(proxy_info);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Hah! */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* I dunno what you're laughing about, fuzz ball. */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->new_proxy_type = type;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_combo_box_set_active(GTK_COMBO_BOX(dialog->proxy_dropdown),
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 type + 1);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (type == GAIM_PROXY_USE_GLOBAL || type == GAIM_PROXY_NONE ||
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 type == GAIM_PROXY_USE_ENVVAR) {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_hide_all(vbox2);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 else {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 const char *value;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 int int_val;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if ((value = gaim_proxy_info_get_host(proxy_info)) != NULL)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_entry_set_text(GTK_ENTRY(dialog->proxy_host_entry), value);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if ((int_val = gaim_proxy_info_get_port(proxy_info)) != 0) {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 char buf[32];
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_snprintf(buf, sizeof(buf), "%d", int_val);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_entry_set_text(GTK_ENTRY(dialog->proxy_port_entry), buf);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if ((value = gaim_proxy_info_get_username(proxy_info)) != NULL)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_entry_set_text(GTK_ENTRY(dialog->proxy_user_entry), value);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if ((value = gaim_proxy_info_get_password(proxy_info)) != NULL)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_entry_set_text(GTK_ENTRY(dialog->proxy_pass_entry), value);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 else {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->new_proxy_type = GAIM_PROXY_USE_GLOBAL;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_combo_box_set_active(GTK_COMBO_BOX(dialog->proxy_dropdown),
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->new_proxy_type + 1);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_hide_all(vbox2);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Connect signals. */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_signal_connect(G_OBJECT(dialog->proxy_dropdown), "changed",
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 G_CALLBACK(proxy_type_changed_cb), dialog);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static void
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 account_win_destroy_cb(GtkWidget *w, GdkEvent *event,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 AccountPrefsDialog *dialog)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_hash_table_remove(account_pref_wins, dialog->account);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_destroy(dialog->window);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_list_free(dialog->user_split_entries);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_list_free(dialog->protocol_opt_entries);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_free(dialog->protocol_id);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (dialog->icon_path != NULL)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 const char *icon = gaim_account_get_ui_string(dialog->account, GAIM_GTK_UI, "non-global-buddyicon", NULL);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (dialog->icon_path != NULL && (icon == NULL || strcmp(dialog->icon_path, icon)))
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* The user set an icon, which would've been cached by convert_buddy_icon,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 * but didn't save the changes. Delete the cache file. */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 char *filename = g_build_filename(gaim_buddy_icons_get_cache_dir(), dialog->icon_path, NULL);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 printf("Deleting\n");
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_unlink(filename);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_free(filename);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_free(dialog->icon_path);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (dialog->icon_filesel)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_destroy(dialog->icon_filesel);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_signals_disconnect_by_handle(dialog);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_free(dialog);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static void
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 cancel_account_prefs_cb(GtkWidget *w, AccountPrefsDialog *dialog)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 account_win_destroy_cb(NULL, NULL, dialog);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static GaimAccount*
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 ok_account_prefs_cb(GtkWidget *w, AccountPrefsDialog *dialog)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GaimProxyInfo *proxy_info = NULL;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GList *l, *l2;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 const char *value;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 char *username;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 char *tmp;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gboolean new = FALSE, icon_change = FALSE;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GaimAccount *account;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GaimPluginProtocolInfo *prpl_info;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (dialog->account == NULL)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 const char *screenname;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 screenname = gtk_entry_get_text(GTK_ENTRY(dialog->screenname_entry));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 account = gaim_account_new(screenname, dialog->protocol_id);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 new = TRUE;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 else
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 account = dialog->account;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Protocol */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_account_set_protocol_id(account, dialog->protocol_id);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Alias */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 value = gtk_entry_get_text(GTK_ENTRY(dialog->alias_entry));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (*value != '\0')
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_account_set_alias(account, value);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 else
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_account_set_alias(account, NULL);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Buddy Icon */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(dialog->plugin);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if ((prpl_info != NULL) && (prpl_info->options & OPT_PROTO_IM_IMAGE))
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (new || gaim_account_get_ui_bool(account, GAIM_GTK_UI, "use-global-buddyicon", TRUE) ==
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON(dialog->icon_check)))
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 icon_change = TRUE;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_account_set_ui_bool(account, GAIM_GTK_UI, "use-global-buddyicon", !gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON(dialog->icon_check)));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_account_set_ui_string(account, GAIM_GTK_UI, "non-global-buddyicon", dialog->icon_path);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON(dialog->icon_check)))
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_account_set_buddy_icon(account, dialog->icon_path);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 else if (gaim_prefs_get_string("/gaim/gtk/accounts/buddyicon") && icon_change)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 char *icon = gaim_gtk_convert_buddy_icon(dialog->plugin, gaim_prefs_get_string("/gaim/gtk/accounts/buddyicon"));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_account_set_buddy_icon(account, icon);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_free(icon);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Remember Password */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_account_set_remember_password(account,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_toggle_button_get_active(
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GTK_TOGGLE_BUTTON(dialog->remember_pass_check)));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Check Mail */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (dialog->prpl_info && dialog->prpl_info->options & OPT_PROTO_MAIL_CHECK)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_account_set_check_mail(account,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_toggle_button_get_active(
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GTK_TOGGLE_BUTTON(dialog->new_mail_check)));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Password */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 value = gtk_entry_get_text(GTK_ENTRY(dialog->password_entry));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /*
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 * We set the password if this is a new account because new accounts
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 * will be set to online, and if the user has entered a password into
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 * the account editor (but has not checked the 'save' box), then we
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 * don't want to prompt them.
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if ((gaim_account_get_remember_password(account) || new) && (*value != '\0'))
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_account_set_password(account, value);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 else
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_account_set_password(account, NULL);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Build the username string. */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 username =
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_strdup(gtk_entry_get_text(GTK_ENTRY(dialog->screenname_entry)));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (dialog->prpl_info != NULL)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 for (l = dialog->prpl_info->user_splits,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 l2 = dialog->user_split_entries;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 l != NULL && l2 != NULL;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 l = l->next, l2 = l2->next)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GaimAccountUserSplit *split = l->data;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkEntry *entry = l2->data;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 char sep[2] = " ";
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 value = gtk_entry_get_text(entry);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 *sep = gaim_account_user_split_get_separator(split);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 tmp = g_strconcat(username, sep,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 (*value ? value :
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_account_user_split_get_default_value(split)),
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 NULL);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_free(username);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 username = tmp;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_account_set_username(account, username);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_free(username);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Add the protocol settings */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (dialog->prpl_info) {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 for (l = dialog->prpl_info->protocol_options,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 l2 = dialog->protocol_opt_entries;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 l != NULL && l2 != NULL;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 l = l->next, l2 = l2->next) {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GaimPrefType type;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GaimAccountOption *option = l->data;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *widget = l2->data;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkTreeIter iter;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 const char *setting;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 char *value2;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 int int_value;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gboolean bool_value;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 type = gaim_account_option_get_type(option);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 setting = gaim_account_option_get_setting(option);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 switch (type) {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 case GAIM_PREF_STRING:
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 value = gtk_entry_get_text(GTK_ENTRY(widget));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_account_set_string(account, setting, value);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 break;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 case GAIM_PREF_INT:
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 int_value = atoi(gtk_entry_get_text(GTK_ENTRY(widget)));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_account_set_int(account, setting, int_value);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 break;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 case GAIM_PREF_BOOLEAN:
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 bool_value =
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON(widget));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_account_set_bool(account, setting, bool_value);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 break;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 case GAIM_PREF_STRING_LIST:
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_combo_box_get_active_iter(GTK_COMBO_BOX(widget), &iter);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_tree_model_get(gtk_combo_box_get_model(GTK_COMBO_BOX(widget)), &iter, 1, &value2, -1);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_account_set_string(account, setting, value2);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_free(value2);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 break;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 default:
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 break;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Set the proxy stuff. */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (dialog->new_proxy_type == GAIM_PROXY_USE_GLOBAL) {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_account_set_proxy_info(account, NULL);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 else {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 proxy_info = gaim_account_get_proxy_info(account);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Create the proxy info if it doesn't exist. */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (proxy_info == NULL) {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 proxy_info = gaim_proxy_info_new();
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_account_set_proxy_info(account, proxy_info);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Set the proxy info type. */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_proxy_info_set_type(proxy_info, dialog->new_proxy_type);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Host */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 value = gtk_entry_get_text(GTK_ENTRY(dialog->proxy_host_entry));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (*value != '\0')
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_proxy_info_set_host(proxy_info, value);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 else
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_proxy_info_set_host(proxy_info, NULL);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Port */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 value = gtk_entry_get_text(GTK_ENTRY(dialog->proxy_port_entry));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (*value != '\0')
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_proxy_info_set_port(proxy_info, atoi(value));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 else
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_proxy_info_set_port(proxy_info, 0);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Username */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 value = gtk_entry_get_text(GTK_ENTRY(dialog->proxy_user_entry));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (*value != '\0')
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_proxy_info_set_username(proxy_info, value);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 else
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_proxy_info_set_username(proxy_info, NULL);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Password */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 value = gtk_entry_get_text(GTK_ENTRY(dialog->proxy_pass_entry));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (*value != '\0')
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_proxy_info_set_password(proxy_info, value);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 else
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_proxy_info_set_password(proxy_info, NULL);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* We no longer need the data from the dialog window */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 account_win_destroy_cb(NULL, NULL, dialog);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* If this is a new account, add it to our list */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (new)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_accounts_add(account);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 else
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_signal_emit(gaim_gtk_account_get_handle(), "account-modified", account);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* If this is a new account, then sign on! */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (new) {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 const GaimSavedStatus *saved_status;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 saved_status = gaim_savedstatus_get_current();
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (saved_status != NULL) {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_savedstatus_activate_for_account(saved_status, account);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_account_set_enabled(account, GAIM_GTK_UI, TRUE);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 return account;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static void
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 register_account_prefs_cb(GtkWidget *w, AccountPrefsDialog *dialog)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GaimAccount *account = ok_account_prefs_cb(NULL, dialog);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_account_register(account);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static const GtkTargetEntry dnd_targets[] = {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {"text/plain", 0, 0},
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {"text/uri-list", 0, 1},
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {"STRING", 0, 2}
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 };
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 void
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_gtk_account_dialog_show(GaimGtkAccountDialogType type,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GaimAccount *account)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 AccountPrefsDialog *dialog;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *win;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *main_vbox;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *vbox;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *bbox;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *dbox;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *notebook;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *button;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (accounts_window != NULL && account != NULL &&
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 (dialog = g_hash_table_lookup(account_pref_wins, account)) != NULL)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_window_present(GTK_WINDOW(dialog->window));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 return;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog = g_new0(AccountPrefsDialog, 1);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (accounts_window != NULL && account != NULL)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_hash_table_insert(account_pref_wins, account, dialog);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->account = account;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->type = type;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->sg = gtk_size_group_new(GTK_SIZE_GROUP_HORIZONTAL);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (dialog->account == NULL) {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Select the first prpl in the list*/
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GList *prpl_list = gaim_plugins_get_protocols();
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (prpl_list != NULL)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->protocol_id = g_strdup(((GaimPlugin *) prpl_list->data)->info->id);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 else
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->protocol_id =
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_strdup(gaim_account_get_protocol_id(dialog->account));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if ((dialog->plugin = gaim_find_prpl(dialog->protocol_id)) != NULL)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(dialog->plugin);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->window = win = gtk_window_new(GTK_WINDOW_TOPLEVEL);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_window_set_role(GTK_WINDOW(win), "account");
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (type == GAIM_GTK_ADD_ACCOUNT_DIALOG)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_window_set_title(GTK_WINDOW(win), _("Add Account"));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 else
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_window_set_title(GTK_WINDOW(win), _("Modify Account"));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_window_set_resizable(GTK_WINDOW(win), FALSE);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_container_set_border_width(GTK_CONTAINER(win), GAIM_HIG_BORDER);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_signal_connect(G_OBJECT(win), "delete_event",
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 G_CALLBACK(account_win_destroy_cb), dialog);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Setup the vbox */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 main_vbox = gtk_vbox_new(FALSE, GAIM_HIG_BORDER);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_container_add(GTK_CONTAINER(win), main_vbox);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_show(main_vbox);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 notebook = gtk_notebook_new();
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_box_pack_start(GTK_BOX(main_vbox), notebook, FALSE, FALSE, 0);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_show(GTK_WIDGET(notebook));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Setup the inner vbox */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->top_vbox = vbox = gtk_vbox_new(FALSE, GAIM_HIG_BORDER);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_container_set_border_width(GTK_CONTAINER(vbox), GAIM_HIG_BORDER);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_notebook_append_page(GTK_NOTEBOOK(notebook), vbox,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_label_new_with_mnemonic(_("_Basic")));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_show(vbox);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Setup the top frames. */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 add_login_options(dialog, vbox);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 add_user_options(dialog, vbox);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Setup the page with 'Advanced'. */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->bottom_vbox = dbox = gtk_vbox_new(FALSE, GAIM_HIG_BORDER);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_container_set_border_width(GTK_CONTAINER(dbox), GAIM_HIG_BORDER);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_notebook_append_page(GTK_NOTEBOOK(notebook), dbox,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_label_new_with_mnemonic(_("_Advanced")));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_show(dbox);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /** Setup the bottom frames. */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 add_protocol_options(dialog, dbox);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 add_proxy_options(dialog, dbox);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Setup the button box */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 bbox = gtk_hbutton_box_new();
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_box_set_spacing(GTK_BOX(bbox), GAIM_HIG_BOX_SPACE);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_button_box_set_layout(GTK_BUTTON_BOX(bbox), GTK_BUTTONBOX_END);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_box_pack_end(GTK_BOX(main_vbox), bbox, FALSE, TRUE, 0);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_show(bbox);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Register button */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 button = gtk_button_new_with_label(_("Register"));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_box_pack_start(GTK_BOX(bbox), button, FALSE, FALSE, 0);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_show(button);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_signal_connect(G_OBJECT(button), "clicked",
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 G_CALLBACK(register_account_prefs_cb), dialog);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->register_button = button;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (dialog->account == NULL)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_set_sensitive(button, FALSE);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (!dialog->prpl_info || !dialog->prpl_info->register_user)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_hide(button);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Cancel button */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 button = gtk_button_new_from_stock(GTK_STOCK_CANCEL);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_box_pack_start(GTK_BOX(bbox), button, FALSE, FALSE, 0);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_show(button);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_signal_connect(G_OBJECT(button), "clicked",
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 G_CALLBACK(cancel_account_prefs_cb), dialog);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Save button */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 button = gtk_button_new_from_stock(GTK_STOCK_SAVE);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_box_pack_start(GTK_BOX(bbox), button, FALSE, FALSE, 0);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (dialog->account == NULL)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_set_sensitive(button, FALSE);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_show(button);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->ok_button = button;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Set up DND */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_drag_dest_set(dialog->window,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GTK_DEST_DEFAULT_MOTION |
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GTK_DEST_DEFAULT_DROP,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dnd_targets,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 sizeof(dnd_targets) / sizeof(GtkTargetEntry),
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GDK_ACTION_COPY);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_signal_connect(G_OBJECT(dialog->window), "drag_data_received",
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 G_CALLBACK(account_dnd_recv), dialog);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_signal_connect(G_OBJECT(button), "clicked",
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 G_CALLBACK(ok_account_prefs_cb), dialog);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Show the window. */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_show(win);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /**************************************************************************
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 * Accounts Dialog
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 **************************************************************************/
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static void
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 signed_on_off_cb(GaimConnection *gc, gpointer user_data)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GaimAccount *account;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GaimGtkPulseData *pulse_data;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkTreeModel *model;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkTreeIter iter;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GdkPixbuf *pixbuf;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 size_t index;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Don't need to do anything if the accounts window is not visible */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (accounts_window == NULL)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 return;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 account = gaim_connection_get_account(gc);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 model = GTK_TREE_MODEL(accounts_window->model);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 index = g_list_index(gaim_accounts_get_all(), account);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (gtk_tree_model_iter_nth_child(model, &iter, NULL, index))
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_tree_model_get(GTK_TREE_MODEL(accounts_window->model), &iter,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 COLUMN_PULSE_DATA, &pulse_data, -1);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (pulse_data != NULL)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (pulse_data->timeout > 0)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_source_remove(pulse_data->timeout);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_object_unref(G_OBJECT(pulse_data->online_pixbuf));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_free(pulse_data);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 pixbuf = gaim_gtk_create_prpl_icon(account, 0.5);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if ((pixbuf != NULL) && gaim_account_is_disconnected(account))
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gdk_pixbuf_saturate_and_pixelate(pixbuf, pixbuf, 0.0, FALSE);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_list_store_set(accounts_window->model, &iter,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 COLUMN_ICON, pixbuf,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 COLUMN_PULSE_DATA, NULL,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 -1);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (pixbuf != NULL)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_object_unref(G_OBJECT(pixbuf));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /*
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 * Get the GtkTreeIter of the specified account in the
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 * GtkListStore
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static gboolean
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 accounts_window_find_account_in_treemodel(GtkTreeIter *iter, GaimAccount *account)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkTreeModel *model;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GaimAccount *cur;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_return_val_if_fail(account != NULL, FALSE);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_return_val_if_fail(accounts_window != NULL, FALSE);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 model = GTK_TREE_MODEL(accounts_window->model);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (!gtk_tree_model_get_iter_first(model, iter))
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 return FALSE;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_tree_model_get(model, iter, COLUMN_DATA, &cur, -1);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (cur == account)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 return TRUE;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 while (gtk_tree_model_iter_next(model, iter))
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_tree_model_get(model, iter, COLUMN_DATA, &cur, -1);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (cur == account)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 return TRUE;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 return FALSE;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static void
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 account_removed_cb(GaimAccount *account, gpointer user_data)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 AccountPrefsDialog *dialog;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkTreeIter iter;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* If the account was being modified, close the edit window */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if ((dialog = g_hash_table_lookup(account_pref_wins, account)) != NULL)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 account_win_destroy_cb(NULL, NULL, dialog);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (accounts_window == NULL)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 return;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Remove the account from the GtkListStore */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (accounts_window_find_account_in_treemodel(&iter, account))
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_list_store_remove(accounts_window->model, &iter);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static void
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 account_abled_cb(GaimAccount *account, gpointer user_data)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkTreeIter iter;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (accounts_window == NULL)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 return;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* update the account in the GtkListStore */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (accounts_window_find_account_in_treemodel(&iter, account))
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_list_store_set(accounts_window->model, &iter,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 COLUMN_ENABLED, GPOINTER_TO_INT(user_data),
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 -1);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static void
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 drag_data_get_cb(GtkWidget *widget, GdkDragContext *ctx,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkSelectionData *data, guint info, guint time,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 AccountsWindow *dialog)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (data->target == gdk_atom_intern("GAIM_ACCOUNT", FALSE)) {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkTreeRowReference *ref;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkTreePath *source_row;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkTreeIter iter;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GaimAccount *account = NULL;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GValue val;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 ref = g_object_get_data(G_OBJECT(ctx), "gtk-tree-view-source-row");
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 source_row = gtk_tree_row_reference_get_path(ref);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (source_row == NULL)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 return;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_tree_model_get_iter(GTK_TREE_MODEL(dialog->model), &iter,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 source_row);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 val.g_type = 0;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_tree_model_get_value(GTK_TREE_MODEL(dialog->model), &iter,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 COLUMN_DATA, &val);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->drag_iter = iter;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 account = g_value_get_pointer(&val);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_selection_data_set(data, gdk_atom_intern("GAIM_ACCOUNT", FALSE),
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 8, (void *)&account, sizeof(account));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_tree_path_free(source_row);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static void
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 move_account_after(GtkListStore *store, GtkTreeIter *iter,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkTreeIter *position)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkTreeIter new_iter;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GaimAccount *account;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_tree_model_get(GTK_TREE_MODEL(store), iter,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 COLUMN_DATA, &account,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 -1);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_list_store_insert_after(store, &new_iter, position);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 set_account(store, &new_iter, account);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_list_store_remove(store, iter);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static void
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 move_account_before(GtkListStore *store, GtkTreeIter *iter,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkTreeIter *position)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkTreeIter new_iter;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GaimAccount *account;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_tree_model_get(GTK_TREE_MODEL(store), iter,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 COLUMN_DATA, &account,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 -1);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_list_store_insert_before(store, &new_iter, position);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 set_account(store, &new_iter, account);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_list_store_remove(store, iter);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static void
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 drag_data_received_cb(GtkWidget *widget, GdkDragContext *ctx,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 guint x, guint y, GtkSelectionData *sd,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 guint info, guint t, AccountsWindow *dialog)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (sd->target == gdk_atom_intern("GAIM_ACCOUNT", FALSE) && sd->data) {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gint dest_index;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GaimAccount *a = NULL;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkTreePath *path = NULL;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkTreeViewDropPosition position;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 memcpy(&a, sd->data, sizeof(a));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (gtk_tree_view_get_dest_row_at_pos(GTK_TREE_VIEW(widget), x, y,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 &path, &position)) {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkTreeIter iter;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GaimAccount *account;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GValue val;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_tree_model_get_iter(GTK_TREE_MODEL(dialog->model), &iter, path);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 val.g_type = 0;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_tree_model_get_value(GTK_TREE_MODEL(dialog->model), &iter,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 COLUMN_DATA, &val);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 account = g_value_get_pointer(&val);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 switch (position) {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 case GTK_TREE_VIEW_DROP_AFTER:
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 case GTK_TREE_VIEW_DROP_INTO_OR_AFTER:
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 move_account_after(dialog->model, &dialog->drag_iter,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 &iter);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dest_index = g_list_index(gaim_accounts_get_all(),
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 account) + 1;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 break;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 case GTK_TREE_VIEW_DROP_BEFORE:
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 case GTK_TREE_VIEW_DROP_INTO_OR_BEFORE:
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dest_index = g_list_index(gaim_accounts_get_all(),
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 account);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 move_account_before(dialog->model, &dialog->drag_iter,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 &iter);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 break;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 default:
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 return;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_accounts_reorder(a, dest_index);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static gint
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 accedit_win_destroy_cb(GtkWidget *w, GdkEvent *event, AccountsWindow *dialog)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_gtk_accounts_window_hide();
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 return 0;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static gboolean
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 configure_cb(GtkWidget *w, GdkEventConfigure *event, AccountsWindow *dialog)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (GTK_WIDGET_VISIBLE(w)) {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 int old_width = gaim_prefs_get_int("/gaim/gtk/accounts/dialog/width");
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 int col_width;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 int difference;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_prefs_set_int("/gaim/gtk/accounts/dialog/width", event->width);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_prefs_set_int("/gaim/gtk/accounts/dialog/height", event->height);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 col_width = gtk_tree_view_column_get_width(dialog->screenname_col);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (col_width == 0)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 return FALSE;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 difference = (MAX(old_width, event->width) -
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 MIN(old_width, event->width));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (difference == 0)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 return FALSE;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (old_width < event->width)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_tree_view_column_set_min_width(dialog->screenname_col,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 col_width + difference);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 else
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_tree_view_column_set_max_width(dialog->screenname_col,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 col_width - difference);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 return FALSE;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static void
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 add_account_cb(GtkWidget *w, AccountsWindow *dialog)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_gtk_account_dialog_show(GAIM_GTK_ADD_ACCOUNT_DIALOG, NULL);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static void
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 modify_account_sel(GtkTreeModel *model, GtkTreePath *path,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkTreeIter *iter, gpointer data)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GaimAccount *account;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_tree_model_get(model, iter, COLUMN_DATA, &account, -1);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (account != NULL)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_gtk_account_dialog_show(GAIM_GTK_MODIFY_ACCOUNT_DIALOG, account);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static void
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 modify_account_cb(GtkWidget *w, AccountsWindow *dialog)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkTreeSelection *selection;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 selection = gtk_tree_view_get_selection(GTK_TREE_VIEW(dialog->treeview));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_tree_selection_selected_foreach(selection, modify_account_sel, dialog);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static void
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 delete_account_cb(GaimAccount *account)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_accounts_delete(account);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static void
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 ask_delete_account_sel(GtkTreeModel *model, GtkTreePath *path,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkTreeIter *iter, gpointer data)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GaimAccount *account;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_tree_model_get(model, iter, COLUMN_DATA, &account, -1);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (account != NULL) {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 char *buf;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 buf = g_strdup_printf(_("Are you sure you want to delete %s?"),
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_account_get_username(account));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_request_close_with_handle(account);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_request_action(account, NULL, buf, NULL, 0, account, 2,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 _("Delete"), delete_account_cb,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 _("Cancel"), NULL);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_free(buf);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static void
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 ask_delete_account_cb(GtkWidget *w, AccountsWindow *dialog)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkTreeSelection *selection;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 selection = gtk_tree_view_get_selection(GTK_TREE_VIEW(dialog->treeview));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_tree_selection_selected_foreach(selection, ask_delete_account_sel,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static void
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 close_accounts_cb(GtkWidget *w, AccountsWindow *dialog)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_destroy(dialog->window);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_gtk_accounts_window_hide();
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static void
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 enabled_cb(GtkCellRendererToggle *renderer, gchar *path_str,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gpointer data)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 AccountsWindow *dialog = (AccountsWindow *)data;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GaimAccount *account;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkTreeModel *model = GTK_TREE_MODEL(dialog->model);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkTreeIter iter;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gboolean enabled;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 const GaimSavedStatus *saved_status;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_tree_model_get_iter_from_string(model, &iter, path_str);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_tree_model_get(model, &iter,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 COLUMN_DATA, &account,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 COLUMN_ENABLED, &enabled,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 -1);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /*
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 * If we just enabled the account, then set the statuses
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 * to the current status.
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (!enabled)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 saved_status = gaim_savedstatus_get_current();
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_savedstatus_activate_for_account(saved_status, account);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_account_set_enabled(account, GAIM_GTK_UI, !enabled);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static void
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 add_columns(GtkWidget *treeview, AccountsWindow *dialog)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkCellRenderer *renderer;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkTreeViewColumn *column;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Screen Name column */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 column = gtk_tree_view_column_new();
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_tree_view_column_set_title(column, _("Screen Name"));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_tree_view_insert_column(GTK_TREE_VIEW(treeview), column, -1);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_tree_view_column_set_resizable(column, TRUE);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Icon */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 renderer = gtk_cell_renderer_pixbuf_new();
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_tree_view_column_pack_start(column, renderer, FALSE);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_tree_view_column_add_attribute(column, renderer,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 "pixbuf", COLUMN_ICON);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Screen Name */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 renderer = gtk_cell_renderer_text_new();
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_tree_view_column_pack_start(column, renderer, TRUE);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_tree_view_column_add_attribute(column, renderer,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 "text", COLUMN_SCREENNAME);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->screenname_col = column;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Enabled */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 renderer = gtk_cell_renderer_toggle_new();
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_signal_connect(G_OBJECT(renderer), "toggled",
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 G_CALLBACK(enabled_cb), dialog);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 column = gtk_tree_view_column_new_with_attributes(_("Enabled"),
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 renderer, "active", COLUMN_ENABLED, NULL);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_tree_view_insert_column(GTK_TREE_VIEW(treeview), column, -1);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_tree_view_column_set_resizable(column, TRUE);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Protocol name */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 column = gtk_tree_view_column_new();
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_tree_view_column_set_title(column, _("Protocol"));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_tree_view_insert_column(GTK_TREE_VIEW(treeview), column, -1);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_tree_view_column_set_resizable(column, TRUE);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 renderer = gtk_cell_renderer_text_new();
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_tree_view_column_pack_start(column, renderer, TRUE);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_tree_view_column_add_attribute(column, renderer,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 "text", COLUMN_PROTOCOL);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static void
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 set_account(GtkListStore *store, GtkTreeIter *iter, GaimAccount *account)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GdkPixbuf *pixbuf;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 pixbuf = gaim_gtk_create_prpl_icon(account, 0.5);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if ((pixbuf != NULL) && gaim_account_is_disconnected(account))
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gdk_pixbuf_saturate_and_pixelate(pixbuf, pixbuf, 0.0, FALSE);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_list_store_set(store, iter,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 COLUMN_ICON, pixbuf,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 COLUMN_SCREENNAME, gaim_account_get_username(account),
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 COLUMN_ENABLED, gaim_account_get_enabled(account, GAIM_GTK_UI),
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 COLUMN_PROTOCOL, gaim_account_get_protocol_name(account),
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 COLUMN_DATA, account,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 -1);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (pixbuf != NULL)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_object_unref(G_OBJECT(pixbuf));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static void
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 add_account_to_liststore(GaimAccount *account, gpointer user_data)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkTreeIter iter;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (accounts_window == NULL)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 return;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_list_store_append(accounts_window->model, &iter);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 set_account(accounts_window->model, &iter, account);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static void
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 populate_accounts_list(AccountsWindow *dialog)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GList *l;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_list_store_clear(dialog->model);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 for (l = gaim_accounts_get_all(); l != NULL; l = l->next)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 add_account_to_liststore((GaimAccount *)l->data, NULL);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 #if !GTK_CHECK_VERSION(2,2,0)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static void
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 get_selected_helper(GtkTreeModel *model, GtkTreePath *path,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkTreeIter *iter, gpointer user_data)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 *((gboolean *)user_data) = TRUE;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 #endif
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static void
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 account_selected_cb(GtkTreeSelection *sel, AccountsWindow *dialog)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gboolean selected = FALSE;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 #if GTK_CHECK_VERSION(2,2,0)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 selected = (gtk_tree_selection_count_selected_rows(sel) > 0);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 #else
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_tree_selection_selected_foreach(sel, get_selected_helper, &selected);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 #endif
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_set_sensitive(dialog->modify_button, selected);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_set_sensitive(dialog->delete_button, selected);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static gboolean
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 account_treeview_double_click_cb(GtkTreeView *treeview, GdkEventButton *event, gpointer user_data)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 AccountsWindow *dialog;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkTreePath *path;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkTreeViewColumn *column;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkTreeIter iter;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GaimAccount *account;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 const gchar *title;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog = (AccountsWindow *)user_data;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Figure out which node was clicked */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (!gtk_tree_view_get_path_at_pos(GTK_TREE_VIEW(dialog->treeview), event->x, event->y, &path, &column, NULL, NULL))
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 return FALSE;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 title = gtk_tree_view_column_get_title(column);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* The -1 is required because the first two columns of the list
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 * store are displayed as only one column in the tree view. */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 column = gtk_tree_view_get_column(treeview, COLUMN_ENABLED-1);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_tree_model_get_iter(GTK_TREE_MODEL(dialog->model), &iter, path);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_tree_path_free(path);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_tree_model_get(GTK_TREE_MODEL(dialog->model), &iter, COLUMN_DATA, &account, -1);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if ((account != NULL) && (event->button == 1) &&
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 (event->type == GDK_2BUTTON_PRESS) &&
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 (strcmp(gtk_tree_view_column_get_title(column), title)))
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_gtk_account_dialog_show(GAIM_GTK_MODIFY_ACCOUNT_DIALOG, account);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 return TRUE;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 return FALSE;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static GtkWidget *
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 create_accounts_list(AccountsWindow *dialog)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *sw;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *treeview;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkTreeSelection *sel;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkTargetEntry gte[] = {{"GAIM_ACCOUNT", GTK_TARGET_SAME_APP, 0}};
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Create the scrolled window. */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 sw = gtk_scrolled_window_new(0, 0);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_scrolled_window_set_policy(GTK_SCROLLED_WINDOW(sw),
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GTK_POLICY_AUTOMATIC,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GTK_POLICY_AUTOMATIC);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_scrolled_window_set_shadow_type(GTK_SCROLLED_WINDOW(sw),
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GTK_SHADOW_IN);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_show(sw);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Create the list model. */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->model = gtk_list_store_new(NUM_COLUMNS,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GDK_TYPE_PIXBUF, G_TYPE_STRING,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 G_TYPE_BOOLEAN, G_TYPE_STRING, G_TYPE_POINTER,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 G_TYPE_POINTER);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* And now the actual treeview */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 treeview = gtk_tree_view_new_with_model(GTK_TREE_MODEL(dialog->model));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->treeview = treeview;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_tree_view_set_rules_hint(GTK_TREE_VIEW(treeview), TRUE);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 sel = gtk_tree_view_get_selection(GTK_TREE_VIEW(treeview));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_tree_selection_set_mode(sel, GTK_SELECTION_MULTIPLE);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_signal_connect(G_OBJECT(sel), "changed",
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 G_CALLBACK(account_selected_cb), dialog);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Handle double-clicking */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_signal_connect(G_OBJECT(treeview), "button_press_event",
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 G_CALLBACK(account_treeview_double_click_cb), dialog);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_container_add(GTK_CONTAINER(sw), treeview);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_show(treeview);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 add_columns(treeview, dialog);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 populate_accounts_list(dialog);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Setup DND. I wanna be an orc! */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_tree_view_enable_model_drag_source(
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GTK_TREE_VIEW(treeview), GDK_BUTTON1_MASK, gte,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 1, GDK_ACTION_COPY);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_tree_view_enable_model_drag_dest(
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GTK_TREE_VIEW(treeview), gte, 1,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GDK_ACTION_COPY | GDK_ACTION_MOVE);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_signal_connect(G_OBJECT(treeview), "drag-data-received",
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 G_CALLBACK(drag_data_received_cb), dialog);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_signal_connect(G_OBJECT(treeview), "drag-data-get",
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 G_CALLBACK(drag_data_get_cb), dialog);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 return sw;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static void
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 account_modified_cb(GaimAccount *account, AccountsWindow *window)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkTreeIter iter;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (!accounts_window_find_account_in_treemodel(&iter, account))
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 return;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 set_account(window->model, &iter, account);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 void
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_gtk_accounts_window_show(void)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 AccountsWindow *dialog;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *win;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *vbox;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *bbox;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *sw;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GtkWidget *button;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 int width, height;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (accounts_window != NULL) {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_window_present(GTK_WINDOW(accounts_window->window));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 return;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 accounts_window = dialog = g_new0(AccountsWindow, 1);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 width = gaim_prefs_get_int("/gaim/gtk/accounts/dialog/width");
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 height = gaim_prefs_get_int("/gaim/gtk/accounts/dialog/height");
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->window = win = gtk_window_new(GTK_WINDOW_TOPLEVEL);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_window_set_default_size(GTK_WINDOW(win), width, height);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_window_set_role(GTK_WINDOW(win), "accounts");
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_window_set_title(GTK_WINDOW(win), _("Accounts"));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_container_set_border_width(GTK_CONTAINER(win), GAIM_HIG_BORDER);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_signal_connect(G_OBJECT(win), "delete_event",
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 G_CALLBACK(accedit_win_destroy_cb), accounts_window);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_signal_connect(G_OBJECT(win), "configure_event",
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 G_CALLBACK(configure_cb), accounts_window);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Setup the vbox */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 vbox = gtk_vbox_new(FALSE, GAIM_HIG_BORDER);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_container_add(GTK_CONTAINER(win), vbox);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_show(vbox);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Setup the scrolled window that will contain the list of accounts. */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 sw = create_accounts_list(dialog);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_box_pack_start(GTK_BOX(vbox), sw, TRUE, TRUE, 0);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_show(sw);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Button box. */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 bbox = gtk_hbutton_box_new();
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_box_set_spacing(GTK_BOX(bbox), GAIM_HIG_BOX_SPACE);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_button_box_set_layout(GTK_BUTTON_BOX(bbox), GTK_BUTTONBOX_END);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_box_pack_end(GTK_BOX(vbox), bbox, FALSE, TRUE, 0);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_show(bbox);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Add button */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 button = gtk_button_new_from_stock(GTK_STOCK_ADD);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_box_pack_start(GTK_BOX(bbox), button, FALSE, FALSE, 0);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_show(button);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_signal_connect(G_OBJECT(button), "clicked",
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 G_CALLBACK(add_account_cb), dialog);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Modify button */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 button = gtk_button_new_from_stock(GAIM_STOCK_MODIFY);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->modify_button = button;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_box_pack_start(GTK_BOX(bbox), button, FALSE, FALSE, 0);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_set_sensitive(button, FALSE);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_show(button);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_signal_connect(G_OBJECT(button), "clicked",
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 G_CALLBACK(modify_account_cb), dialog);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Delete button */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 button = gtk_button_new_from_stock(GTK_STOCK_DELETE);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 dialog->delete_button = button;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_box_pack_start(GTK_BOX(bbox), button, FALSE, FALSE, 0);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_set_sensitive(button, FALSE);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_show(button);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_signal_connect(G_OBJECT(button), "clicked",
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 G_CALLBACK(ask_delete_account_cb), dialog);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Close button */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 button = gtk_button_new_from_stock(GTK_STOCK_CLOSE);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_box_pack_start(GTK_BOX(bbox), button, FALSE, FALSE, 0);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_show(button);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_signal_connect(G_OBJECT(button), "clicked",
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 G_CALLBACK(close_accounts_cb), dialog);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_signal_connect(gaim_gtk_account_get_handle(), "account-modified",
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 accounts_window,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GAIM_CALLBACK(account_modified_cb), accounts_window);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gtk_widget_show(win);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 void
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_gtk_accounts_window_hide(void)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (accounts_window == NULL)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 return;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_signals_disconnect_by_handle(accounts_window);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_free(accounts_window);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 accounts_window = NULL;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* See if we're the main window here. */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (GAIM_GTK_BLIST(gaim_get_blist())->window == NULL &&
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_connections_get_all() == NULL) {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_core_quit();
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static void
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 free_add_user_data(GaimGtkAccountAddUserData *data)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_free(data->username);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_free(data->alias);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_free(data);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static void
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 add_user_cb(GaimGtkAccountAddUserData *data)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GaimConnection *gc = gaim_account_get_connection(data->account);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (g_list_find(gaim_connections_get_all(), gc))
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_blist_request_add_buddy(data->account, data->username,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 NULL, data->alias);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 free_add_user_data(data);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static char *
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 make_info(GaimAccount *account, GaimConnection *gc, const char *remote_user,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 const char *id, const char *alias, const char *msg)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 if (msg != NULL && *msg == '\0')
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 msg = NULL;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 return g_strdup_printf(_("%s%s%s%s has made %s his or her buddy%s%s"),
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 remote_user,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 (alias != NULL ? " (" : ""),
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 (alias != NULL ? alias : ""),
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 (alias != NULL ? ")" : ""),
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 (id != NULL
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 ? id
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 : (gaim_connection_get_display_name(gc) != NULL
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 ? gaim_connection_get_display_name(gc)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 : gaim_account_get_username(account))),
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 (msg != NULL ? ": " : "."),
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 (msg != NULL ? msg : ""));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static void
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_gtk_accounts_notify_added(GaimAccount *account, const char *remote_user,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 const char *id, const char *alias,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 const char *msg)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 char *buffer;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GaimConnection *gc;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gc = gaim_account_get_connection(account);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 buffer = make_info(account, gc, remote_user, id, alias, msg);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_notify_info(NULL, NULL, buffer, NULL);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_free(buffer);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static void
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_gtk_accounts_request_add(GaimAccount *account, const char *remote_user,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 const char *id, const char *alias,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 const char *msg)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 char *buffer;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GaimConnection *gc;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GaimGtkAccountAddUserData *data;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gc = gaim_account_get_connection(account);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 data = g_new0(GaimGtkAccountAddUserData, 1);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 data->account = account;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 data->username = g_strdup(remote_user);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 data->alias = g_strdup(alias);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 buffer = make_info(account, gc, remote_user, id, alias, msg);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_request_action(NULL, NULL, _("Add buddy to your list?"),
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 buffer, GAIM_DEFAULT_ACTION_NONE, data, 2,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 _("Add"), G_CALLBACK(add_user_cb),
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 _("Cancel"), G_CALLBACK(free_add_user_data));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_free(buffer);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static GaimAccountUiOps ui_ops =
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_gtk_accounts_notify_added,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 NULL,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_gtk_accounts_request_add
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 };
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GaimAccountUiOps *
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_gtk_accounts_get_ui_ops(void)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 return &ui_ops;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 void *
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_gtk_account_get_handle(void) {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 static int handle;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 return &handle;
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 void
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_gtk_account_init(void)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_prefs_add_none("/gaim/gtk/accounts");
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_prefs_add_none("/gaim/gtk/accounts/dialog");
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_prefs_add_int("/gaim/gtk/accounts/dialog/width", 520);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_prefs_add_int("/gaim/gtk/accounts/dialog/height", 321);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_prefs_add_string("/gaim/gtk/accounts/buddyicon", NULL);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_signal_register(gaim_gtk_account_get_handle(), "account-modified",
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_marshal_VOID__POINTER, NULL, 1,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_value_new(GAIM_TYPE_SUBTYPE,
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GAIM_SUBTYPE_ACCOUNT));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /* Setup some gaim signal handlers. */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_signal_connect(gaim_connections_get_handle(), "signed-on",
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_gtk_account_get_handle(),
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GAIM_CALLBACK(signed_on_off_cb), NULL);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_signal_connect(gaim_connections_get_handle(), "signed-off",
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_gtk_account_get_handle(),
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GAIM_CALLBACK(signed_on_off_cb), NULL);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_signal_connect(gaim_accounts_get_handle(), "account-added",
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_gtk_account_get_handle(),
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GAIM_CALLBACK(add_account_to_liststore), NULL);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_signal_connect(gaim_accounts_get_handle(), "account-removed",
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_gtk_account_get_handle(),
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GAIM_CALLBACK(account_removed_cb), NULL);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_signal_connect(gaim_accounts_get_handle(), "account-disabled",
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_gtk_account_get_handle(),
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GAIM_CALLBACK(account_abled_cb), GINT_TO_POINTER(FALSE));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_signal_connect(gaim_accounts_get_handle(), "account-enabled",
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_gtk_account_get_handle(),
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 GAIM_CALLBACK(account_abled_cb), GINT_TO_POINTER(TRUE));
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 account_pref_wins =
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_hash_table_new_full(g_direct_hash, g_direct_equal, NULL, NULL);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 void
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_gtk_account_uninit(void)
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 {
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 /*
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 * TODO: Need to free all the dialogs in here. Could probably create
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 * a callback function to use for the free-some-data-function
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 * parameter of g_hash_table_new_full, above.
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 */
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 g_hash_table_destroy(account_pref_wins);
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_signals_disconnect_by_handle(gaim_gtk_account_get_handle());
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 gaim_signals_unregister_by_instance(gaim_gtk_account_get_handle());
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申 }
+ 鐃緒申��申鐃初姐�渇����鐃醇�鐃緒申��申鐃緒申